Class EventStreamInfo
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Gets all of the event stream events of the event stream.Gets the top-level input or output member that targets the event stream.Gets the shape that is streamed over the event stream.Gets the initial message members that form the initial-request or initial-response of the event stream.Gets the shapes targeted by the initial message members that are not the target of an event stream.Gets the operation associated with this data.Gets the event stream trait.Gets the input or output structure of the data.int
hashCode()
boolean
Returns true if the event stream has an initial-message, meaning there are top-level members of the input or output of the operation that are not the event stream member.
-
Method Details
-
getOperation
Gets the operation associated with this data.- Returns:
- Returns the associated operation.
-
getStreamingTrait
Gets the event stream trait.- Returns:
- Returns the event stream trait.
-
getStructure
Gets the input or output structure of the data.- Returns:
- Returns the structure.
-
getEventStreamMember
Gets the top-level input or output member that targets the event stream.- Returns:
- Returns the member.
-
getEventStreamTarget
Gets the shape that is streamed over the event stream.If the target shape is a structure, then the event stream is a single-event event stream that streams events of a single shape. If the target shape is a union, then the event stream is a multi-event event stream that streams one or more named events of various structure shapes.
- Returns:
- Returns a structure or union shape.
-
getInitialMessageMembers
Gets the initial message members that form the initial-request or initial-response of the event stream.The initial message members are the members of the input or output of an operation that are not the target of an event stream.
The returned map is a map of member names to
MemberShape
s. UsegetInitialMessageTargets()
to get a mapping of member names to the shapes targeted by a member.EventStreamIndex index = EventStreamIndex.of(model); EventStreamInfo info = index.getInputInfo(myShapeId); for (MemberShape member : info.getInitialMessageMembers()) { System.out.println("Initial message member: " + member); }
- Returns:
- Returns the initial event members (if any).
-
getInitialMessageTargets
Gets the shapes targeted by the initial message members that are not the target of an event stream.The returned map contains the same information as
getInitialMessageMembers()
except each value is the shape targeted by the member.- Returns:
- Returns the shapes targeted by the initial message members.
- See Also:
-
hasInitialMessage
public boolean hasInitialMessage()Returns true if the event stream has an initial-message, meaning there are top-level members of the input or output of the operation that are not the event stream member.- Returns:
- Returns true if there is an initial message.
-
getEvents
Gets all of the event stream events of the event stream.The returned map is a mapping of the event name to the event. For multi-event event streams, the name of hte event is the member name of the multi-event union. For single-event event streams, the name of the event is the name of the input or output structure member referenced by the event stream trait.
- Returns:
- Returns a map of event stream events.
-
equals
-
hashCode
public int hashCode()
-