java.lang.Object
org.praxislive.core.Value
org.praxislive.core.types.PMap.MapBasedValue
org.praxislive.core.PortInfo
Information on the type, direction and properties for a
Port.-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.praxislive.core.Value
Value.Type<T extends Value> -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic PortInfocreate(Class<? extends Port> typeClass, PortInfo.Direction direction, PMap properties) Create a PortInfo.The direction of the port.Coerce the provided Value into a PortInfo if possible.static PortInfoParse the provided String into a PortInfo if possible.portType()The type of the port.Access the map of properties.Methods inherited from class org.praxislive.core.types.PMap.MapBasedValue
dataMap, equals, equivalent, hashCode, toString
-
Field Details
-
TYPE_NAME
Value type name.- See Also:
-
KEY_TYPE
Map key for port type name. Value should be the String fromPort.Type.name().- See Also:
-
KEY_DIRECTION
Map key for the port direction.- See Also:
-
-
Method Details
-
portType
The type of the port.- Returns:
- port type
-
direction
The direction of the port.- Returns:
- port direction
-
properties
Access the map of properties. The map includes the type and direction, as well as any custom or optional properties.This method is equivalent to calling
PMap.MapBasedValue.dataMap().- Returns:
- property map
-
create
public static PortInfo create(Class<? extends Port> typeClass, PortInfo.Direction direction, PMap properties) Create a PortInfo.- Parameters:
typeClass- port base classdirection- port directionproperties- additional properties (may be null)- Returns:
- port info
-
from
Coerce the provided Value into a PortInfo if possible.- Parameters:
arg- value of unknown type- Returns:
- port info or empty optional
-
parse
Parse the provided String into a PortInfo if possible.- Parameters:
string- text to parse- Returns:
- port info
- Throws:
ValueFormatException- if parsing fails
-