@salesforce/source-deploy-retrieve
Version:
JavaScript library to run Salesforce metadata deploys and retrieves
54 lines (53 loc) • 2.14 kB
TypeScript
import { SourcePath } from '../../common/types';
import { SourceComponent } from '../sourceComponent';
import { MetadataXml } from '../types';
import { BundleSourceAdapter } from './bundleSourceAdapter';
/**
* Source Adapter for DigitalExperience metadata types. This metadata type is a bundled type of the format
*
* __Example Structure__:
*
*```text
* site/
* ├── foos/
* | ├── sfdc_cms__appPage/
* | | ├── mainAppPage/
* | | | ├── _meta.json
* | | | ├── content.json
* | ├── sfdc_cms__view/
* | | ├── view1/
* | | | ├── _meta.json
* | | | ├── content.json
* | | | ├── fr.json
* | | | ├── en.json
* | | ├── view2/
* | | | ├── _meta.json
* | | | ├── content.json
* | | | ├── ar.json
* | | ├── view3/
* | | | ├── _meta.json
* | | | ├── content.json
* | | | ├── mobile/
* | | | | ├──mobile.json
* | | | ├── tablet/
* | | | | ├──tablet.json
* | ├── foos.digitalExperience-meta.xml
* content/
* ├── bars/
* | ├── bars.digitalExperience-meta.xml
* ```
*
* In the above structure the metadata xml file ending with "digitalExperience-meta.xml" belongs to DigitalExperienceBundle MD type.
* The "_meta.json" files are child metadata files of DigitalExperienceBundle belonging to DigitalExperience MD type. The rest of the files in the
* corresponding folder are the contents to the DigitalExperience metadata. So, incase of DigitalExperience the metadata file is a JSON file
* and not an XML file
*/
export declare class DigitalExperienceSourceAdapter extends BundleSourceAdapter {
protected getRootMetadataXmlPath(trigger: string): string;
protected trimPathToContent(path: string): string;
protected populate(trigger: string, component?: SourceComponent): SourceComponent;
protected parseMetadataXml(path: SourcePath): MetadataXml | undefined;
private getBundleName;
private getBundleMetadataXmlPath;
private isBundleType;
}