/** * <p> * The type of API entities of the to-be-retrieved documentation parts. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #type} will return * {@link DocumentationPartType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #typeAsString}. * </p> * * @return The type of API entities of the to-be-retrieved documentation parts. * @see DocumentationPartType */ public DocumentationPartType type() { return DocumentationPartType.fromValue(type); }
/** * Use this in place of valueOf to convert the raw string returned by the service into the enum value. * * @param value * real value * @return DocumentationPartType corresponding to the value */ public static DocumentationPartType fromValue(String value) { if (value == null) { return null; } return Stream.of(DocumentationPartType.values()).filter(e -> e.toString().equals(value)).findFirst() .orElse(UNKNOWN_TO_SDK_VERSION); }
@Override public final Builder type(DocumentationPartType type) { this.type(type.toString()); return this; }
/** * Use this in place of {@link #values()} to return a {@link Set} of all values known to the SDK. This will return * all known enum values except {@link #UNKNOWN_TO_SDK_VERSION}. * * @return a {@link Set} of known {@link DocumentationPartType}s */ public static Set<DocumentationPartType> knownValues() { return Stream.of(values()).filter(v -> v != UNKNOWN_TO_SDK_VERSION).collect(toSet()); } }
@Override public final Builder type(DocumentationPartType type) { this.type(type.toString()); return this; }
@Override public final Builder type(DocumentationPartType type) { this.type(type.toString()); return this; }
/** * <p> * The type of API entities of the to-be-retrieved documentation parts. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #type} will return * {@link DocumentationPartType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #typeAsString}. * </p> * * @return The type of API entities of the to-be-retrieved documentation parts. * @see DocumentationPartType */ public DocumentationPartType type() { return DocumentationPartType.fromValue(type); }
/** * <p> * [Required] The type of API entity to which the documentation content applies. Valid values are <code>API</code>, * <code>AUTHORIZER</code>, <code>MODEL</code>, <code>RESOURCE</code>, <code>METHOD</code>, * <code>PATH_PARAMETER</code>, <code>QUERY_PARAMETER</code>, <code>REQUEST_HEADER</code>, <code>REQUEST_BODY</code>, <code>RESPONSE</code>, <code>RESPONSE_HEADER</code>, and <code>RESPONSE_BODY</code>. Content inheritance does * not apply to any entity of the <code>API</code>, <code>AUTHORIZER</code>, <code>METHOD</code>, <code>MODEL</code>, <code>REQUEST_BODY</code>, or <code>RESOURCE</code> type. * </p> * <p> * If the service returns an enum value that is not available in the current SDK version, {@link #type} will return * {@link DocumentationPartType#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service is available from * {@link #typeAsString}. * </p> * * @return [Required] The type of API entity to which the documentation content applies. Valid values are * <code>API</code>, <code>AUTHORIZER</code>, <code>MODEL</code>, <code>RESOURCE</code>, <code>METHOD</code> * , <code>PATH_PARAMETER</code>, <code>QUERY_PARAMETER</code>, <code>REQUEST_HEADER</code>, * <code>REQUEST_BODY</code>, <code>RESPONSE</code>, <code>RESPONSE_HEADER</code>, and * <code>RESPONSE_BODY</code>. Content inheritance does not apply to any entity of the <code>API</code>, * <code>AUTHORIZER</code>, <code>METHOD</code>, <code>MODEL</code>, <code>REQUEST_BODY</code>, or * <code>RESOURCE</code> type. * @see DocumentationPartType */ public DocumentationPartType type() { return DocumentationPartType.fromValue(type); }