FieldNamingStrategy (Gson 2.3.1 API)
Date: 2014-11-20

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.google.gson
Interface FieldNamingStrategy

All Known Implementing Classes:
  FieldNamingPolicy

    public interface FieldNamingStrategy

A mechanism for providing custom field naming in Gson. This allows the client code to translate field names into a particular convention that is not supported as a normal Java field declaration rules. For example, Java does not support "-" characters in a field name.

Since:
  1.3
Author:
  Inderjeet Singh, Joel Leitch

Method Summary
`String` | `translateName(Field f)` Translates the field name into its JSON field name representation.

Method Detail

### translateName

    String translateName(Field f)

  Translates the field name into its JSON field name representation.

  Parameters:
    `f` - the field object that we are translating
  Returns:
    the translated field name.
  Since:
    1.3

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008–2014 Google, Inc.. All rights reserved.