本文整理匯總了Java中com.ibm.xsp.extlib.social.Person類的典型用法代碼示例。如果您正苦於以下問題:Java Person類的具體用法?Java Person怎麽用?Java Person使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
Person類屬於com.ibm.xsp.extlib.social包,在下文中一共展示了Person類的13個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: getAllPropertyKeys
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
@Override
public void getAllPropertyKeys(String category, List<Object> list) {
if(StringUtil.equals(DEFAULT_CATEGORY,category)) {
list.add(Person.FIELD_ID);
list.add(Person.FIELD_DISPLAYNAME);
list.add(Person.FIELD_THUMBNAIL_URL);
list.add(Person.FIELD_OWNER);
list.add(Person.FIELD_VIEWER);
return;
}
ResourceDataProvider p = findDataProvider(category);
if(p!=null) {
list.add(category+':'+SCOPE_AND_SIZE);
Set<String> keys = new HashSet<String>();
p.enumerateProperties(keys);
for(String s: keys) {
list.add(category+':'+s);
}
}
}
示例2: getValue
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public Object getValue(PersonImpl person, Object prop) {
if (prop.equals(Person.FIELD_THUMBNAIL_URL)) {
return getData(person).thumbnailUrl;
}
if (prop.equals(FIELD_INTERNETEMAIL)) {
return getData(person).internetEmail;
}
return null;
}
示例3: getType
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public Class<?> getType(PersonImpl person, Object prop) {
if (prop.equals(Person.FIELD_THUMBNAIL_URL)) {
return String.class;
}
if (prop.equals(FIELD_INTERNETEMAIL)) {
return String.class;
}
return null;
}
示例4: getPerson
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public Person getPerson(FacesContext context) {
Person person = (Person)context.getExternalContext().getRequestMap().get(BEAN_DATA);
if(person==null) {
SocialServicesFactory factory = SocialServicesFactory.getInstance();
PeopleService svc = factory.getPeopleService();
person = svc.getPerson(factory.getAuthenticatedUserId(context));
context.getExternalContext().getRequestMap().put(BEAN_DATA,person);
}
return person;
}
示例5: getType
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
@Override
public Class<?> getType(PersonImpl person, Object key) {
// TODO Auto-generated method stub
if (key.equals(Person.FIELD_THUMBNAIL_URL)) {
return String.class;
}
if (m_AllField.contains(key)) {
return String.class;
}
return null;
}
示例6: find
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public DumpAccessor find(DumpContext dumpContext, Object o) {
if(o instanceof Person) {
return new PersonMap(dumpContext,(Person)o);
}
return null;
}
示例7: PersonMap
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public PersonMap(DumpContext dumpContext, Person p) {
super(dumpContext,p);
}
示例8: getPerson
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public Person getPerson(String id) {
return new PersonImpl(this,id);
}
示例9: getThumbnailUrl
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public String getThumbnailUrl() {
return (String)getField(Person.FIELD_THUMBNAIL_URL);
}
示例10: get
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public Person get(String id) {
PeopleService svc = SocialServicesFactory.getInstance().getPeopleService();
return svc.getPerson(id);
}
示例11: getPerson
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public Person getPerson(String id) {
PeopleService svc = SocialServicesFactory.getInstance().getPeopleService();
return svc.getPerson(id);
}
示例12: getValue
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public Object getValue(PersonImpl person, Object prop) {
if(prop.equals(Person.FIELD_THUMBNAIL_URL)) {
return getData(person).thumbnailUrl;
}
return null;
}
示例13: getType
import com.ibm.xsp.extlib.social.Person; //導入依賴的package包/類
public Class<?> getType(PersonImpl person, Object prop) {
if(prop.equals(Person.FIELD_THUMBNAIL_URL)) {
return String.class;
}
return null;
}