Class Operation.Builder<T extends Operation.Builder<T>>

    • Constructor Detail

      • Builder

        protected Builder()
        Creates a new Builder.
    • Method Detail

      • self

        protected abstract T self()
        Abstract method that returns the instantiated Builder itself.
        Returns:
        Builder
      • description

        public T description​(LocalizableString description)
        Set the description.
        Parameters:
        description - A description of the endpoint
        Returns:
        Builder
      • description

        public T description​(String description)
        Set the description.
        Parameters:
        description - A description of the endpoint
        Returns:
        Builder
      • supportedLocales

        public T supportedLocales​(String... supportedlocales)
        Set the supported locale.
        Parameters:
        supportedlocales - Locales codes supported by the operation
        Returns:
        Builder
      • errors

        public T errors​(List<ApiError> apiErrors)
        Set multiple supported errors.
        Parameters:
        apiErrors - What errors may be returned by this operation
        Returns:
        Builder
      • error

        public T error​(ApiError apiError)
        Sets a single supported error.
        Parameters:
        apiError - An error that may be returned by this operation
        Returns:
        Builder
      • parameters

        public T parameters​(List<Parameter> parameters)
        Set multiple supported parameters.
        Parameters:
        parameters - Extra parameters supported by the operation
        Returns:
        Builder
      • parameter

        public T parameter​(Parameter parameter)
        Sets a single supported parameters.
        Parameters:
        parameter - Extra parameter supported by the operation
        Returns:
        Builder
      • stability

        public T stability​(Stability stability)
        Sets stability of Operation.
        Parameters:
        stability - Stability
        Returns:
        Builder
      • detailsFromAnnotation

        public T detailsFromAnnotation​(Operation operation,
                                       ApiDescription descriptor,
                                       Class<?> relativeType)
        Set all properties in the Builder using the data in the annotation.
        Parameters:
        operation - The annotation that holds the data
        descriptor - The root descriptor
        relativeType - The type relative to which schema resources should be resolved.
        Returns:
        Builder