/** * @author <a href="mailto:julien.viet@exoplatform.com">Julien Viet</a> * @version $Revision$ */ @PrimaryType(name = "mop:contexttypecontainer") @NamingPrefix("mop") @FormattedBy(BaseEncodingObjectFormatter.class) public abstract class ContextTypeContainer { @OneToMany public abstract Map<String, ContextType> getContextTypes(); @OneToOne @MappedBy("mop:contexttypes") public abstract AbstractCustomization getCustomization(); }
private RelationshipMapping.OneToMany.Hierarchic createHierarchicOneToMany(BeanMapping beanMapping, OneToMany annotation, PropertyInfo<BeanValueInfo, ?> property) { RelationshipMapping.OneToMany.Hierarchic mapping; NamingPrefix namingPrefix = property.getAnnotation(NamingPrefix.class); String declaredPrefix = namingPrefix != null ? namingPrefix.value() : null; String prefix = declaredPrefix == null ? beanMapping.getPrefix() : declaredPrefix; mapping = new RelationshipMapping.OneToMany.Hierarchic(property, declaredPrefix, prefix); mapping.relatedBeanMapping = resolve(property.getValue().getBean()); return mapping; }
private RelationshipMapping.ManyToOne.Hierarchic createHierarchicManyToOne(BeanMapping beanMapping, ManyToOne annotation, PropertyInfo<BeanValueInfo, ValueKind.Single> property) { RelationshipMapping.ManyToOne.Hierarchic mapping; NamingPrefix namingPrefix = property.getAnnotation(NamingPrefix.class); String declaredPrefix = namingPrefix != null ? namingPrefix.value() : null; String prefix = declaredPrefix == null ? beanMapping.getPrefix() : declaredPrefix; mapping = new RelationshipMapping.ManyToOne.Hierarchic(property, declaredPrefix, prefix); mapping.relatedBeanMapping = resolve(property.getValue().getBean()); return mapping; }
/** * @author <a href="mailto:julien.viet@exoplatform.com">Julien Viet</a> * @version $Revision$ */ @PrimaryType(name = "mop:contexttype") @NamingPrefix("mop") @FormattedBy(BaseEncodingObjectFormatter.class) public abstract class ContextType { @Name public abstract String getName(); @OneToMany public abstract Map<String, ContextSpecialization> getSpecializations(); @ManyToOne public abstract ContextTypeContainer getContainer(); }
String prefix = null; if (namingPrefix != null) { prefix = namingPrefix.value();
/** * @author <a href="mailto:julien.viet@exoplatform.com">Julien Viet</a> * @version $Revision$ */ @PrimaryType(name = "mop:pagecontainer") @NamingPrefix("mop") @FormattedBy(BaseEncodingObjectFormatter.class) public abstract class PageContainer { @OneToOne @MappedBy("mop:children") public abstract PageImpl getOwner(); @OneToMany public abstract Map<String, PageImpl> getPages(); @Create public abstract PageImpl createPage(); public PageImpl addPage(String name) { PageImpl page = createPage(); getPages().put(name, page); return page; } }
NamingPrefix namingPrefix = property.getAnnotation(NamingPrefix.class); if (namingPrefix != null) { prefix = namingPrefix.value();
/** * @author <a href="mailto:julien.viet@exoplatform.com">Julien Viet</a> * @version $Revision$ */ @NamingPrefix("foo") @PrimaryType(name = "1") public abstract class F1 { @OneToMany() public abstract Collection<F2> getChildren(); }
/** * @author <a href="mailto:julien.viet@exoplatform.com">Julien Viet</a> * @version $Revision$ */ @NamingPrefix("foo") @PrimaryType(name = "1") public class G1 { }
@NamingPrefix("onetomany_h_map") @OneToMany public abstract Map<String, B5> getChildren(); }
@NamingPrefix("onetomany_h_map") @ManyToOne public abstract A5 getParent();
@Properties() @NamingPrefix("foo") public abstract Map<String, Object> getStringProperties();
@NamingPrefix("foo") @OneToMany public abstract Collection<E2> getChildren();
@Properties @NamingPrefix("property_map") public abstract Map<String, Object> getProperties();
@NamingPrefix("mop") @FormattedBy(BaseEncodingObjectFormatter.class) @PrimaryType(name = "foo")
@NamingPrefix("mop") @FormattedBy(BaseEncodingObjectFormatter.class) public abstract class NavigationContainer
@NamingPrefix("mop") @FormattedBy(BaseEncodingObjectFormatter.class) @PrimaryType(name = "mop:site")
@NamingPrefix("mop") @FormattedBy(BaseEncodingObjectFormatter.class) public abstract class CustomizationContainer
@NamingPrefix("mop") @FormattedBy(BaseEncodingObjectFormatter.class) @PrimaryType(name = "mop:workspaceobject")
@NamingPrefix("mop") @FormattedBy(BaseEncodingObjectFormatter.class) @NamingPolicy(onDuplicate = NameConflictResolution.REPLACE)