
com.sap.cloud.sdk.s4hana.datamodel.odata.services.DefaultStatisticalKeyFigureService Maven / Gradle / Ivy
/*
* Copyright (c) 2019 SAP SE or an SAP affiliate company. All rights reserved.
*/
package com.sap.cloud.sdk.s4hana.datamodel.odata.services;
import javax.annotation.Nonnull;
import javax.inject.Named;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigure;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureByKeyFluentHelper;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureCreateFluentHelper;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureDeleteFluentHelper;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureFluentHelper;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureText;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureTextByKeyFluentHelper;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureTextCreateFluentHelper;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureTextDeleteFluentHelper;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureTextFluentHelper;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureTextUpdateFluentHelper;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.StatisticalKeyFigureUpdateFluentHelper;
import com.sap.cloud.sdk.s4hana.datamodel.odata.namespaces.statisticalkeyfigure.batch.DefaultStatisticalKeyFigureServiceBatch;
/**
*
* This service enables you to create, read, update, or delete the master data of statistical key figures.
*
*
*
* Reference: SAP
* API Business Hub
*
* Details:
*
*
* OData Service:
* API_STATISTICALKEYFIGURE_SRV
*
*
* API Version:
* 1
*
*
* Communication Scenario:
* Finance - Statistical Key Figure Integration (SAP_COM_0130)
*
*
* Scope Items:
* Overhead Cost Accounting (J54)
*
*
* Authentication Methods:
* Basic, x509
*
*
*
*/
@Named( "com.sap.cloud.sdk.s4hana.datamodel.odata.services.DefaultStatisticalKeyFigureService" )
public class DefaultStatisticalKeyFigureService implements StatisticalKeyFigureService
{
@Nonnull
private final String servicePath;
/**
* Creates a service using {@link StatisticalKeyFigureService#DEFAULT_SERVICE_PATH} to send the requests.
*
*/
public DefaultStatisticalKeyFigureService()
{
servicePath = StatisticalKeyFigureService.DEFAULT_SERVICE_PATH;
}
/**
* Creates a service using the provided service path to send the requests.
*
* Used by the fluent {@link #withServicePath(String)} method.
*
*/
private DefaultStatisticalKeyFigureService( @Nonnull final String servicePath )
{
this.servicePath = servicePath;
}
@Override
@Nonnull
public DefaultStatisticalKeyFigureService withServicePath( @Nonnull final String servicePath )
{
return new DefaultStatisticalKeyFigureService(servicePath);
}
/**
* {@inheritDoc}
*
*/
@Override
@Nonnull
public DefaultStatisticalKeyFigureServiceBatch batch()
{
return new DefaultStatisticalKeyFigureServiceBatch(this);
}
@Override
@Nonnull
public StatisticalKeyFigureFluentHelper getAllStatisticalKeyFigure()
{
return new StatisticalKeyFigureFluentHelper(servicePath);
}
@Override
@Nonnull
public
StatisticalKeyFigureByKeyFluentHelper
getStatisticalKeyFigureByKey( final String statisticalKeyFigure, final String controllingArea )
{
return new StatisticalKeyFigureByKeyFluentHelper(servicePath, statisticalKeyFigure, controllingArea);
}
@Override
@Nonnull
public StatisticalKeyFigureCreateFluentHelper createStatisticalKeyFigure(
@Nonnull final StatisticalKeyFigure statisticalKeyFigure )
{
return new StatisticalKeyFigureCreateFluentHelper(servicePath, statisticalKeyFigure);
}
@Override
@Nonnull
public StatisticalKeyFigureUpdateFluentHelper updateStatisticalKeyFigure(
@Nonnull final StatisticalKeyFigure statisticalKeyFigure )
{
return new StatisticalKeyFigureUpdateFluentHelper(servicePath, statisticalKeyFigure);
}
@Override
@Nonnull
public StatisticalKeyFigureDeleteFluentHelper deleteStatisticalKeyFigure(
@Nonnull final StatisticalKeyFigure statisticalKeyFigure )
{
return new StatisticalKeyFigureDeleteFluentHelper(servicePath, statisticalKeyFigure);
}
@Override
@Nonnull
public StatisticalKeyFigureTextFluentHelper getAllStatisticalKeyFigureText()
{
return new StatisticalKeyFigureTextFluentHelper(servicePath);
}
@Override
@Nonnull
public StatisticalKeyFigureTextByKeyFluentHelper getStatisticalKeyFigureTextByKey(
final String language,
final String controllingArea,
final String statisticalKeyFigure )
{
return new StatisticalKeyFigureTextByKeyFluentHelper(
servicePath,
language,
controllingArea,
statisticalKeyFigure);
}
@Override
@Nonnull
public StatisticalKeyFigureTextCreateFluentHelper createStatisticalKeyFigureText(
@Nonnull final StatisticalKeyFigureText statisticalKeyFigureText )
{
return new StatisticalKeyFigureTextCreateFluentHelper(servicePath, statisticalKeyFigureText);
}
@Override
@Nonnull
public StatisticalKeyFigureTextUpdateFluentHelper updateStatisticalKeyFigureText(
@Nonnull final StatisticalKeyFigureText statisticalKeyFigureText )
{
return new StatisticalKeyFigureTextUpdateFluentHelper(servicePath, statisticalKeyFigureText);
}
@Override
@Nonnull
public StatisticalKeyFigureTextDeleteFluentHelper deleteStatisticalKeyFigureText(
@Nonnull final StatisticalKeyFigureText statisticalKeyFigureText )
{
return new StatisticalKeyFigureTextDeleteFluentHelper(servicePath, statisticalKeyFigureText);
}
}