import { ODataVersion } from '../base/odata-service.js'; import { ServiceProvider } from '../base/service-provider.js'; import { AppIndexService } from './app-index-service.js'; import type { CatalogService } from './catalog/index.js'; import { LayeredRepositoryService } from './lrep-service.js'; import type { AbapCDSView, AtoSettings, BusinessObject, ExternalService, ExternalServiceReference, SystemInfo } from './types/index.js'; import { Ui5AbapRepositoryService } from './ui5-abap-repository-service.js'; import { ODataServiceGenerator } from './adt-catalog/generators/odata-service-generator.js'; import { UiServiceGenerator } from './adt-catalog/generators/ui-service-generator.js'; import { type AdtService } from './adt-catalog/services/index.js'; import { UI5VersionService } from './ui5-version-service.js'; /** * Extension of the service provider for ABAP services. */ export declare class AbapServiceProvider extends ServiceProvider { protected atoSettings: AtoSettings; /** * Maintain the public facing URL which is required for destination related flows */ protected _publicUrl: string; /** * The connected system info */ protected _systemInfo: SystemInfo | undefined; /** * Get the name of the currently logged in user. This is the basic implementation that could be overwritten by subclasses. * The function returns a promise because it may be required to fetch the information from the backend. * * @returns the username */ user(): Promise; /** * Get user information. * * @returns user name or undefined */ getSystemInfo(): Promise; /** * Set the ATO settings for the provider so that it does not try to fetch them with the first request. * * @param atoSettings ABAP Transport Organizer settings */ setAtoInfo(atoSettings: AtoSettings): void; /** * Get the ATO settings either locally or from the server if not yet available. * * @returns ABAP Transport Organizer settings */ getAtoInfo(): Promise; /** * Set the public facing URL, typically used for a destination related flows. * * @param host */ set publicUrl(host: string); /** * Retrieve the public facing URL, default to Axios base URL if not configured. * * @returns string Axios baseUrl if public URL is not configured by a destination */ get publicUrl(): string; /** * Detect if the given configuration points to an S/4HANA Cloud system. * * @returns true if it an S/4HANA cloud system */ isAbapCloud(): Promise; /** * Create or get an existing instance of AdtCatalogService for fetching ADT schema. * * @returns AdtCatalogService */ private getAdtCatalogService; /** * Create or get an existing instance of the catalog service for the given OData version. * * @param version OData version of the requested catalog service * @returns an instance of the catalog service. */ catalog(version: ODataVersion): CatalogService; /** * Create or get an existing instance of the UI5 ABAP repository service. * * @param alias - optional alias path on which the UI5Repository service is exposed * @returns an instance of the UI5 ABAP repository service. */ getUi5AbapRepository(alias?: string): Ui5AbapRepositoryService; /** * Create or get an existing instance of the app index service. * * @returns an instance of the app index service. */ getAppIndex(): AppIndexService; /** * Create or get an existing instance of design time adaptation service. * * @param alias - optional alias path on which the LREP service is exposed * @returns an instance of the design time adaptation service. */ getLayeredRepository(alias?: string): LayeredRepositoryService; /** * Retrieve singleton instance of AdtService subclass to serve the specific ADT request query. * * @example * ```ts * const transportRequestService = abapServiceProvider.getAdtService(TransportRequestService); * ``` * @param adtServiceSubclass Subclass of class AdtService, type is specified by using AdtService class constructor signature. * @returns Subclass type of class AdtService */ getAdtService(adtServiceSubclass: typeof AdtService): Promise; /** * Creates a singleton instance of the UI5 version service using lazy initialization. * * @returns The instance to the UI5 version service. */ getUI5VersionService(): UI5VersionService; /** * Create a UI Service generator for the given referenced object. * * @param referencedObject - referenced object (business object or abap cds view) * @returns a UI Service generator */ getUiServiceGenerator(referencedObject: BusinessObject | AbapCDSView): Promise; /** * Gets an OData Service generator. * * @param packageName - Name of package to be used for generated artifacts in ABAP system * @returns An OData Service generator */ getODataServiceGenerator(packageName: string): Promise; /** * Collects ValueListReferences annotation values from the service metadata and annotation files. * * @param references - Service references for which metadata should be fetched. * @returns A list of ValueListReferences found in the metadata and annotations. */ fetchExternalServices(references: ExternalServiceReference[]): Promise; /** * Get the service URL from the generator config. * * @param config - generator config * @returns the service URL */ private getServiceUrlFromConfig; /** * @param config - generator config * @returns the type of the content link from service generator config */ private getContentType; /** * Create a service provider to lock a binding path. * * @param path - service binding path * @returns a service provider instance to lock the service binding */ createLockServiceBindingGenerator(path: string): Promise; } //# sourceMappingURL=abap-service-provider.d.ts.map