summaryrefslogtreecommitdiffstats
path: root/cds-ui/designer-client/src/app/modules/feature-modules/packages/package-creation/mapping-models/definitions/VlbDefinition.ts
blob: 2d5e520ee9c92b89c3e15bb07e458a706b28d4be (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
import {Any, JsonObject, JsonProperty} from 'json2typescript';


@JsonObject
export class VlbDefinition {

    // tslint:disable-next-line:variable-name
    tosca_definitions_version: string;
    metadata: Metadata;
    imports: Import[];
    // dsl_definitions:           DSLDefinitions;
    // topology_template: TopologyTemplate;
}

@JsonObject('metadata')
export class Metadata {
    @JsonProperty('template_author')
     // tslint:disable-next-line:variable-name
    template_author: string;
    'author-email': string;
    'user-groups': string;
    @JsonProperty('template_name')
        // tslint:disable-next-line:variable-name
    template_name: string;
    @JsonProperty('template_version')
        // tslint:disable-next-line:variable-name
    template_version: string;
    @JsonProperty('template_tag')
        // tslint:disable-next-line:variable-name
    template_tags: string;

    @JsonProperty('dictionary_group')
        // tslint:disable-next-line:variable-name
    dictionary_group: string;


    /* @JsonProperty('custom_keys', {String}, false)
     mapOfCustomKeys: Map<string, string> = new Map<string, string>();*/
}

export class Import {
    file: string;
}
ramework automatically delivers these commands as part of the OCLIP zip file as part of this build. #. To test this command, run the command 'oclip hello-world --name amsterdam' As a YAML --------- All OCLIP commands can be implemented as YAML using HTTP profile. Follow the steps below to implement new commands for ONAP using YAML: #. Install the latest OCLIP using the guide :ref:`cli_installation_guide`. #. Under the open-cli-schema folder, add a new YAML file by referring to :ref:`open_cli_schema_version_1_0`. #. Use the command 'oclip schema-validate' to validate the YAML before testing its functionality. #. Run 'oclip schema-refresh' command to take the new YAML file. We recommended validating the YAML before running this command. #. To test this command, run the command 'oclip CMD-NAME --help'. Sample YAML ~~~~~~~~~~~~ Find more details about YAML specification at :ref:`open_cli_schema_version_1_0`. Sample hello-world YAML :: open_cli_schema_version: 1.0 name: hello-world-http description: First cmd hello world using http running under lighttpd in cli at http://<cli-ip>:8080/version.json version: sample-1.0 parameters: - name: name description: name of the person long_option: name short_option: b default_value: ${DEMO_NAME} type: string is_optional: false results: direction: landscape attributes: - name: output description: hello world output type: string scope: short http: request: uri: /version.json method: GET service: name: sample-service version: v1 auth: none mode: direct success_codes: - 200 - 201 result_map: output: Hello ${name}, You are running on $b{$.name} $b{$.version}