public Object sGet(SField sField) { if (sField.getName().equals("name")) { return getName(); } if (sField.getName().equals("type")) { return getType(); } if (sField.getName().equals("description")) { return getDescription(); } if (sField.getName().equals("enabled")) { return isEnabled(); } if (sField.getName().equals("identifier")) { return getIdentifier(); } if (sField.getName().equals("installForAllUsers")) { return isInstallForAllUsers(); } if (sField.getName().equals("installForNewUsers")) { return isInstallForNewUsers(); } if (sField.getName().equals("oid")) { return getOid(); } if (sField.getName().equals("rid")) { return getRid(); } throw new RuntimeException("Field " + sField.getName() + " not found"); }
pluginDescriptor.setPluginInterfaceClassName(getPluginInterface(plugin.getClass()).getName()); pluginDescriptor.setEnabled(sPluginInformation.isEnabled()); pluginDescriptor.setInstallForNewUsers(sPluginInformation.isInstallForNewUsers()); pluginDescriptor.setPluginBundleVersion(session.get(pluginBundleVersionId, OldQuery.getDefault()));
public PluginInformation convertFromSObject(SPluginInformation input, PluginInformation result, DatabaseSession session) throws BimserverDatabaseException { if (input == null) { return null; } result.setName(input.getName()); result.setType(PluginType.values()[input.getType().ordinal()]); result.setDescription(input.getDescription()); result.setEnabled(input.isEnabled()); result.setIdentifier(input.getIdentifier()); result.setInstallForAllUsers(input.isInstallForAllUsers()); result.setInstallForNewUsers(input.isInstallForNewUsers()); return result; }
pluginDescriptor.setPluginInterfaceClassName(getPluginInterface(plugin.getClass()).getName()); pluginDescriptor.setEnabled(sPluginInformation.isEnabled()); pluginDescriptor.setInstallForNewUsers(sPluginInformation.isInstallForNewUsers()); PluginBundleVersion value = session.get(pluginBundleVersionId, OldQuery.getDefault()); pluginDescriptor.setPluginBundleVersion(value);