if [ ! -d ./open-cli-schema ]; then mkdir ./open-cli-schema; fi
chmod +x ./bin/oclip.sh
-#Make onap available in path
+#Make oclip available in path
ln ./bin/oclip.sh $CLI_BIN
#Print the version
import org.onap.cli.fw.utils.OnapCommandUtils;
/**
- * Onap Command.
+ * Oclip Command.
*
*/
public abstract class OnapCommand {
}
/**
- * Onap command description, defined by derived command.
+ * Oclip command description, defined by derived command.
*/
public String getDescription() {
return this.cmdDescription;
}
/*
- * Onap command name like user-create, ns-list, etc , defined by derived command
+ * Oclip command name like user-create, ns-list, etc , defined by derived command
*/
public String getName() {
return this.cmdName;
}
/*
- * Onap command input parameters, defined by derived command
+ * Oclip command input parameters, defined by derived command
*/
public List<OnapCommandParameter> getParameters() {
return this.cmdParameters;
}
/*
- * Onap command input parameters, defined by derived command
+ * Oclip command input parameters, defined by derived command
*/
public Map<String, OnapCommandParameter> getParametersMap() {
return OnapCommandUtils.getInputMap(this.getParameters());
}
/*
- * Onap command output results, defined by derived command
+ * Oclip command output results, defined by derived command
*/
public OnapCommandResult getResult() {
return this.cmdResult;
}
/**
- * Onap command execute with given parameters on service. Before calling this method, its mandatory to set all
+ * Oclip command execute with given parameters on service. Before calling this method, its mandatory to set all
* parameters value.
*
* @throws OnapCommandException
/**
- * Onap Command registrar provides a common place, where every command would get registered automatically when its
+ * Oclip Command registrar provides a common place, where every command would get registered automatically when its
* loaded into JVM.
*
*/
}
/**
- * Helps to find the Onap CLI version, could be used with --version or -v option.
+ * Helps to find the Oclip CLI version, could be used with --version or -v option.
*
* @return string
*/
/**
* Provide command name and schema file location, which is placed in the main resources folder (in classpath). It is
- * recommended to keep the name for schema, in the form of onap-[command-name]-schema.yaml, considered this format as
+ * recommended to keep the name for schema, in the form of oclip-[command-name]-schema.yaml, considered this format as
* default if the schema declaration is missing for a command abc-create, schema file name could be
* abc-create-schema.yaml, corresponding command would like as below
*
import org.onap.cli.fw.utils.OnapCommandUtils;
/**
- * Onap Auth client helps to do login and logout.
+ * Oclip Auth client helps to do login and logout.
*
*/
public class OnapAuthClient {
import org.onap.cli.fw.conf.Constants;
/**
- * Onap Service as reported in api catalog.
+ * Oclip Service as reported in api catalog.
*/
public class OnapService {
/*
- * Onap Service name like aai.
+ * Oclip Service name like aai.
*/
private String serviceName;
/*
- * Onap Service API version like v1, v2, etc
+ * Oclip Service API version like v1, v2, etc
*/
private String serviceVersion;
import org.onap.cli.fw.error.OnapCommandInvalidParameterType;
/**
- * Command type supported by Onap CLI.
+ * Command type supported by Oclip CLI.
*
*/
public enum CommandType {
import org.onap.cli.http.mock.MockResponse;
/**
- * Onap Command.
+ * Oclip Command.
*
*/
public class OnapHttpCommand extends OnapCommand {
protected OnapAuthClient authClient;
- private OnapService onapService = new OnapService();
+ private OnapService oclipService = new OnapService();
public void setInput(HttpInput input) {
this.input = input;
}
/*
- * Onap service, this command uses to execute it.
+ * Oclip service, this command uses to execute it.
*/
public OnapService getService() {
- return this.onapService;
+ return this.oclipService;
}
public void setService(OnapService service) {
- this.onapService = service;
+ this.oclipService = service;
}
@Override
import java.util.stream.Collectors;
/**
- * Onap command constants.
+ * Oclip command constants.
*
*/
public final class OnapCommandConfg {
package org.onap.cli.fw.error;
/**
- * Command Not registered in Onap Command Registrar.
+ * Command Not registered in Oclip Command Registrar.
*
*/
public class OnapCommandRegistrationFailed extends OnapCommandException {
package org.onap.cli.fw.error;
/**
- * Command Not registered in Onap Command Registrar as version missing.
+ * Command Not registered in Oclip Command Registrar as version missing.
*
*/
public class OnapCommandRegistrationProductInfoMissing extends OnapCommandException {
import org.onap.cli.fw.cmd.CommandType;
/**
- * Onap Command info like product version, service, contact, etc.
+ * Oclip Command info like product version, service, contact, etc.
*/
public class OnapCommandInfo {
import java.util.UUID;
/**
- * Onap Command's input parameter.
+ * Oclip Command's input parameter.
*
*/
public class OnapCommandParameter {
import org.onap.cli.fw.error.OnapCommandInvalidParameterType;
/**
- * Parameter type supported by Onap CLI.
+ * Parameter type supported by Oclip CLI.
*
*/
public enum ParameterType {
import java.util.Map;
/**
- * Onap Command result holds the final output of the command.
+ * Oclip Command result holds the final output of the command.
*
*/
public class OnapCommandResult {
/*
- * if type=JSON, then JSON response of the command from back-end Onap service, by default all the command would
+ * if type=JSON, then JSON response of the command from back-end Oclip service, by default all the command would
* set this value once the back-end call returns, which would be useful to print the output in JSON format, returned
* from the back-end service.
*
import java.util.List;
/**
- * Onap command output records, helps to define the title and its description while command is defined and during run
+ * Oclip command output records, helps to define the title and its description while command is defined and during run
* time, it captures the value of the output as well.
*/
public class OnapCommandResultAttribute {
import org.onap.cli.fw.error.OnapCommandInvalidResultAttributeScope;
/**
- * Onap command supports to print output with given set of defined attributes, and each attributes are marked with this
+ * Oclip command supports to print output with given set of defined attributes, and each attributes are marked with this
* visibility.
*
*/
package org.onap.cli.fw.output;
/**
- * Onap command result format.
+ * Oclip command result format.
*
*/
public enum ResultType {
import java.util.StringTokenizer;
/**
- * Onap Command Table print.
+ * Oclip Command Table print.
*
*/
public class OnapCommandPrint {
package org.onap.cli.fw.run;
/**
- * Onap Command executor.
+ * Oclip Command executor.
*
*/
public class OnapCommandExecutor {
}
/**
- * Discover the Onap commands.
+ * Discover the Oclip commands.
*
* @return list
*/
open_cli_schema_version: 1.0
name: schema-refresh
-description: Onap command to refresh schemas stored in open_cli_schema folders.
+description: Oclip command to refresh schemas stored in open_cli_schema folders.
info:
product: open-cli
open_cli_schema_version: 1.0
name: schema-validate
-description: Onap command to validate schema
+description: Oclip command to validate schema
info:
product: open-cli
}
@Test
- public void onapCommandNotFoundTest() throws OnapCommandException {
+ public void oclipCommandNotFoundTest() throws OnapCommandException {
try {
registerar = OnapCommandRegistrar.getRegistrar();
registerar.get("Test1");
}
@Test
- public void onapCommandRegistrationFailedTest() throws OnapCommandException {
+ public void oclipCommandRegistrationFailedTest() throws OnapCommandException {
@OnapCommandSchema(schema = "sample-test-schema.yaml")
class Test extends OnapCommand {
cmd.initializeSchema("schema-refresh.yaml");
cmd.execute();
- List<OnapCommandResultAttribute> onapCommandResultAttribute = cmd.getResult()
+ List<OnapCommandResultAttribute> oclipCommandResultAttribute = cmd.getResult()
.getRecords();
- String s1Number = onapCommandResultAttribute.get(0).getValues().get(0);
- String cmdName = onapCommandResultAttribute.get(1).getValues().get(0);
- String cmdVer = onapCommandResultAttribute.get(2).getValues().get(0);
- String cmdFile = onapCommandResultAttribute.get(3).getValues().get(0);
- String version = onapCommandResultAttribute.get(4).getValues().get(0);
+ String s1Number = oclipCommandResultAttribute.get(0).getValues().get(0);
+ String cmdName = oclipCommandResultAttribute.get(1).getValues().get(0);
+ String cmdVer = oclipCommandResultAttribute.get(2).getValues().get(0);
+ String cmdFile = oclipCommandResultAttribute.get(3).getValues().get(0);
+ String version = oclipCommandResultAttribute.get(4).getValues().get(0);
assertTrue(s1Number.equalsIgnoreCase("1"));
}
public class OnapCommandErrorTest {
@Test
- public void onapCommandDiscoveryFailedTest() {
+ public void oclipCommandDiscoveryFailedTest() {
OnapCommandDiscoveryFailed failed = new OnapCommandDiscoveryFailed("name");
assertEquals("0x1001::Failed auto discover schema files from name under class path, ", failed.getMessage());
failed = new OnapCommandDiscoveryFailed("directory", "name");
}
@Test
- public void onapCommandInvalidParameterValueTest() {
+ public void oclipCommandInvalidParameterValueTest() {
OnapCommandInvalidParameterValue failed = new OnapCommandInvalidParameterValue("name");
assertEquals("0x7002::Parameter name value is invalid, ", failed.getMessage());
}
@Test
- public void onapCommandResultMapProcessingFailedTest() {
+ public void oclipCommandResultMapProcessingFailedTest() {
OnapCommandResultMapProcessingFailed failed = new OnapCommandResultMapProcessingFailed("name",
new Exception("failed"));
assertEquals("0x3002::Failed to parse the result format of command name, failed", failed.getMessage());
}
@Test
- public void onapCommandHttpHeaderNotFoundTest() {
+ public void oclipCommandHttpHeaderNotFoundTest() {
OnapCommandHttpHeaderNotFound failed = new OnapCommandHttpHeaderNotFound("name");
assertEquals("0x3003::Http header name is not returned from the service", failed.getMessage());
}
@Test
- public void onapCommandClientInitialzationFailedTest() {
+ public void oclipCommandClientInitialzationFailedTest() {
OnapCommandClientInitialzationFailed failed = new OnapCommandClientInitialzationFailed("Test",
new Exception("Test Command Failed"));
assertEquals("0x5001::API client for the command Test is failed, Test Command Failed", failed.getMessage());
}
@Test
- public void onapCommandExceptionTest1() {
+ public void oclipCommandExceptionTest1() {
OnapCommandException failed = new OnapCommandException("1", "Test Command Failed");
assertEquals("1::Test Command Failed", failed.getMessage());
}
@Test
- public void onapCommandExceptionTest2() {
+ public void oclipCommandExceptionTest2() {
OnapCommandException failed = new OnapCommandException("1", "Test Command Failed", 201);
assertEquals("201::1::Test Command Failed", failed.getMessage());
}
@Test
- public void onapCommandExecutionFailedTest1() {
+ public void oclipCommandExecutionFailedTest1() {
OnapCommandExecutionFailed failed = new OnapCommandExecutionFailed("Test", "Test Command Failed", 201);
assertEquals("201::0x6001::Command Test failed to execute, Test Command Failed", failed.getMessage());
failed = new OnapCommandExecutionFailed("Test", new Exception("Test Command Failed"), 201);
}
@Test
- public void onapCommandExecutionFailedTest2() {
+ public void oclipCommandExecutionFailedTest2() {
OnapCommandExecutionFailed failed = new OnapCommandExecutionFailed("Test Command Failed");
assertEquals("0x6001::Test Command Failed", failed.getMessage());
}
@Test
- public void onapCommandExecutionFailedTest3() {
+ public void oclipCommandExecutionFailedTest3() {
OnapCommandExecutionFailed failed = new OnapCommandExecutionFailed("Test", "Test Command Failed");
assertEquals("0x6001::Command Test failed to execute, Test Command Failed", failed.getMessage());
}
@Test
- public void onapCommandExecutorInfoMissingTest() {
+ public void oclipCommandExecutorInfoMissingTest() {
OnapCommandExecutorInfoMissing failed = new OnapCommandExecutorInfoMissing("Test");
assertEquals("0x6002::Command Test excutor info is missing from schema", failed.getMessage());
}
@Test
- public void onapCommandHelpFailedTest() {
+ public void oclipCommandHelpFailedTest() {
OnapCommandHelpFailed failed = new OnapCommandHelpFailed(new Exception("Failed"));
assertEquals("0x9001::Command failed to print help message, Failed", failed.getMessage());
}
@Test
- public void onapCommandHttpFailureTest1() {
+ public void oclipCommandHttpFailureTest1() {
OnapCommandHttpFailure failed = new OnapCommandHttpFailure("Failed");
assertEquals("0x3001::Failed", failed.getMessage());
}
@Test
- public void onapCommandHttpFailureTest2() {
+ public void oclipCommandHttpFailureTest2() {
OnapCommandHttpFailure failed = new OnapCommandHttpFailure("Failed", 203);
assertEquals("203::0x3001::Failed", failed.getMessage());
}
@Test
- public void onapCommandInvalidParameterTypeTest() {
+ public void oclipCommandInvalidParameterTypeTest() {
OnapCommandInvalidParameterType failed = new OnapCommandInvalidParameterType("Failed");
assertEquals("0x7001::Parameter type Failed is invalid", failed.getMessage());
}
@Test
- public void onapCommandInvalidPrintDirectionTest() {
+ public void oclipCommandInvalidPrintDirectionTest() {
OnapCommandInvalidPrintDirection failed = new OnapCommandInvalidPrintDirection("Direction");
assertEquals("0x8003::Print direction Direction is invalid", failed.getMessage());
}
@Test
- public void onapCommandInvalidRegistrationTest() {
+ public void oclipCommandInvalidRegistrationTest() {
OnapCommandInvalidRegistration failed = new OnapCommandInvalidRegistration(OnapCommandErrorTest.class);
assertEquals("0x2001::Invalid commad class org.onap.cli.fw.error.OnapCommandErrorTest registration, "
}
@Test
- public void onapCommandInvalidResultAttributeScopeTest() {
+ public void oclipCommandInvalidResultAttributeScopeTest() {
OnapCommandInvalidResultAttributeScope failed = new OnapCommandInvalidResultAttributeScope("Attribute");
assertEquals("0x8002::Result atrribute Attribute is invalid", failed.getMessage());
}
@Test
- public void onapCommandInvalidSchemaTest() {
+ public void oclipCommandInvalidSchemaTest() {
OnapCommandInvalidSchema failed = new OnapCommandInvalidSchema("Schema", "Failed");
assertEquals("0xb001::Invalid command schema Schema, Failed", failed.getMessage());
}
@Test
- public void onapCommandInvalidSchemaVersionTest() {
+ public void oclipCommandInvalidSchemaVersionTest() {
OnapCommandInvalidSchemaVersion failed = new OnapCommandInvalidSchemaVersion("1.0");
assertEquals("0xb003::Command schema open_cli_schema_version 1.0 is invalid or missing", failed.getMessage());
}
@Test
- public void onapCommandLoginFailedTest1() {
+ public void oclipCommandLoginFailedTest1() {
OnapCommandLoginFailed failed = new OnapCommandLoginFailed(new Exception("Failed"));
assertEquals("0x4001::Login failed, Failed", failed.getMessage());
}
@Test
- public void onapCommandLoginFailedTest2() {
+ public void oclipCommandLoginFailedTest2() {
OnapCommandLoginFailed failed = new OnapCommandLoginFailed("Failed", 201);
assertEquals("201::0x4001::Login failed, Failed", failed.getMessage());
}
@Test
- public void onapCommandLogoutFailedTest() {
+ public void oclipCommandLogoutFailedTest() {
OnapCommandLogoutFailed failed = new OnapCommandLogoutFailed(new Exception("Failed"));
assertEquals("0x4002::Logout failed, Failed", failed.getMessage());
}
@Test
- public void onapCommandNotFoundTest() {
+ public void oclipCommandNotFoundTest() {
OnapCommandNotFound failed = new OnapCommandNotFound("Test", "1.0");
assertEquals("0x6003::Command Test is not available for product version 1.0", failed.getMessage());
}
@Test
- public void onapCommandNotInitializedTest() {
+ public void oclipCommandNotInitializedTest() {
OnapCommandNotInitialized failed = new OnapCommandNotInitialized("Test");
assertEquals("0x6004::Command Test is not initialized", failed.getMessage());
}
@Test
- public void onapCommandOutputPrintingFailedTest() {
+ public void oclipCommandOutputPrintingFailedTest() {
OnapCommandOutputPrintingFailed failed = new OnapCommandOutputPrintingFailed(new Exception("error"));
assertEquals("0x8006::Command is failed to print the result, error", failed.getMessage());
}
@Test
- public void onapCommandParameterMissingTest() {
+ public void oclipCommandParameterMissingTest() {
OnapCommandParameterMissing failed = new OnapCommandParameterMissing("paramName");
assertEquals("0x7003::Parameter paramName is mandatory", failed.getMessage());
}
@Test
- public void onapCommandParameterNameConflictTest() {
+ public void oclipCommandParameterNameConflictTest() {
OnapCommandParameterNameConflict failed = new OnapCommandParameterNameConflict("paramName");
assertEquals("0x7004::Parameter name paramName is in conflict", failed.getMessage());
}
@Test
- public void onapCommandParameterOptionConflictTest() {
+ public void oclipCommandParameterOptionConflictTest() {
OnapCommandParameterOptionConflict failed = new OnapCommandParameterOptionConflict("option");
assertEquals("0x7006::Parameter option option is in conflict, only one option is allowed with given name",
}
@Test
- public void onapCommandRegistrationFailedTest() {
+ public void oclipCommandRegistrationFailedTest() {
OnapCommandRegistrationFailed failed = new OnapCommandRegistrationFailed("Test", "error");
assertEquals("0x2002::Failed to register the command Test, error", failed.getMessage());
}
@Test
- public void onapCommandResultInitialzationFailedTest() {
+ public void oclipCommandResultInitialzationFailedTest() {
OnapCommandResultInitialzationFailed failed = new OnapCommandResultInitialzationFailed("Test",
new Exception("error"));
}
@Test
- public void onapCommandSchemaNotFoundTest() {
+ public void oclipCommandSchemaNotFoundTest() {
OnapCommandSchemaNotFound failed = new OnapCommandSchemaNotFound("Test");
assertEquals("0xb002::Command schema is missing for command Test", failed.getMessage());
}
@Test
- public void onapCommandSampleInvalidTest() {
- OnapCommandInvalidSample failed = new OnapCommandInvalidSample("Test", "error");
-
- assertEquals("0xf001::Invalid command sample Test, error", failed.getMessage());
-
- failed = new OnapCommandInvalidSample("Test", new Exception("error"));
-
- assertEquals("0xf001::Invalid command sample Test, error", failed.getMessage());
- }
-
- @Test
- public void onapCommandServiceNotFoundTest() {
+ public void oclipCommandServiceNotFoundTest() {
OnapCommandServiceNotFound failed = new OnapCommandServiceNotFound("Service");
assertEquals("0xd001::Service Service is not found in MSB", failed.getMessage());
}
@Test
- public void onapCommandOutputFormatNotsupportedTest() {
+ public void oclipCommandOutputFormatNotsupportedTest() {
OnapCommandOutputFormatNotsupported failed = new OnapCommandOutputFormatNotsupported("Format");
assertEquals("0x8005::Command does not support the output format Format", failed.getMessage());
@Test
- public void onapProfilePersistTest() {
+ public void oclipProfilePersistTest() {
OnapCommandPersistProfileFailed failed = new OnapCommandPersistProfileFailed("error");
assertEquals("0xc002::Failed to persist profile details, error", failed.getMessage());
@Test
- public void onapProfileLoadTest() {
+ public void oclipProfileLoadTest() {
OnapCommandLoadProfileFailed failed = new OnapCommandLoadProfileFailed("error");
assertEquals("0xc001::Failed to load profile details, error", failed.getMessage());
}
@Test
- public void onapCommandTypeInvalidTest() {
+ public void oclipCommandTypeInvalidTest() {
OnapCommandInvalidCommandType failed = new OnapCommandInvalidCommandType("test");
assertEquals("0x3003::Command type test is invalid", failed.getMessage());
}
@Test(expected = OnapCommandInvalidParameterValue.class)
- public void onapCommandInvalidParameterValueArrayExeceptionTest() throws OnapCommandInvalidParameterValue {
+ public void oclipCommandInvalidParameterValueArrayExeceptionTest() throws OnapCommandInvalidParameterValue {
OnapCommandParameter param = new OnapCommandParameter();
param.setName("name");
param.setParameterType(ParameterType.ARRAY);
}
@Test(expected = OnapCommandInvalidParameterValue.class)
- public void onapCommandInvalidParameterValueMapExeceptionTest() throws OnapCommandInvalidParameterValue {
+ public void oclipCommandInvalidParameterValueMapExeceptionTest() throws OnapCommandInvalidParameterValue {
OnapCommandParameter param = new OnapCommandParameter();
param.setName("name");
param.setParameterType(ParameterType.MAP);
}
@Test(expected = OnapCommandInvalidParameterValue.class)
- public void onapCommandInvalidParameterValueBinaryExeceptionTest() throws OnapCommandException {
+ public void oclipCommandInvalidParameterValueBinaryExeceptionTest() throws OnapCommandException {
OnapCommandParameter param = new OnapCommandParameter();
param.setName("name");
param.setParameterType(ParameterType.BINARY);
public class OnapCommandResultAttributeScopeTest {
@Test
- public void onapCommandResultAttributeTest() {
+ public void oclipCommandResultAttributeTest() {
OnapCommandResultAttribute att = new OnapCommandResultAttribute();
att.setDescription("description");
att.setName("name");
};
List<String> errorList4 = OnapCommandUtils.loadSchema(cmd2, "schema-validate-invalid.yaml", true, true);
- OnapHttpCommand onapHttpCommand = new OnapHttpCommand();
- errorList4.addAll(OnapCommandUtils.loadHttpSchema(onapHttpCommand,
+ OnapHttpCommand oclipHttpCommand = new OnapHttpCommand();
+ errorList4.addAll(OnapCommandUtils.loadHttpSchema(oclipHttpCommand,
"schema-validate-invalid.yaml", true, true));
assertTrue(errorList4.size() > 0);
public class OnapCommandUtilsTest {
@Test(expected = OnapCommandInvalidSchema.class)
- public void onapCommandUtilsInputStreamNullTest() throws OnapCommandException {
+ public void oclipCommandUtilsInputStreamNullTest() throws OnapCommandException {
OnapCommandUtils.validateSchemaVersion("sample-test1-schema-http1.yaml", "1.0");
}
@Test
- public void onapCommandUtilsInputStreamNotNullTest() throws OnapCommandException {
+ public void oclipCommandUtilsInputStreamNotNullTest() throws OnapCommandException {
Map<String, ?> map = OnapCommandUtils.validateSchemaVersion("sample-test1-schema-http.yaml", "1.0");
assertTrue(map != null);
}
open_cli_schema_version: 1.0
name: sample-test
-description: Onap sample command to test the command features
+description: Oclip sample command to test the command features
info:
product: open-cli
parameters:
- name: bool-param
type: bool
- description: Onap boolean param, by default its always false.
+ description: Oclip boolean param, by default its always false.
short_option: b
long_option: bool
is_optional: true
default_value: false
- name: secure-param
type: string
- description: Onap secure param such as password
+ description: Oclip secure param such as password
short_option: x
long_option: secure
is_secured: true
default_Value: pass123#
- name: string-param
type: string
- description: Onap string param
+ description: Oclip string param
long_option: string-param
short_option: c
is_optional: false
default_Value: test
- name: yaml-param
type: json
- description: Onap yaml file location param
+ description: Oclip yaml file location param
long_option: yaml-param
short_option: y
is_optional: false
- name: json-param
type: json
- description: Onap json file location param
+ description: Oclip json file location param
long_option: json-param
short_option: j
is_optional: false
- name: long-param
type: digit
- description: Onap long param
+ description: Oclip long param
short_option: l
long_option: long-opt
is_optional: false
default_value: 10
- name: url-param
type: url
- description: Onap url param
+ description: Oclip url param
short_option: r
long_option: url
is_optional: false
default_value: http://localhost:8082/file.txt
- name: env-param
type: string
- description: Onap env param.
+ description: Oclip env param.
short_option: z
long_option: env
is_optional: false
default_value: ${ENV_VAR}
- name: positional-args
type: string
- description: Onap positional args, if no short option and no long option given for it
+ description: Oclip positional args, if no short option and no long option given for it
is_optional: false
default_value: http://localhost:8082/file.txt
results:
direction: portrait
attributes:
- name: output-1
- description: Onap output attribute marked in short
+ description: Oclip output attribute marked in short
scope: short
type: string
is_secured: true
- name: output-2
- description: Onap output attribute marked in long
+ description: Oclip output attribute marked in long
scope: short
is_secured: false
type: string
\ No newline at end of file
open_cli_schema_version: 1.0
name: sample-test
-description: Onap sample command to test the command features
+description: Oclip sample command to test the command features
info:
product: open-cli
service: test
parameters:
- name: bool-param
type: bool
- description: Onap boolean param, by default its always false.
+ description: Oclip boolean param, by default its always false.
short_option: b
long_option: bool
is_optional: true
is_include: true
- name: secure-param
type: string
- description: Onap secure param such as password
+ description: Oclip secure param such as password
short_option: x
long_option: secure
is_secured: true
default_Value: pass123#
- name: string-param
type: string
- description: Onap string param
+ description: Oclip string param
long_option: string-param
short_option: c
is_optional: true
default_Value: test
- name: yaml-param
type: json
- description: Onap yaml file location param
+ description: Oclip yaml file location param
long_option: yaml-param
short_option: y
is_optional: true
- name: json-param
type: json
- description: Onap json file location param
+ description: Oclip json file location param
long_option: json-param
short_option: j
is_optional: true
is_secured: false
- name: long-param
type: digit
- description: Onap long param
+ description: Oclip long param
short_option: l
long_option: long-opt
is_optional: true
default_value: 10
- name: url-param
type: url
- description: Onap url param
+ description: Oclip url param
short_option: r
long_option: url
is_optional: true
default_value: http://localhost:8082/file.txt
- name: env-param
type: string
- description: Onap env param.
+ description: Oclip env param.
short_option: z
long_option: env
is_optional: true
default_value: ${ENV_VAR}
- name: positional-args
type: string
- description: Onap positional args, if no short option and no long option given for it
+ description: Oclip positional args, if no short option and no long option given for it
is_optional: true
default_value: http://localhost:8082/file.txt
results:
direction: portrait
attributes:
- name: output-1
- description: Onap output attribute marked in short
+ description: Oclip output attribute marked in short
scope: short
type: string
is_secured: true
default_value: req-$s{uuid}
- name: output-2
- description: Onap output attribute marked in long
+ description: Oclip output attribute marked in long
scope: short
is_secured: false
type: string
open_cli_schema_version: 1.0
name: sample-test1
-description: Onap sample command to test the command features
+description: Oclip sample command to test the command features
info:
product: open-cli
parameters:
- name: bool-param
type: bool
- description: Onap boolean param, by default its always false.
+ description: Oclip boolean param, by default its always false.
short_option: b
long_option: bool
is_optional: true
default_value: false
- name: secure-param
type: string
- description: Onap secure param such as password
+ description: Oclip secure param such as password
short_option: x
long_option: secure
is_secured: true
default_Value: pass123#
- name: string-param
type: string
- description: Onap string param
+ description: Oclip string param
long_option: string-param
short_option: c
is_optional: false
default_Value: test
- name: yaml-param
type: json
- description: Onap yaml file location param
+ description: Oclip yaml file location param
long_option: yaml-param
short_option: y
is_optional: false
- name: json-param
type: json
- description: Onap json file location param
+ description: Oclip json file location param
long_option: json-param
short_option: j
is_optional: false
- name: long-param
type: digit
- description: Onap long param
+ description: Oclip long param
short_option: l
long_option: long-opt
is_optional: false
default_value: 10
- name: url-param
type: url
- description: Onap url param
+ description: Oclip url param
short_option: r
long_option: url
is_optional: false
default_value: http://localhost:8082/file.txt
- name: env-param
type: string
- description: Onap env param.
+ description: Oclip env param.
short_option: z
long_option: env
is_optional: false
default_value: ${ENV_VAR}
- name: positional-args
type: string
- description: Onap positional args, if no short option and no long option given for it
+ description: Oclip positional args, if no short option and no long option given for it
is_optional: false
default_value: http://localhost:8082/file.txt
http:
usage: oclip sample-test
-Onap sample command to test the command features
+Oclip sample command to test the command features
-Onap service: sample v1
+Oclip service: sample v1
Options:
[-h | --help] [-v | --version] [-d | --debug]
[-l | --long-opt] [-r | --url] [-z | --env]
<positional-args>
where,
--h | --help Onap command help message. It is of type STRING.
+-h | --help Oclip command help message. It is of type STRING.
By default, it is false.
--v | --version Onap command service version. It is of type
+-v | --version Oclip command service version. It is of type
STRING. By default, it is false.
-d | --debug Enable debug output. It is of type BOOL. By
default, it is false.
false.
-t | --no-title whether to print title or not. It is of type BOOL.
By default, it is false.
--b | --bool Onap boolean param, by default its always false.
+-b | --bool Oclip boolean param, by default its always false.
It is of type BOOL. It is optional. By default, it
is false.
--x | --secure Onap secure param such as password. It is of
+-x | --secure Oclip secure param such as password. It is of
type STRING. Secured.
--c | --string-param Onap string param. It is of type STRING.
--y | --yaml-param Onap yaml file location param. It is of type
+-c | --string-param Oclip string param. It is of type STRING.
+-y | --yaml-param Oclip yaml file location param. It is of type
JSON. It's recommended to input the complete path
of the file, which is having the value for it.
--j | --json-param Onap json file location param. It is of type
+-j | --json-param Oclip json file location param. It is of type
JSON. It's recommended to input the complete path
of the file, which is having the value for it.
--l | --long-opt Onap long param. It is of type LONG. By default,
+-l | --long-opt Oclip long param. It is of type LONG. By default,
it is 10.
--r | --url Onap url param. It is of type URL. By default,
+-r | --url Oclip url param. It is of type URL. By default,
it is http://localhost:8082/file.txt.
--z | --env Onap env param. It is of type STRING. By
+-z | --env Oclip env param. It is of type STRING. By
default, it is read from environment variable
ENV_VAR.
-positional-args Onap positional args, if no short option and no
+positional-args Oclip positional args, if no short option and no
long option given for it. It is of type STRING. By
default, it is http://localhost:8082/file.txt.
Results:
-output-1 Onap output attribute marked in short and is of
+output-1 Oclip output attribute marked in short and is of
type STRING. It is secured.
-output-2 Onap output attribute marked in long and is of
+output-2 Oclip output attribute marked in long and is of
type STRING.
open_cli_schema_version: 1.0
name: sample-test-info
-description: Onap sample command to test the command features
+description: Oclip sample command to test the command features
info:
product: open-cli
open_cli_schema_version: 1.0
name: sample-test
-description: Onap sample command to test the command features
+description: Oclip sample command to test the command features
info:
product: open-cli
parameters:
- name: bool-param
type: bool
- description: Onap boolean param, by default its always false.
+ description: Oclip boolean param, by default its always false.
short_option: b
long_option: bool
is_optional: true
default_value: false
- name: secure-param
type: string
- description: Onap secure param such as password
+ description: Oclip secure param such as password
short_option: x
long_option: secure
is_secured: true
default_Value: pass123#
- name: string-param
type: string
- description: Onap string param
+ description: Oclip string param
long_option: secure
short_option: c
is_optional: false
default_Value: test
- name: yaml-param
type: json
- description: Onap yaml file location param
+ description: Oclip yaml file location param
long_option: yaml-param
short_option: y
is_optional: false
- name: json-param
type: json
- description: Onap json file location param
+ description: Oclip json file location param
long_option: json-param
short_option: j
is_optional: false
- name: long-param
type: digit
- description: Onap long param
+ description: Oclip long param
short_option: l
long_option: long-opt
is_optional: false
default_value: 10
- name: url-param
type: url
- description: Onap url param
+ description: Oclip url param
short_option: r
long_option: url
is_optional: false
default_value: http://localhost:8082/file.txt
- name: env-param
type: string
- description: Onap env param.
+ description: Oclip env param.
short_option: z
long_option: env
is_optional: false
default_value: ${ENV_VAR}
- name: positional-args
type: string
- description: Onap positional args, if no short option and no long option given for it
+ description: Oclip positional args, if no short option and no long option given for it
is_optional: false
default_value: http://localhost:8082/file.txt
results:
direction: portrait
attributes:
- name: output-1
- description: Onap output attribute marked in short
+ description: Oclip output attribute marked in short
scope: short
type: string
- name: output-2
- description: Onap output attribute marked in long
+ description: Oclip output attribute marked in long
scope: short
type: string
\ No newline at end of file
open_cli_schema_version: 1.0
name: sample-test
-description: Onap sample command to test the command features
+description: Oclip sample command to test the command features
info:
product: open-cli
service: test
parameters:
- name: bool-param
type: bool
- description: Onap boolean param, by default its always false.
+ description: Oclip boolean param, by default its always false.
short_option: b
long_option: bool
is_optional: true
default_value: false
- name: bool-param
type: bool
- description: Onap boolean param, by default its always false.
+ description: Oclip boolean param, by default its always false.
short_option: b
long_option: bool
is_optional: true
default_value: false
- name: secure-param
type: string
- description: Onap secure param such as password
+ description: Oclip secure param such as password
short_option: x
long_option: secure
is_secured: true
default_Value: pass123#
- name: string-param
type: string
- description: Onap string param
+ description: Oclip string param
long_option: string-param
short_option: c
is_optional: false
default_Value: test
- name: yaml-param
type: json
- description: Onap yaml file location param
+ description: Oclip yaml file location param
long_option: yaml-param
short_option: y
is_optional: false
- name: json-param
type: json
- description: Onap json file location param
+ description: Oclip json file location param
long_option: json-param
short_option: j
is_optional: false
- name: long-param
type: digit
- description: Onap long param
+ description: Oclip long param
short_option: l
long_option: long-opt
is_optional: false
default_value: 10
- name: url-param
type: url
- description: Onap url param
+ description: Oclip url param
short_option: r
long_option: url
is_optional: false
default_value: http://localhost:8082/file.txt
- name: env-param
type: string
- description: Onap env param.
+ description: Oclip env param.
short_option: z
long_option: env
is_optional: false
default_value: ${ENV_VAR}
- name: positional-args
type: string
- description: Onap positional args, if no short option and no long option given for it
+ description: Oclip positional args, if no short option and no long option given for it
is_optional: false
default_value: http://localhost:8082/file.txt
results:
direction: portrait
attributes:
- name: output-1
- description: Onap output attribute marked in short
+ description: Oclip output attribute marked in short
scope: short
type: string
- name: output-2
- description: Onap output attribute marked in long
+ description: Oclip output attribute marked in long
scope: short
type: string
\ No newline at end of file
open_cli_schema_version: 1.0
name: sample-test
-description: Onap sample command to test the command features
+description: Oclip sample command to test the command features
info:
product: open-cli
service: test
parameters:
- name: bool-param
type: bool
- description: Onap boolean param, by default its always false.
+ description: Oclip boolean param, by default its always false.
short_option: b
long_option: bool
is_optional: true
default_value: false
- name: secure-param
type: string
- description: Onap secure param such as password
+ description: Oclip secure param such as password
short_option: x
short_option: y
long_option: secure
default_Value: pass123#
- name: string-param
type: string
- description: Onap string param
+ description: Oclip string param
long_option: string-param
short_option: c
is_optional: false
default_Value: test
- name: yaml-param
type: json
- description: Onap yaml file location param
+ description: Oclip yaml file location param
long_option: yaml-param
short_option: y
is_optional: false
- name: json-param
type: json
- description: Onap json file location param
+ description: Oclip json file location param
long_option: json-param
short_option: j
is_optional: false
- name: long-param
type: digit
- description: Onap long param
+ description: Oclip long param
short_option: l
long_option: long-opt
is_optional: false
default_value: 10
- name: url-param
type: url
- description: Onap url param
+ description: Oclip url param
short_option: r
long_option: url
is_optional: false
default_value: http://localhost:8082/file.txt
- name: env-param
type: string
- description: Onap env param.
+ description: Oclip env param.
short_option: z
long_option: env
is_optional: false
default_value: ${ENV_VAR}
- name: positional-args
type: string
- description: Onap positional args, if no short option and no long option given for it
+ description: Oclip positional args, if no short option and no long option given for it
is_optional: false
default_value: http://localhost:8082/file.txt
results:
direction: portrait
attributes:
- name: output-1
- description: Onap output attribute marked in short
+ description: Oclip output attribute marked in short
scope: short
type: string
- name: output-2
- description: Onap output attribute marked in long
+ description: Oclip output attribute marked in long
scope: short
type: string
\ No newline at end of file
open_cli_schema_version: 1.0
name: sample-test
-description: Onap sample command to test the command features
+description: Oclip sample command to test the command features
info:
product: open-cli
service: test
parameters:
- name: bool-param
type: bool
- description: Onap boolean param, by default its always false.
+ description: Oclip boolean param, by default its always false.
short_option: b
long_option: bool
is_optional: true
default_value: false
- name: secure-param
type: string
- description: Onap secure param such as password
+ description: Oclip secure param such as password
short_option: x
long_option: secure
is_secured: true
default_Value: pass123#
- name: string-param
type: string
- description: Onap string param
+ description: Oclip string param
long_option: string-param
short_option: c
is_optional: false
default_Value: test
- name: yaml-param
type: json
- description: Onap yaml file location param
+ description: Oclip yaml file location param
long_option: yaml-param
short_option: y
is_optional: false
- name: json-param
type: json
- description: Onap json file location param
+ description: Oclip json file location param
long_option: json-param
short_option: j
is_optional: false
- name: long-param
type: digit
- description: Onap long param
+ description: Oclip long param
short_option: l
long_option: long-opt
is_optional: false
default_value: 10
- name: url-param
type: url
- description: Onap url param
+ description: Oclip url param
short_option: r
long_option: url
is_optional: false
default_value: http://localhost:8082/file.txt
- name: env-param
type: string
- description: Onap env param.
+ description: Oclip env param.
short_option: z
long_option: env
is_optional: false
default_value: ${ENV_VAR}
- name: positional-args
type: string
- description: Onap positional args, if no short option and no long option given for it
+ description: Oclip positional args, if no short option and no long option given for it
is_optional: false
default_value: http://localhost:8082/file.txt
results:
direction: portrait
attributes:
- name: output-1
- description: Onap output attribute marked in short
+ description: Oclip output attribute marked in short
scope: short
type: string
- name: output-2
- description: Onap output attribute marked in long
+ description: Oclip output attribute marked in long
scope: short
type: string
\ No newline at end of file
open_cli_schema_version: 1.0
name: sample-test
-description: Onap sample command to test the command features
+description: Oclip sample command to test the command features
info:
product: open-cli
service: test
parameters:
- name: bool-param
type: bool
- description: Onap boolean param, by default its always false.
+ description: Oclip boolean param, by default its always false.
short_option: b
long_option: bool
is_optional: true
author: Kanagaraj Manickam mkr1481@gmail.com
parameters:
- name: service-name
- description: Onap service name
+ description: Oclip service name
type: string
short_option: x
long_option: service-name
is_optional: false
- name: service-version
- description: Onap service version
+ description: Oclip service version
type: string
short_option: y
long_option: service-version
is_optional: false
- name: service-url
- description: Onap service base url
+ description: Oclip service base url
type: url
short_option: r
long_option: service-url
is_optional: false
- name: status
- description: Onap service status
+ description: Oclip service status
type: digit
short_option: z
long_option: service-status
is_optional: true
default_value: 1
- name: node-ip
- description: Onap service running node IP
+ description: Oclip service running node IP
type: string
- name: node-port
- description: Onap service running node port
+ description: Oclip service running node port
type: string
- name: create-or-update
- description: Onap service create or update
+ description: Oclip service create or update
type: bool
default_value: true
results:
direction: portrait
attributes:
- name: name
- description: Onap service name
+ description: Oclip service name
scope: short
type: string
- name: version
- description: Onap service version
+ description: Oclip service version
scope: short
type: string
- name: url
- description: Onap service base url
+ description: Oclip service base url
scope: short
type: url
- name: status
- description: Onap service status
+ description: Oclip service status
scope: short
type: digit
- name: nodes
- description: Onap service running nodes
+ description: Oclip service running nodes
scope: long
type: string
- name: location
- description: Onap service location
+ description: Oclip service location
scope: long
type: url
http:
parameters:
- name: user
type: string
- description: Onap user
+ description: Oclip user
short_option: n
long_option: username
is_optional: false
direction: portrait
attributes:
- name: name
- description: Onap user
+ description: Oclip user
scope: short
type: string
exec:
author: Kanagaraj Manickam mkr1481@gmail.com
parameters:
- name: service-name1
- description: Onap service name
+ description: Oclip service name
type: string
short_option: x
long_option: service-name
is_optional: false
- name: service-version
- description: Onap service version
+ description: Oclip service version
type: string
short_option: x
long_option: service-version
is_optional: false
- name: service-url
- description: Onap service base url
+ description: Oclip service base url
type: url1
short_option: u
long_option: service-url
is_optional: false1
- name: status
- description: Onap service status
+ description: Oclip service status
type: digit
short_option: z
long_option: service-version
is_optional: true
default_value: 1
- name: node-ip
- description: Onap service running node IP
+ description: Oclip service running node IP
type: string
- name: node-port
- description: Onap service running node port
+ description: Oclip service running node port
type: string
- name: create-or-update
- description: Onap service create or update
+ description: Oclip service create or update
type: cfbcv
default_value: true
results:
direction: portrait1
attributes:
- name: name
- description: Onap service name
+ description: Oclip service name
scope: short
type: string
- name: version
- description: Onap service version
+ description: Oclip service version
scope: short
type: string
- name: status
- description: Onap service base url
+ description: Oclip service base url
scope: short
type: url
- name: status
- description: Onap service status
+ description: Oclip service status
scope: short1
type: digit
- name: nodes
- description: Onap service running nodes
+ description: Oclip service running nodes
scope: long
type: string
- name: location
- description: Onap service location
+ description: Oclip service location
scope: long
type: url
\ No newline at end of file
parameters:
- name: service-name1
- description: Onap service name
+ description: Oclip service name
type: string
short_option: x
long_option: service-name
is_optional: false
- name: service-version
- description: Onap service version
+ description: Oclip service version
type: string
short_option: x
long_option: service-version
is_optional: false
- name: service-url
- description: Onap service base url
+ description: Oclip service base url
type: url1
short_option: u
long_option: service-url
is_optional: false1
- name: status
- description: Onap service status
+ description: Oclip service status
type: digit
short_option: z
long_option: service-version
is_optional: true
default_value: 1
- name: node-ip
- description: Onap service running node IP
+ description: Oclip service running node IP
type: string
- name: node-port
- description: Onap service running node port
+ description: Oclip service running node port
type: string
- name: create-or-update
- description: Onap service create or update
+ description: Oclip service create or update
type: cfbcv
default_value: true
results:
direction: portrait
attributes:
- name: name
- description: Onap service name
+ description: Oclip service name
scope: short
type: string
- name: version
- description: Onap service version
+ description: Oclip service version
scope: short
type: string
- name: status
- description: Onap service base url
+ description: Oclip service base url
scope: short
type: url
- name: status
- description: Onap service status
+ description: Oclip service status
scope: short1
type: digit
- name: nodes
- description: Onap service running nodes
+ description: Oclip service running nodes
scope: long
type: string
- name: location
- description: Onap service location
+ description: Oclip service location
scope: long
type: url
http:
author: Kanagaraj Manickam mkr1481@gmail.com
parameters:
- name: name
- description: Onap SDNC name
+ description: Oclip SDNC name
scope: short
type: string
short_option: n
long_option: name
is_optional: false
- name: vendor
- description: Onap SDNC vendor
+ description: Oclip SDNC vendor
scope: short
type: string
short_option: e
long_option: vendor
is_optional: false
- name: type
- description: Onap SDNC type
+ description: Oclip SDNC type
scope: short
type: string
short_option: y
long_option: type
is_optional: false
- name: sdnc-version
- description: Onap SDNC version
+ description: Oclip SDNC version
scope: short
type: string
short_option: r
long_option: sdnc-version
is_optional: false
- name: url
- description: Onap SDNC base url
+ description: Oclip SDNC base url
scope: short
type: url
short_option: l
long_option: url
is_optional: false
- name: description
- description: Onap SDNC description
+ description: Oclip SDNC description
scope: short
type: string
short_option: i
long_option: description
is_optional: false
- name: username
- description: Onap SDNC username
+ description: Oclip SDNC username
scope: short
type: string
short_option: g
long_option: username
is_optional: false
- name: password
- description: Onap SDNC password
+ description: Oclip SDNC password
scope: short
type: string
is_secured: true
long_option: password
is_optional: false
- name: product-name
- description: Onap SDNC product-name
+ description: Oclip SDNC product-name
scope: short
type: string
short_option: o
long_option: product-name
is_optional: false
- name: protocol
- description: Onap SDNC protocol
+ description: Oclip SDNC protocol
scope: short
type: string
short_option: k
direction: portrait
attributes:
- name: id
- description: Onap SDNC ID
+ description: Oclip SDNC ID
scope: short
type: string
- name: name
- description: Onap SDNC name
+ description: Oclip SDNC name
scope: short
type: string
- name: vendor
- description: Onap SDNC vendor
+ description: Oclip SDNC vendor
scope: short
type: string
- name: type
- description: Onap SDNC type
+ description: Oclip SDNC type
scope: short
type: string
- name: version
- description: Onap SDNC version
+ description: Oclip SDNC version
scope: short
type: string
- name: url
- description: Onap SDNC base url
+ description: Oclip SDNC base url
scope: short
type: url
- name: description
- description: Onap SDNC description
+ description: Oclip SDNC description
scope: short
type: string
- name: username
- description: Onap SDNC username
+ description: Oclip SDNC username
scope: short
type: string
- name: password
- description: Onap SDNC password
+ description: Oclip SDNC password
scope: short
type: string
is_secured: true
- name: product-name
- description: Onap SDNC product name
+ description: Oclip SDNC product name
scope: short
type: string
- name: protocol
- description: Onap SDNC protocol
+ description: Oclip SDNC protocol
scope: short
type: string
- name: create-time
- description: Onap SDNC create-time
+ description: Oclip SDNC create-time
scope: long
type: string
http:
name: schema-validate
parameters:
- name: service-name1
- description: Onap service name
+ description: Oclip service name
type: string
short_option: x
long_option: service-name
is_optional: false
- name: service-version
- description: Onap service version
+ description: Oclip service version
type: string
short_option: x
long_option: service-version
is_optional: false
- name: service-url
- description: Onap service base url
+ description: Oclip service base url
type: url1
short_option: u
long_option: service-url
is_optional: false1
- name: status
- description: Onap service status
+ description: Oclip service status
type: digit
short_option: z
long_option: service-version
is_optional: true
default_value: 1
- name: node-ip
- description: Onap service running node IP
+ description: Oclip service running node IP
type: string
- name: node-port
- description: Onap service running node port
+ description: Oclip service running node port
type: string
- name: create-or-update
- description: Onap service create or update
+ description: Oclip service create or update
type: cfbcv
default_value: true
results:
direction: portrait
attributes:
- name: name
- description: Onap service name
+ description: Oclip service name
scope: short
type: string
- name: version
- description: Onap service version
+ description: Oclip service version
scope: short
type: string
- name: status
- description: Onap service base url
+ description: Oclip service base url
scope: short
type: url
- name: status
- description: Onap service status
+ description: Oclip service status
scope: short1
type: digit
- name: nodes
- description: Onap service running nodes
+ description: Oclip service running nodes
scope: long
type: string
- name: location
- description: Onap service location
+ description: Oclip service location
scope: long
type: url
http:
parameters:
- name: name
- description: Onap SDNC name
+ description: Oclip SDNC name
scope: short
type: string
short_option: n
long_option: name
is_optional: false
- name: vendor
- description: Onap SDNC vendor
+ description: Oclip SDNC vendor
scope: short
type: string
short_option: e
long_option: vendor
is_optional: false
- name: type
- description: Onap SDNC type
+ description: Oclip SDNC type
scope: short
type: string
short_option: y
long_option: type
is_optional: false
- name: sdnc-version
- description: Onap SDNC version
+ description: Oclip SDNC version
scope: short
type: string
short_option: r
long_option: sdnc-version
is_optional: false
- name: url
- description: Onap SDNC base url
+ description: Oclip SDNC base url
scope: short
type: url
short_option: l
long_option: url
is_optional: false
- name: description
- description: Onap SDNC description
+ description: Oclip SDNC description
scope: short
type: string
short_option: i
long_option: description
is_optional: false
- name: username
- description: Onap SDNC username
+ description: Oclip SDNC username
scope: short
type: string
short_option: g
long_option: username
is_optional: false
- name: password
- description: Onap SDNC password
+ description: Oclip SDNC password
scope: short
type: string
is_secured: true
long_option: password
is_optional: false
- name: product-name
- description: Onap SDNC product-name
+ description: Oclip SDNC product-name
scope: short
type: string
short_option: o
long_option: product-name
is_optional: false
- name: protocol
- description: Onap SDNC protocol
+ description: Oclip SDNC protocol
scope: short
type: string
short_option: k
direction: portrait
attributes:
- name: id
- description: Onap SDNC ID
+ description: Oclip SDNC ID
scope: short
type: string
- name: name
- description: Onap SDNC name
+ description: Oclip SDNC name
scope: short
type: string
- name: vendor
- description: Onap SDNC vendor
+ description: Oclip SDNC vendor
scope: short
type: string
- name: type
- description: Onap SDNC type
+ description: Oclip SDNC type
scope: short
type: string
- name: version
- description: Onap SDNC version
+ description: Oclip SDNC version
scope: short
type: string
- name: url
- description: Onap SDNC base url
+ description: Oclip SDNC base url
scope: short
type: url
- name: description
- description: Onap SDNC description
+ description: Oclip SDNC description
scope: short
type: string
- name: username
- description: Onap SDNC username
+ description: Oclip SDNC username
scope: short
type: string
- name: password
- description: Onap SDNC password
+ description: Oclip SDNC password
scope: short
type: string
is_secured: true
- name: product-name
- description: Onap SDNC product name
+ description: Oclip SDNC product name
scope: short
type: string
- name: protocol
- description: Onap SDNC protocol
+ description: Oclip SDNC protocol
scope: short
type: string
- name: create-time
- description: Onap SDNC create-time
+ description: Oclip SDNC create-time
scope: long
type: string
http:
import jline.console.ConsoleReader;
/**
- * Onap Command Line Interface (CLI).
+ * Oclip Command Line Interface (CLI).
*
*/
public class OnapCli {
console.addCompleter(strCompleter);
console.setPrompt(OnapCliConstants.PARAM_INTERACTIVE_PROMPT + ":" + OnapCommandRegistrar.getRegistrar().getEnabledProductVersion() + ">");
} catch (OnapCommandException e) { // NOSONAR
- this.print("Failed to load onap commands," + e.getMessage());
+ this.print("Failed to load oclip commands," + e.getMessage());
}
return console;
import java.util.Map;
/**
- * Onap CLI utilities.
+ * Oclip CLI utilities.
*
*/
public class OnapCliUtils {
}
int positionalIdx = 0;
- // Skip the first args onap cmd name, so start from 1
+ // Skip the first args oclip cmd name, so start from 1
for (int i = 1; i < args.size(); i++) {
// check if short option exist
// (mrkanag) Optimize the below code to handle short and long options in one iteration
2. OPEN_CLI_HOST_USERNAME - Service user name
3. OPEN_CLI_HOST_PASSWORD - Service password
-To know the CLI version, type onap [-v|--version]
-To know the CLI usage, type onap [-h|--help]
-To know the usage of sub commands, type onap <command> [-h|--help]
+To know the CLI version, type oclip [-v|--version]
+To know the CLI usage, type oclip [-h|--help]
+To know the usage of sub commands, type oclip <command> [-h|--help]
To know more, please refer the wiki https://wiki.onap.org
parameters:
- name: service-name
- description: Onap service name
+ description: Oclip service name
type: string
short_option: x
long_option: service-name
is_optional: false
- name: node-ip
- description: Onap service running node IP
+ description: Oclip service running node IP
type: array
short_option: i
long_option: node-ip
- name: node-port
- description: Onap service running node port
+ description: Oclip service running node port
type: map
short_option: o
long_option: node-port
direction: portrait
attributes:
- name: name
- description: Onap service name
+ description: Oclip service name
scope: short
type: string
- name: version
- description: Onap service version
+ description: Oclip service version
scope: short
type: string
- name: url
- description: Onap service base url
+ description: Oclip service base url
scope: short
type: url
- name: status
- description: Onap service status
+ description: Oclip service status
scope: short
type: digit
- name: nodes
- description: Onap service running nodes
+ description: Oclip service running nodes
scope: long
type: string
- name: location
- description: Onap service location
+ description: Oclip service location
scope: long
type: url
http:
open_cli_schema_version: 1.0
name: sample-test
-description: Onap sample command to test the command features
+description: Oclip sample command to test the command features
info:
product: open-cli
service: test
parameters:
- name: bool-param
type: bool
- description: Onap boolean param, by default its always false.
+ description: Oclip boolean param, by default its always false.
short_option: b
long_option: bool
is_optional: true
default_value: false
- name: secure-param
type: string
- description: Onap secure param such as password
+ description: Oclip secure param such as password
short_option: x
long_option: secure
is_secured: true
default_Value: pass123#
- name: string-param
type: string
- description: Onap string param
+ description: Oclip string param
long_option: string-param
short_option: c
is_optional: true
default_Value: test
- name: yaml-param
type: json
- description: Onap yaml file location param
+ description: Oclip yaml file location param
long_option: yaml-param
short_option: y
is_optional: true
- name: json-param
type: json
- description: Onap json file location param
+ description: Oclip json file location param
long_option: json-param
short_option: j
is_optional: true
- name: long-param
type: digit
- description: Onap long param
+ description: Oclip long param
short_option: l
long_option: long-opt
is_optional: true
default_value: 10
- name: url-param
type: url
- description: Onap url param
+ description: Oclip url param
short_option: r
long_option: url
is_optional: true
default_value: http://localhost:8082/file.txt
- name: env-param
type: string
- description: Onap env param.
+ description: Oclip env param.
short_option: z
long_option: env
is_optional: true
default_value: http://localhost:8082/file.txt
- name: positional-args
type: string
- description: Onap positional args, if no short option and no long option given for it
+ description: Oclip positional args, if no short option and no long option given for it
is_optional: true
default_value: http://localhost:8082/file.txt
- name: text-param
type: text
- description: Onap text file location param
+ description: Oclip text file location param
long_option: text-param
short_option: e
is_optional: true
direction: portrait
attributes:
- name: output-1
- description: Onap output attribute marked in short
+ description: Oclip output attribute marked in short
scope: short
type: string
- name: output-2
- description: Onap output attribute marked in long
+ description: Oclip output attribute marked in long
scope: short
type: string
\ No newline at end of file