ApiNamespace

com.google.api.server.spi.config

Annotation Type ApiNamespace



  • @Retention(value=RUNTIME)
     @Target(value=TYPE)
    public @interface ApiNamespace
    Fields populated in Discovery in order to proper namespace generated clients.
    • Required Element Summary

      Required Elements 
      Modifier and Type Required Element and Description
      java.lang.String ownerDomain
      This is the domain name commonly associated with owner.
      java.lang.String ownerName
      This is a canonical company name obeying the same rules as the canonical API name.
    • Optional Element Summary

      Optional Elements 
      Modifier and Type Optional Element and Description
      java.lang.String packagePath
      This is an optional way to further scope a generated client library.
    • Element Detail

      • ownerDomain

        public abstract java.lang.String ownerDomain
        This is the domain name commonly associated with owner. If, for instance, this is an API owned by NASA, then "nasa.gov" would be a reasonable choice for domain name. It does not necessarily need to be the same as the serving domain, though the latter will be picked as a default if ownerDomain is not set. Required for a specified namespace.
      • ownerName

        public abstract java.lang.String ownerName
        This is a canonical company name obeying the same rules as the canonical API name. It obeys the exact capitalization a company would like to use to represent themselves. If their name is really two dwords, they are separated by spaces. E.g. "YouTube", "NASA" , "3Com", "Fox News". Required for a specified namespace.
      • packagePath

        public abstract java.lang.String packagePath
        This is an optional way to further scope a generated client library. It follows the same name rules for ownerName, with the restriction that words must be alphanumeric. This feature allows an enterprise to group one or more of their APIs from different Endpoints instances together in a logical space more fine-grained than just their domain name. If the package includes multiple words, each word will, when possible, be used as an additional level in the scope of the package.
        Default:
        ""