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

com.amazonaws.codegen.naming.NamingStrategy Maven / Gradle / Ivy

Go to download

The AWS SDK for Java - Code Generator module holds the classes and templates required to generate the AWS Java SDK clients for AWS services.

There is a newer version: 1.11.8
Show newest version
/*
 * Copyright (c) 2016. Amazon.com, Inc. or its affiliates. All Rights Reserved.
 *
 * Licensed under the Apache License, Version 2.0 (the "License").
 * You may not use this file except in compliance with the License.
 * A copy of the License is located at
 *
 * http://aws.amazon.com/apache2.0
 *
 * or in the "license" file accompanying this file. This file is distributed
 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
 * express or implied. See the License for the specific language governing
 * permissions and limitations under the License.
 */
package com.amazonaws.codegen.naming;

/**
 * Strategy to name various Java constructs based on the naming in the model and potentially
 * customizations.
 */
public interface NamingStrategy {

    /**
     * @param errorShapeName Name of error shape to derive exception class name from.
     * @return Appropriate name to use for a Java exception class name
     */
    String getExceptionName(String errorShapeName);


    /**
     * @param operationName Name of operation used to derive request class name.
     * @return Appropriate name to use for the Java class representing the request shape.
     */
    String getRequestClassName(String operationName);

    /**
     * @param operationName Name of operation used to derive response class name.
     * @return Appropriate name to use for the Java class representing the response shape.
     */
    String getResponseClassName(String operationName);

    /**
     * @param name Some contextual name to derive variable name from (i.e. member name, java class
     *             name, etc).
     * @return Appropriate name to use for a Java variable or field.
     */
    String getVariableName(String name);

    /**
     * @param enumValue Enum value as defined in the service model used to derive the java name.
     * @return Appropriate name to use for a Java enum value
     */
    String getEnumValueName(String enumValue);

    /**
     * @param shapeName Name of structure used to derive Java class name.
     * @return Appropriate name to use for a Java class for an arbitrary (not a request, response,
     * error) structure.
     */
    String getJavaClassName(String shapeName);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy