//------------------------------------------------------------------------------- // This package was automatically generated from EXPRESS (ISO STEP 10303 part11) // by a java generator build with the meta CASE tool Platypus // (alain.plantec@univ-brest.fr) // // Please, be aware that any hand-made updating of this file can be lost!!. //------------------------------------------------------------------------------- package CheddarBridge; import java.util.*; import step.core.*; public class Channel extends ARINC_653_Object { private static String EntityName = "CHANNEL"; private PortMappingType Source_; private ArrayList Destination_; private String ChannelIdentifier_; private String ChannelName_; public static String EntityName() { return EntityName; } public String entityName() { return EntityName(); } public boolean isInstanceOf(String entName) { return entName.equals(EntityName); } public boolean isKindOf(String entName) { return entName.equals(EntityName) ? true : super.isKindOf(entName); } public void initializeExplicitAttributes() { super.initializeExplicitAttributes(); Source_ = null; Destination_ = new ArrayList(); ChannelIdentifier_ = ""; ChannelName_ = null; } public Channel () { initializeExplicitAttributes(); } public Channel (step.core.StepCoreRepository _repo) { super(_repo); initializeExplicitAttributes(); } public void setSource ( PortMappingType _v ) { Source_ = _v; } public PortMappingType getSource() { return Source_; } public void setDestination(ArrayList _v) { if (_v == null) { Destination_ = null; } else { if (Destination_ == null) { Destination_ = new ArrayList(); } else { Destination_.clear(); } Destination_.addAll(_v); } } public void destinationAdd (PortMappingType _elem) { if (Destination_ == null) { Destination_ = new ArrayList(); } Destination_.add(_elem); } public boolean destinationRemove(PortMappingType _elem) { if (Destination_ != null) { return Destination_.remove(_elem); } return false; } public boolean destinationRemoveAll(ArrayList _v) { if (Destination_ != null) { return Destination_.removeAll(_v); } return false; } public void destinationAddAll(ArrayList _v) { if (Destination_ == null) { Destination_ = new ArrayList(); } Destination_.addAll(_v); } public PortMappingType destinationSet (int _pos, PortMappingType _elem) { return Destination_.set(_pos, _elem); } public ArrayList getDestination() { return Destination_; } public int destinationSize () { return Destination_ == null ? 0 : Destination_.size(); } public PortMappingType destinationGet (int _pos) { return Destination_.get(_pos); } public void setChannelIdentifier ( String _v ) { ChannelIdentifier_ = _v; } public String getChannelIdentifier() { return ChannelIdentifier_; } public void setChannelName ( String _v ) { ChannelName_ = _v; } public String getChannelName() { return ChannelName_; } public void accept(CheddarBridge_AbstractVisitor visitor ) { visitor.accept((Channel) this); } public step.core.StepCoreObjectReaderWriter readerWriter() { return new ChannelStepRW(); } public boolean replaceReferenceWith(StepCoreObject oldObj, StepCoreObject newObj) { boolean done = false; if (getSource() == oldObj ) { setSource((PortMappingType) newObj); done = true; } for (ListIterator itori = getDestination().listIterator(); itori.hasNext(); ) { if (itori.next() == oldObj ) { if (newObj == null) { itori.remove(); } else { itori.set((PortMappingType)newObj); } done = true; } } if (super.replaceReferenceWith(oldObj, newObj)) { done = true; } return done; } }