Port
models a port of a component.
More...
List of all members.
Public Member Functions |
void | addDataElement (DataElement newDataElement) throws AXLException |
| Adds e new data element.
|
void | addOperation (Operation newOperation) throws AXLException |
| Adds a new operation.
|
void | addSignal (Signal newSignal) throws AXLException |
| Adds a new signal.
|
int | compareTo (IAXLangElement axlOther) |
| Define sorting order.
|
void | elementAdded (IAXLangElement owner, ReferenceKind referenceKind, Role role, IAXLangElement addedElement) |
| if this a port of an xor-component this method reacts to changes of all ports that this port represents
|
void | elementChanged (IAXLangElement owner, AXLangAttribute changedAttribute, String newValue, String oldValue) |
| if this is an xor port: reacts on the change of the value of one of the attributes (identifier, direction) of one of the alternatives
|
void | elementDeleted (IAXLangElement deletedElement) |
| if this is an xor-port: reacts to the deletion of one of the alternatives
|
void | elementRemoved (IAXLangElement owner, ReferenceKind referenceKind, Role role, IAXLangElement removedElement) |
| if this is an xor port: reacts on removal of a reference to a data element of one of the alternatives
|
Collection< DataElement > | getDataElements () |
| getter method for the collection of referenced data elements.
|
Collection< Port > | getDelegatedPorts () |
| Returns the ports that are connected with this port via a delegation.
|
Direction | getDirection () |
| Returns direction.
|
HWPortType | getHWPortType () |
| Returns hardware port type.
|
Collection< ElementWithMessage > | getNonValidElements () |
Collection< Operation > | getOperations () |
| Returns the operations.
|
Collection< Signal > | getSignals () |
| Returns the signals.
|
boolean | isClockElement () |
| Is this port a clock port?
|
boolean | isCSPort () |
| Checks whether the port's interfaces contain only operations.
|
boolean | isDependent () |
| Returns dependency.
|
boolean | isSRPort () |
| Checks whether the port's interfaces contain only signals.
|
| Port () |
| Constructor.
|
boolean | removeDataElement (DataElement theDataElement) |
| Removes either a Signal or an Operation.
|
boolean | removeOperation (Operation theOperation) |
| Removes the operation.
|
boolean | removeSignal (Signal theSignal) |
| Removes the signal.
|
void | setDirection (Direction newDirection) |
| Sets direction.
|
void | setHWPortType (HWPortType newHWPortType) |
| Sets hardware port type.
|
Public Attributes |
Map< String, Port > | xorToAlternativeMap |
Static Public Attributes |
static final String | CLOCKOUT = "clockOut" |
| clock port
|
Detailed Description
Port
models a port of a component.
- Properties
- mandatory direction (Direction)
- References
-
- Author:
- ekleinod
-
mgrosse
-
nschult
-
smann
- Version:
- 0.10.0
- Since:
- 0.1
Constructor & Destructor Documentation
de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.Port |
( |
|
) |
|
Member Function Documentation
void de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.addDataElement |
( |
DataElement |
newDataElement |
) |
throws AXLException |
Adds e new data element.
- Parameters:
-
- Exceptions:
-
| AXLException | if element could not be added or if element is of another type. |
void de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.addOperation |
( |
Operation |
newOperation |
) |
throws AXLException |
Adds a new operation.
- Parameters:
-
| newOperation | the new operation |
- Exceptions:
-
| AXLException | if element could not be added |
void de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.addSignal |
( |
Signal |
newSignal |
) |
throws AXLException |
Adds a new signal.
- Parameters:
-
- Exceptions:
-
| AXLException | if element could not be added |
int de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.compareTo |
( |
IAXLangElement |
axlOther |
) |
|
Define sorting order.
Sorting order (smaller elements first):
- Richtung (Inports vor Outports)
- Optionalität (optionale Ports vor nichtoptionalen)
- Name des Ports
- Parameters:
-
- Returns:
- result of comparison
- Return values:
-
| <0 | this element is less than the other |
| 0 | this element equals the other |
| >0 | this element is greater than the other |
Reimplemented from de.fraunhofer.isst.axbench.axlang.api.AbstractAXLangElement.
void de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.elementAdded |
( |
IAXLangElement |
owner, |
|
|
ReferenceKind |
referenceKind, |
|
|
Role |
role, |
|
|
IAXLangElement |
addedElement | |
|
) |
| | |
if this a port of an xor-component this method reacts to changes of all ports that this port represents
if the alternative port has a new reference to a data element 1. add a corresponding xor-data element to the xor-component 2. add a reference to the xor-data element 3. add a data element link (alternative data element - xor-data element) to the delegation alternative port - xor-port (in the correct direction)
void de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.elementChanged |
( |
IAXLangElement |
owner, |
|
|
AXLangAttribute |
changedAttribute, |
|
|
String |
newValue, |
|
|
String |
oldValue | |
|
) |
| | |
if this is an xor port: reacts on the change of the value of one of the attributes (identifier, direction) of one of the alternatives
void de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.elementDeleted |
( |
IAXLangElement |
deletedElement |
) |
|
if this is an xor-port: reacts to the deletion of one of the alternatives
- Parameters:
-
| deletedElement | the alternative port that has been deleted |
void de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.elementRemoved |
( |
IAXLangElement |
owner, |
|
|
ReferenceKind |
referenceKind, |
|
|
Role |
role, |
|
|
IAXLangElement |
removedElement | |
|
) |
| | |
if this is an xor port: reacts on removal of a reference to a data element of one of the alternatives
- Parameters:
-
| owner | the element from which the old element has been removed |
| referenceKind | the reference kind in which the element has been removed: ReferenceKind:CHILD or ReferenceKind.REFERENCE |
| role | the role in which the element has been removed |
| removedElement | the removed element |
< indicates whether another alternative port still references the data element
Collection<DataElement> de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.getDataElements |
( |
|
) |
|
getter method for the collection of referenced data elements.
- Returns:
- collection of referenced data elements
Collection<Port> de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.getDelegatedPorts |
( |
|
) |
|
Returns the ports that are connected with this port via a delegation.
- Returns:
- ports in delegation connection
Direction de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.getDirection |
( |
|
) |
|
Returns direction.
- Returns:
- direction
HWPortType de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.getHWPortType |
( |
|
) |
|
Returns hardware port type.
- Returns:
- hw port type
Collection<ElementWithMessage> de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.getNonValidElements |
( |
|
) |
|
Collection<Operation> de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.getOperations |
( |
|
) |
|
Returns the operations.
- Returns:
- the operations
Collection<Signal> de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.getSignals |
( |
|
) |
|
Returns the signals.
- Returns:
- the signals
boolean de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.isClockElement |
( |
|
) |
|
Is this port a clock port?
- Returns:
- clock port?
- Return values:
-
| true | clock port |
| false | no clock port |
boolean de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.isCSPort |
( |
|
) |
|
Checks whether the port's interfaces contain only operations.
- Returns:
- true if the port's interfaces contain only operations, else false
boolean de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.isDependent |
( |
|
) |
|
Returns dependency.
A port is dependent if 1) it is the port of an XOR component and is not connected with all it's subcomponents, OR 2) it is the port of an XOR component and is connected to at least one optional or dependent port, OR 4) it is the port of a non-XOR component and it has a delegation to an optional or dependent port or to a port of an optional subcomponent, but it has not a delegation to a mandatory port of a mandatory subcomponent nor it is itself declared as optional 3)
- Todo:
check computation
maybe, the implementation is too strong: Consider the case, where an port is connected to a mandatory as well as an optional port of subcomponents. In this case, one can argue that the parent's port is mandatory (if there is no variance with respect to signals). --> the implementation is not so strong now, but was modified for XOR components.
- Returns:
- dependency
- Return values:
-
| true | == dependent |
| false | == not dependent |
boolean de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.isSRPort |
( |
|
) |
|
Checks whether the port's interfaces contain only signals.
- Returns:
- true if the port's interfaces contain only signals, else false
boolean de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.removeDataElement |
( |
DataElement |
theDataElement |
) |
|
Removes either a Signal or an Operation.
- Parameters:
-
- Returns:
- remove success
- Return values:
-
| true | reference was removed, or reference was null, or reference was not of type signal or operation |
| false | reference was not removed |
boolean de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.removeOperation |
( |
Operation |
theOperation |
) |
|
Removes the operation.
- Parameters:
-
| theOperation | the operation |
- Returns:
- remove success
- Return values:
-
| true | reference was removed, or reference was null |
| false | reference was not removed |
boolean de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.removeSignal |
( |
Signal |
theSignal |
) |
|
Removes the signal.
- Parameters:
-
- Returns:
- remove success
- Return values:
-
| true | reference was removed, or reference was null |
| false | reference was not removed |
void de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.setDirection |
( |
Direction |
newDirection |
) |
|
Sets direction.
- Parameters:
-
| newDirection | new direction |
void de.fraunhofer.isst.axbench.axlang.elements.architecturemodel.Port.setHWPortType |
( |
HWPortType |
newHWPortType |
) |
|
Sets hardware port type.
- Parameters:
-
| newHWPortType | new hw port type |
Member Data Documentation