List<JMethod> methods = getActionMethods(t);
if (methods != null) {
for (JMethod method : methods) {
CmdActionDescriptor cmdActionDescriptor = new CmdActionDescriptor(
method.getName(), method, t);
CmdAction cmdAction = method.getAnnotation(CmdAction.class);
if (cmdAction.name() != null && cmdAction.name().length() > 0) {
cmdActionDescriptor.name = cmdAction.name();
}
if (cmdAction.description() != null
&& cmdAction.description().length() > 0) {
cmdActionDescriptor.description = cmdAction.description();
}
if (cmdAction.image() != null && cmdAction.image().length() > 0) {
cmdActionDescriptor.image = cmdAction.image();
}
if (cmdAction.enabledProperty() != null
&& cmdAction.enabledProperty().length() > 0) {
cmdActionDescriptor.enabledProperty = cmdAction.enabledProperty();
}
if (cmdAction.selectedProperty() != null
&& cmdAction.selectedProperty().length() > 0) {
cmdActionDescriptor.selectedProperty = cmdAction.selectedProperty();
}
cmdActionDescriptorList.add(cmdActionDescriptor);
}
}
}