All Downloads are FREE. Search and download functionalities are using the official Maven repository.

Java.libraries.jersey2.additional_properties.mustache Maven / Gradle / Ivy

There is a newer version: 7.6.0
Show newest version
{{#additionalPropertiesType}}
  /**
   * A container for additional, undeclared properties.
   * This is a holder for any undeclared properties as specified with
   * the 'additionalProperties' keyword in the OAS document.
   */
  private Map additionalProperties;

  /**
   * Set the additional (undeclared) property with the specified name and value.
   * If the property does not already exist, create it otherwise replace it.
   */
  @JsonAnySetter
  public {{classname}} putAdditionalProperty(String key, {{{.}}} value) {
    if (this.additionalProperties == null) {
        this.additionalProperties = new HashMap<>();
    }
    this.additionalProperties.put(key, value);
    return this;
  }

  /**
   * Return the additional (undeclared) property.
   */
  @JsonAnyGetter
  public Map getAdditionalProperties() {
    return additionalProperties;
  }

  /**
   * Return the additional (undeclared) property with the specified name.
   */
  public {{{.}}} getAdditionalProperty(String key) {
    if (this.additionalProperties == null) {
        return null;
    }
    return this.additionalProperties.get(key);
  }
{{/additionalPropertiesType}}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy