Class DynamicModelUtils

java.lang.Object
com.sap.cds.services.utils.model.DynamicModelUtils

public class DynamicModelUtils extends Object
  • Constructor Details

    • DynamicModelUtils

      public DynamicModelUtils(CdsRuntime runtime)
  • Method Details

    • useStaticModel

      public boolean useStaticModel()
      Returns true, if the static model, packaged with the application, can be loaded Retrieves the required information from the current RequestContext
      Returns:
      true, if the static model, packaged with the application, can be loaded
    • useStaticModel

      public boolean useStaticModel(UserInfo userInfo, FeatureTogglesInfo featureTogglesInfo)
      Returns true, if the static model, packaged with the application, can be loaded
      Parameters:
      userInfo - the UserInfo
      featureTogglesInfo - the FeatureTogglesInfo
      Returns:
      true, if the static model, packaged with the application, can be loaded
    • prepareModelId

      public ModelId.Builder prepareModelId(UserInfo userInfo, FeatureTogglesInfo featureTogglesInfo)
      Prepares the ModelId with tenant and feature toggles dimension, depending on the configuration
      Parameters:
      userInfo - the UserInfo
      featureTogglesInfo - the FeatureTogglesInfo
      Returns:
      the ModelId with tenant and feature toggles dimension, depending on the configuration
    • isModelProviderEnabled

      public boolean isModelProviderEnabled()
      Returns:
      true if ModelProviderService is configured
    • getModelProviderUrl

      public String getModelProviderUrl()
    • createMetadataAccessor

    • getResilienceConfig

      public ResilienceConfig getResilienceConfig()
    • createSidecarDestination

      public com.sap.cloud.sdk.cloudplatform.connectivity.HttpDestination createSidecarDestination(String destinationName, String targetUrl)