RESOLVEDTYPE
- The resolved typepublic interface FormatStage<RESOLVEDTYPE extends ResolvedArtifact<RESOLVEDTYPE>>
RESOLVEDTYPE
is returned in the desired format.
Supports extensible formats by registering a FormatProcessor with the SPI.Modifier and Type | Method and Description |
---|---|
<RETURNTYPE> |
as(Class<RETURNTYPE> returnTypeClass)
Formats the resultant artifacts as an array of
type s. |
File[] |
asFile()
Formats the resultant artifacts as an array of
File s |
InputStream[] |
asInputStream()
Formats the resultant artifacts as an array of
InputStream s. |
<RETURNTYPE> |
asList(Class<RETURNTYPE> returnTypeClass)
Formats the resultant artifacts as a list of
type s. |
RESOLVEDTYPE[] |
asResolvedArtifact()
Formats the resultant artifacts as an array of
RESOLVEDTYPE . |
<RETURNTYPE> |
asSingle(Class<RETURNTYPE> returnTypeClass)
Formats the resultant artifact as a
type ; assumes a single artifact is returned from resolution. |
File |
asSingleFile()
Formats the resultant artifact as a
File ; assumes a single artifact is returned from resolution. |
InputStream |
asSingleInputStream()
Formats the resultant artifact as an
InputStream ; assumes a single artifact is returned from resolution. |
RESOLVEDTYPE |
asSingleResolvedArtifact()
Formats the resultant artifact as
RESOLVEDTYPE ; assumes a single artifact is returned from resolution. |
File[] asFile()
File
sFile
sFile asSingleFile() throws NonUniqueResultException, NoResolvedResultException
File
; assumes a single artifact is returned from resolution.File
NonUniqueResultException
- If the resolution resulted in more than one resultNoResolvedResultException
- If the resolution did not yield any resultInputStream[] asInputStream()
InputStream
s. It is a caller responsibility to close the streams
afterwards.InputStream
s.InputStream asSingleInputStream() throws NonUniqueResultException, NoResolvedResultException
InputStream
; assumes a single artifact is returned from resolution. It is a
caller responsibility to close the stream afterwards.InputStream
.NonUniqueResultException
- If the resolution resulted in more than one resultNoResolvedResultException
- If the resolution did not yield any resultRESOLVEDTYPE[] asResolvedArtifact()
RESOLVEDTYPE
.RESOLVEDTYPE
.RESOLVEDTYPE asSingleResolvedArtifact() throws NonUniqueResultException, NoResolvedResultException
RESOLVEDTYPE
; assumes a single artifact is returned from resolution.RESOLVEDTYPE
.NonUniqueResultException
- If the resolution resulted in more than one resultNoResolvedResultException
- If the resolution did not yield any result<RETURNTYPE> RETURNTYPE[] as(Class<RETURNTYPE> returnTypeClass) throws IllegalArgumentException, UnsupportedOperationException
type
s. If nothing matches resolution, an empty array will
be returned. Supports extensible formats by registering a FormatProcessor
for given returnTypeClass
.RETURNTYPE
- The return typereturnTypeClass
- The return type classtype
s.IllegalArgumentException
- If the type is not specifiedUnsupportedOperationException
- If the type is not supported *<RETURNTYPE> List<RETURNTYPE> asList(Class<RETURNTYPE> returnTypeClass) throws IllegalArgumentException, UnsupportedOperationException
type
s. If nothing matches resolution, an empty list will
be returned. Supports extensible formats by registering a FormatProcessor
for given returnTypeClass
.RETURNTYPE
- The return typereturnTypeClass
- The return type classtype
s.IllegalArgumentException
- If the type is not specifiedUnsupportedOperationException
- If the type is not supported *<RETURNTYPE> RETURNTYPE asSingle(Class<RETURNTYPE> returnTypeClass) throws IllegalArgumentException, UnsupportedOperationException, NonUniqueResultException, NoResolvedResultException
type
; assumes a single artifact is returned from resolution.
Supports extensible formats by registering a FormatProcessor
for given returnTypeClass
.RETURNTYPE
- The return typereturnTypeClass
- The return type classtype
.NonUniqueResultException
- If the resolution resulted in more than one resultNoResolvedResultException
- If the resolution did not yield any resultIllegalArgumentException
- If the type is not specifiedUnsupportedOperationException
- If the type is not supportedCopyright © 2017 JBoss by Red Hat. All rights reserved.