org.apache.olingo.ext.proxy

## Class AbstractService<C extends EdmEnabledODataClient>

- java.lang.Object
- - org.apache.olingo.ext.proxy.AbstractService<C>

- Type Parameters:
    `C` - actual client class

      public abstract class AbstractService<C extends EdmEnabledODataClient>
      extends Object

  Entry point for proxy mode, gives access to entity container instances.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected static org.slf4j.Logger` | `LOG`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `AbstractService(String compressedMetadata, String metadataETag, ODataServiceVersion version, String serviceRoot, boolean transactional)`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected Set<String>` | `getAllowedClasses()` Returns a set of classes which are allowed for deserialization.
    `C` | `getClient()`
    `abstract Class<?>` | `getComplexTypeClass(String name)`
    `Context` | `getContext()`
    `<T> T` | `getEntityContainer(Class<T> reference)` Return an initialized concrete implementation of the passed EntityContainer interface.
    `abstract Class<?>` | `getEntityTypeClass(String name)`
    `abstract Class<?>` | `getEnumTypeClass(String name)`
    `PersistenceManager` | `getPersistenceManager()`
    `abstract Class<? extends AbstractTerm>` | `getTermClass(String name)`
    `boolean` | `isTransactional()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### LOG

          protected static final org.slf4j.Logger LOG

  - ### Constructor Detail

    - #### AbstractService

          protected AbstractService(String compressedMetadata,
                                    String metadataETag,
                                    ODataServiceVersion version,
                                    String serviceRoot,
                                    boolean transactional)

  - ### Method Detail

    - #### getEntityTypeClass

          public abstract Class<?> getEntityTypeClass(String name)

    - #### getComplexTypeClass

          public abstract Class<?> getComplexTypeClass(String name)

    - #### getEnumTypeClass

          public abstract Class<?> getEnumTypeClass(String name)

    - #### getTermClass

          public abstract Class<? extends AbstractTerm> getTermClass(String name)

    - #### getClient

          public C getClient()

    - #### getContext

          public Context getContext()

    - #### isTransactional

          public boolean isTransactional()

    - #### getPersistenceManager

          public PersistenceManager getPersistenceManager()

    - #### getEntityContainer

          public <T> T getEntityContainer(Class<T> reference)
                                   throws IllegalStateException,
                                          IllegalArgumentException

      Return an initialized concrete implementation of the passed EntityContainer interface.
      Type Parameters:
        `T` - interface annotated as EntityContainer
      Parameters:
        `reference` - class object of the EntityContainer annotated interface
      Returns:
        an initialized concrete implementation of the passed reference
      Throws:
        `IllegalArgumentException` - if the passed reference is not an interface annotated as EntityContainer
        `IllegalStateException`

    - #### getAllowedClasses

          protected Set<String> getAllowedClasses()

      Returns a set of classes which are allowed for deserialization.
      By default, only classes from the "org.apache.olingo" package are allowed. Subclasses should override this method if they expect other classes to be deserialized.
      Returns:
        A set of classes which are allowed for deserialization.

Copyright © 2013–2022 The Apache Software Foundation. All rights reserved.