if ((currentParam instanceof PrimitiveParam)) { g.writeStartObject(); String _name_1 = ((PrimitiveParam)currentParam).getName(); g.writeStringField("name", _name_1); PrimitiveType _type = ((PrimitiveParam) currentParam).getType(); String paramType = _type.getLiteral(); String _thingWorxDataType = this.getThingWorxDataType(paramType);
boolean _isMultiplicity = ((PrimitiveParam)param).isMultiplicity(); if (_isMultiplicity) { _builder.append("\""); String _name = ((PrimitiveParam)param).getName(); _builder.append(_name, ""); _builder.append("\": {"); _and = false; } else { String _description = ((PrimitiveParam)param).getDescription(); boolean _isNullOrEmpty = StringExtensions.isNullOrEmpty(_description); boolean _not = (!_isNullOrEmpty); String _description_1 = ((PrimitiveParam)param).getDescription(); _builder.append(_description_1, "\t"); _builder.append("\","); _builder.newLine(); _builder.append("\t\t"); PrimitiveType _type = primitiveParam.getType(); String _content = OperationSingleParameterValidationTemplate.primitiveTypeValidationTemplate.getContent(_type, invocationContext); _builder.append(_content, "\t\t"); ConstraintRule _constraintRule = ((PrimitiveParam)param).getConstraintRule(); CharSequence _constraintsContent = Utils.getConstraintsContent(_constraintRule, invocationContext); _builder.append(_constraintsContent, "\t\t"); } else { _builder.append("\""); String _name_1 = ((PrimitiveParam)param).getName();
protected boolean isAlexaSupportedParamType(final Param param) { if ((param instanceof PrimitiveParam)) { PrimitiveType primitiveType = ((PrimitiveParam) param).getType(); boolean _or = false; boolean _or_1 = false;
protected boolean isAlexaSupportedParamType(final Param param) { if ((param instanceof PrimitiveParam)) { PrimitiveType primitiveType = ((PrimitiveParam) param).getType(); boolean _or = false; boolean _or_1 = false;
PrimitiveType _type = ((PrimitiveParam) property).getType(); String _mapSimpleDatatype = ValueMapper.mapSimpleDatatype(((PrimitiveType) _type)); _builder.append(_mapSimpleDatatype, ""); _builder.append(" "); String _name = ((PrimitiveParam)property).getName(); _builder.append(_name, ""); _builder.newLineIfNotEmpty();
protected String mapToAlexaSupportedType(final Param param) { if ((param instanceof PrimitiveParam)) { PrimitiveType primitiveType = ((PrimitiveParam) param).getType(); boolean _or = false; boolean _equals = Objects.equal(primitiveType, PrimitiveType.INT);
PrimitiveType _type = ((PrimitiveParam) property).getType(); String _mapSimpleDatatype = ValueMapper.mapSimpleDatatype(((PrimitiveType) _type)); _builder.append(_mapSimpleDatatype, ""); _builder.append(" "); String _name = ((PrimitiveParam)property).getName(); _builder.append(_name, ""); _builder.newLineIfNotEmpty();
protected String mapToAlexaSupportedType(final Param param) { if ((param instanceof PrimitiveParam)) { PrimitiveType primitiveType = ((PrimitiveParam) param).getType(); boolean _or = false; boolean _equals = Objects.equal(primitiveType, PrimitiveType.INT);
/** * Returns the parameter as string */ public static String getParameterTypeAsString(final Param parameter) { if ((parameter instanceof PrimitiveParam)) { PrimitiveType _type = ((PrimitiveParam) parameter).getType(); return ValueMapper.mapSimpleDatatype(((PrimitiveType) _type)); } else { if ((parameter instanceof RefParam)) { RefParam object = ((RefParam) parameter); Type _type_1 = object.getType(); if ((_type_1 instanceof Entity)) { Type _type_2 = object.getType(); String _name = ((Entity) _type_2).getName(); return StringExtensions.toFirstUpper(_name); } else { Type _type_3 = object.getType(); if ((_type_3 instanceof org.eclipse.vorto.core.api.model.datatype.Enum)) { Type _type_4 = object.getType(); String _name_1 = ((org.eclipse.vorto.core.api.model.datatype.Enum) _type_4).getName(); return StringExtensions.toFirstUpper(_name_1); } } } } return null; }
/** * Returns the parameter as string */ public static String getParameterTypeAsString(final Param parameter) { if ((parameter instanceof PrimitiveParam)) { PrimitiveType _type = ((PrimitiveParam) parameter).getType(); return ValueMapper.mapSimpleDatatype(((PrimitiveType) _type)); } else { if ((parameter instanceof RefParam)) { RefParam object = ((RefParam) parameter); Type _type_1 = object.getType(); if ((_type_1 instanceof Entity)) { Type _type_2 = object.getType(); String _name = ((Entity) _type_2).getName(); return StringExtensions.toFirstUpper(_name); } else { Type _type_3 = object.getType(); if ((_type_3 instanceof org.eclipse.vorto.core.api.model.datatype.Enum)) { Type _type_4 = object.getType(); String _name_1 = ((org.eclipse.vorto.core.api.model.datatype.Enum) _type_4).getName(); return StringExtensions.toFirstUpper(_name_1); } } } } return null; }