RSDCollectionResult
public protocol RSDCollectionResult : RSDResult, RSDAnswerResultFinder
RSDCollectionResult is used include multiple results associated with a single step or async action that
may have more that one result.
-
The list of input results associated with this step. These are generally assumed to be answers to field inputs, but they are not required to implement the
RSDAnswerResultprotocol.Declaration
Swift
var inputResults: [RSDResult]
-
findResult(with:)Extension methodFind a result within this collection.
Declaration
Swift
public func findResult(with identifier: String) -> RSDResult?Parameters
identifierThe identifier associated with the result.
Return Value
The result or
nilif not found. -
findAnswerResult(with:)Extension methodFind an answer result within this collection. This method will return
nilif there is a result but that result does not conform to to theRSDAnswerResultprotocol.Seealso
Declaration
Swift
public func findAnswerResult(with identifier:String ) -> RSDAnswerResult?Parameters
identifierThe identifier associated with the result.
Return Value
The result or
nilif not found. -
appendInputResults(with:)Extension methodAppend the result to the end of the input results, replacing the previous instance with the same identifier.
Parameters
resultThe result to add to the input results.
Return Value
The previous result or
nilif there wasn’t one. -
removeInputResult(with:)Extension methodAppend the result to the end of the input results, replacing the previous instance with the same identifier.
Declaration
Swift
mutating public func removeInputResult(with identified: String) -> RSDResult?Parameters
resultThe result to add to the input results.
Return Value
The previous result or
nilif there wasn’t one.
View on GitHub
RSDCollectionResult Protocol Reference