本文整理了Java中org.eclipse.vorto.core.api.model.datatype.Property.getName()
方法的一些代码示例,展示了Property.getName()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Property.getName()
方法的具体详情如下:
包路径:org.eclipse.vorto.core.api.model.datatype.Property
类名称:Property
方法名:getName
[英]Returns the value of the 'Name' attribute.
If the meaning of the 'Name' attribute isn't clear, there really should be more of a description here...
[中]返回“Name”属性的值。
如果“Name”属性的含义不清楚,这里真的应该有更多的描述。。。
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.examples.aws
@Override
public String getFileName(final Property context) {
String _name = context.getName();
String _plus = ("GetThingShadowLambda_" + _name);
return (_plus + ".js");
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.templates.java
public static boolean isEventable(Property property, FunctionBlock fb) {
if (findEventByName(property.getName(), fb) != null) {
return true;
}
return false;
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.templates.java
public static boolean isReadable(Property property, FunctionBlock fb) {
String getterName = GETTER_PREFIX + property.getName();
if (findOperationByName(getterName, fb) != null) {
return true;
}
return false;
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.templates.java
public static boolean isWritable(Property property, FunctionBlock fb) {
String setterName = SETTER_PREFIX + property.getName();
if (findOperationByName(setterName, fb) != null) {
return true;
}
return false;
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.examples.prosystfi
public static boolean isWritable(Property property, FunctionBlock fb) {
String setterName = SETTER_PREFIX + property.getName();
if (findOperationByName(setterName,fb) != null) {
return true;
}
return false;
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.examples.prosystfi
public static boolean isEventable(Property property, FunctionBlock fb) {
if (findEventByName(property.getName(), fb) !=null) {
return true;
}
return false;
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.editor.datatype
public void checkDuplicatedProperty(final List<Property> props) {
HashSet<String> set = new HashSet<String>();
for (final Property pp : props) {
String _name = pp.getName();
boolean _add = set.add(_name);
boolean _not = (!_add);
if (_not) {
this.error(DatatypeSystemMessage.ERROR_DUPLICATED_PROPERTY_NAME, pp, DatatypePackage.Literals.PROPERTY__NAME);
}
}
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.examples.prosystfi
public static boolean isReadable(Property property, FunctionBlock fb) {
String getterName = GETTER_PREFIX + property.getName();
if (findOperationByName(getterName,fb) != null) {
return true;
}
return false;
}
代码示例来源:origin: org.eclipse.vorto/generator-templates-java
public static boolean isWritable(Property property, FunctionBlock fb) {
String setterName = SETTER_PREFIX + property.getName();
return findOperationByName(setterName, fb) != null;
}
代码示例来源:origin: org.eclipse.vorto/boschiotsuite-gateway
public static boolean isReadable(Property property, FunctionBlock fb) {
String getterName = GETTER_PREFIX + property.getName();
return findOperationByName(getterName, fb) != null;
}
代码示例来源:origin: org.eclipse.vorto/boschiotsuite-gateway
public static boolean isWritable(Property property, FunctionBlock fb) {
String setterName = SETTER_PREFIX + property.getName();
return findOperationByName(setterName, fb) != null;
}
代码示例来源:origin: org.eclipse.vorto/generator-templates-java
public static boolean isReadable(Property property, FunctionBlock fb) {
String getterName = GETTER_PREFIX + property.getName();
return findOperationByName(getterName, fb) != null;
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.editor.datatype
@Check
public void checkPropertyName(final Property property) {
String name = property.getName();
boolean _endsWith = name.endsWith("TS");
if (_endsWith) {
this.error(DatatypeSystemMessage.ERROR_PROPNAME_SUFFIX_TS, property, DatatypePackage.Literals.PROPERTY__NAME);
}
}
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.examples.aws
protected CharSequence getDefaultCommand(final Property property) {
StringConcatenation _builder = new StringConcatenation();
_builder.append("get ");
String _name = property.getName();
_builder.append(_name, "");
_builder.append(" status");
return _builder;
}
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.examples.coap
private void generateForProperty(Property property, IGeneratedWriter outputter) {
if(property.getType() != null && property.getType() instanceof PrimitivePropertyType){
new JavaFBPropertyPrimitiveParamWrapperGeneratorTask(
property.getName() + COAP_PRIM_TYPE_WRAPPER_SUFFIX,
JAVA_FILE_EXTENSION,
primitiveTypeWrapperTargetPath,
PRIMITIVE_TYPE_WRAPPER_PACKAGE)
.generate(property, null, outputter);
}
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.coap
private void generateForProperty(Property property, IGeneratedWriter outputter) {
if(property.getType() != null && property.getType() instanceof PrimitivePropertyType){
new JavaFBPropertyPrimitiveParamWrapperGeneratorTask(
property.getName() + COAP_PRIM_TYPE_WRAPPER_SUFFIX,
JAVA_FILE_EXTENSION,
primitiveTypeWrapperTargetPath,
PRIMITIVE_TYPE_WRAPPER_PACKAGE)
.generate(property, null, outputter);
}
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.ditto
private void generateFault(InvocationContext context, String jsonFileExt, IGeneratedWriter outputter,
String stateTargetPath, Fault fault) {
if (fault != null) {
generateTask(fault, context, outputter, ValidationTaskFactory.getPropertiesFaultValidationTask(jsonFileExt, stateTargetPath));
for (Property property : fault.getProperties()) {
generateTask(property, context, outputter,
ValidationTaskFactory.getPropertiesSinglePropertyValidationTask(
"-fault-" + property.getName() + jsonFileExt, stateTargetPath));
}
}
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.aws
protected CharSequence getDefaultCommand(final String functionblockPropertyName, final Property property) {
StringConcatenation _builder = new StringConcatenation();
_builder.append("get ");
_builder.append(functionblockPropertyName, "");
_builder.append(" ");
String _name = property.getName();
_builder.append(_name, "");
return _builder;
}
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.ditto
private void generateConfiguration(InvocationContext context, String jsonFileExt, IGeneratedWriter outputter,
String stateTargetPath, Configuration configuration) {
if (configuration != null) {
generateTask(configuration, context, outputter, ValidationTaskFactory.getPropertiesConfigValidationTask(jsonFileExt, stateTargetPath));
for (Property property : configuration.getProperties()) {
generateTask(property, context, outputter,
ValidationTaskFactory.getPropertiesSinglePropertyValidationTask(
"-configuration-" + property.getName() + jsonFileExt, stateTargetPath));
}
}
}
代码示例来源:origin: org.eclipse.vorto/org.eclipse.vorto.codegen.ditto
private void generateStatus(InvocationContext context, String jsonFileExt, IGeneratedWriter outputter,
String stateTargetPath, Status status) {
if (status != null) {
generateTask(status, context, outputter, ValidationTaskFactory.getPropertiesStatusValidationTask(jsonFileExt, stateTargetPath));
for (Property property : status.getProperties()) {
generateTask(property, context, outputter,
ValidationTaskFactory.getPropertiesSinglePropertyValidationTask(
"-status-" + property.getName() + jsonFileExt, stateTargetPath));
}
}
}
内容来源于网络,如有侵权,请联系作者删除!