public override string GetAbsoluteName() { Net.Vpc.Upa.EntityPart parentSchemaItem = GetParent(); if (parentSchemaItem == null) { return(GetEntity().GetAbsoluteName() + "." + GetName()); } return(parentSchemaItem.GetAbsoluteName() + "/" + GetName()); }
public FieldEvent(Net.Vpc.Upa.Field field, Net.Vpc.Upa.PersistenceUnit persistenceUnit, Net.Vpc.Upa.Entity entity, Net.Vpc.Upa.EntityPart parent, int index, Net.Vpc.Upa.EntityPart oldParent, int oldIndex, Net.Vpc.Upa.EventPhase phase) { this.persistenceUnit = persistenceUnit; this.field = field; this.parent = parent; this.index = index; this.oldParent = oldParent; this.oldIndex = oldIndex; this.entity = entity; this.phase = phase; }
public virtual void After(Net.Vpc.Upa.PrimitiveField child, int index) { Net.Vpc.Upa.EntityPart oldParent = child.GetParent(); if (oldParent != null && oldParent != defaultCompoundField) { if (oldParent is Net.Vpc.Upa.Section) { Net.Vpc.Upa.Section x = (Net.Vpc.Upa.Section)oldParent; x.RemovePartAt(x.IndexOfPart(child)); } else if (oldParent is Net.Vpc.Upa.CompoundField) { Net.Vpc.Upa.CompoundField x = (Net.Vpc.Upa.CompoundField)oldParent; ((Net.Vpc.Upa.Impl.DefaultCompoundField)x).DropFieldAt(x.IndexOfField(child)); } } if (oldParent != defaultCompoundField) { Net.Vpc.Upa.Impl.Util.DefaultBeanAdapter adapter = new Net.Vpc.Upa.Impl.Util.DefaultBeanAdapter(child); adapter.SetProperty("parent", defaultCompoundField); } }
public virtual void Add(Net.Vpc.Upa.EntityPart part) { path.Add(part); }
public virtual Net.Vpc.Upa.EntityPart RemovePartAt(int index) /* throws Net.Vpc.Upa.Exceptions.UPAException */ { Net.Vpc.Upa.EntityPart child = Net.Vpc.Upa.Impl.Util.ListUtils.Remove <Net.Vpc.Upa.EntityPart>(parts, index, this, new Net.Vpc.Upa.Impl.DefaultSectionPrivateRemoveItemInterceptor()); return(child); }
public virtual void AddPart(Net.Vpc.Upa.EntityPart child, int index) /* throws Net.Vpc.Upa.Exceptions.UPAException */ { Net.Vpc.Upa.Impl.Util.ListUtils.Add <Net.Vpc.Upa.EntityPart>(parts, child, index, this, this, new Net.Vpc.Upa.Impl.DefaultSectionPrivateAddItemInterceptor(this)); }
public virtual void AddPart(Net.Vpc.Upa.EntityPart child) /* throws Net.Vpc.Upa.Exceptions.UPAException */ { AddPart(child, -1); }
public DefaultSection() : base() { this.parent = null; this.parts = new System.Collections.Generic.List <Net.Vpc.Upa.EntityPart>(3); childrenMap = new System.Collections.Generic.Dictionary <string, Net.Vpc.Upa.EntityPart>(); }
public virtual string GetPath() { Net.Vpc.Upa.EntityPart parent = GetParent(); return(parent == null ? ("/" + GetName()) : (parent.GetPath() + "/" + GetName())); }
public virtual void SetParent(Net.Vpc.Upa.EntityPart item) { Net.Vpc.Upa.EntityPart old = this.parent; this.parent = item; propertyChangeSupport.FirePropertyChange("parent", old, parent); }
public virtual int IndexOfPart(Net.Vpc.Upa.EntityPart child) { return(parts.IndexOf(child)); }