本文整理汇总了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;
}