test_class.declarator: SELF = "SELF_"
test_class.modifier: private final
test_class.original_string: private final String SELF = "SELF_";
test_class.type: String
test_class.var_name: SELF
test_class.declarator: interface1 = "interface1"
test_class.modifier: private final
test_class.original_string: private final String interface1 = "interface1";
test_class.type: String
test_class.var_name: interface1
test_class.declarator: operation1 = "operation1"
test_class.modifier: private final
test_class.original_string: private final String operation1 = "operation1";
test_class.type: String
test_class.var_name: operation1
test_class.declarator: fake1 = "FAKE1"
test_class.modifier: private final
test_class.original_string: private final String fake1 = "FAKE1";
test_class.type: String
test_class.var_name: fake1
test_class.declarator: fake2 = "FAKE2"
test_class.modifier: private final
test_class.original_string: private final String fake2 = "FAKE2";
test_class.type: String
test_class.var_name: fake2
test_class.declarator: fake3 = "FAKE3"
test_class.modifier: private final
test_class.original_string: private final String fake3 = "FAKE3";
test_class.type: String
test_class.var_name: fake3
test_class.declarator: fake4 = "FAKE4"
test_class.modifier: private final
test_class.original_string: private final String fake4 = "FAKE4";
test_class.type: String
test_class.var_name: fake4
test_class.declarator: fake5 = "FAKE5"
test_class.modifier: private final
test_class.original_string: private final String fake5 = "FAKE5";
test_class.type: String
test_class.var_name: fake5
test_class.declarator: fakeCapa1 = "fakecapa1"
test_class.modifier: private final
test_class.original_string: private final String fakeCapa1 = "fakecapa1";
test_class.type: String
test_class.var_name: fakeCapa1
test_class.declarator: node1 = "node1"
test_class.modifier: private final
test_class.original_string: private final String node1 = "node1";
test_class.type: String
test_class.var_name: node1
test_class.declarator: node2 = "node2"
test_class.modifier: private final
test_class.original_string: private final String node2 = "node2";
test_class.type: String
test_class.var_name: node2
test_class.file: alien4cloud-core/src/test/java/alien4cloud/tosca/PaaSUtilsTest.java
test_class.identifier: PaaSUtilsTest
test_case.body: @Test
      public void injectNodeTemplatePropertiesAsInputs() throws Exception {
          // NodeType nodeType = buildFakeNodeType("test.node.fake1", "1");
  
          PaaSNodeTemplate paaSNodeTemplate = buildPaaSNodeTemplate();
  
          PaaSUtils.processNodeTemplateProperties(paaSNodeTemplate);
  
          Operation operation = paaSNodeTemplate.getInterfaces().get(interface1).getOperations().get(operation1);
          Assert.assertNotNull(operation.getInputParameters());
  
          // assert all node properties are inputs properties
          Assert.assertTrue(operation.getInputParameters().containsKey(SELF + fake1));
          Assert.assertTrue(operation.getInputParameters().containsKey(SELF + fake5));
          Assert.assertTrue(operation.getInputParameters().containsKey(SELF + fake2));
          // complex property should not be there
          Assert.assertFalse(operation.getInputParameters().containsKey(fake3));
  
          // assert that the property from the operation has not been overrided
          Assert.assertEquals(operation.getInputParameters().get(fake1), new ScalarPropertyValue("1_from_operation"));
  
          // check capabilities inputs
          Assert.assertTrue(operation.getInputParameters().containsKey(SELF + generateCapaInputName(fakeCapa1, fake1)));
          Assert.assertTrue(operation.getInputParameters().containsKey(SELF + generateCapaInputName(fakeCapa1, fake3)));
          Assert.assertTrue(operation.getInputParameters().containsKey(SELF + generateCapaInputName(fakeCapa1, fake2)));
          Assert.assertTrue(operation.getInputParameters().containsKey(SELF + generateCapaInputName(fakeCapa1, fake5)));
      }
test_case.class_method_signature: PaaSUtilsTest.injectNodeTemplatePropertiesAsInputs()
test_case.full_signature: @Test public void injectNodeTemplatePropertiesAsInputs()
test_case.identifier: injectNodeTemplatePropertiesAsInputs
test_case.invocations: buildPaaSNodeTemplate processNodeTemplateProperties get getOperations get getInterfaces assertNotNull getInputParameters assertTrue containsKey getInputParameters assertTrue containsKey getInputParameters assertTrue containsKey getInputParameters assertFalse containsKey getInputParameters assertEquals get getInputParameters assertTrue containsKey getInputParameters generateCapaInputName assertTrue containsKey getInputParameters generateCapaInputName assertTrue containsKey getInputParameters generateCapaInputName assertTrue containsKey getInputParameters generateCapaInputName
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void injectNodeTemplatePropertiesAsInputs()
focal_class.declarator: CAPABILITIES = "CAPABILITIES"
focal_class.modifier: public final static
focal_class.original_string: public final static String CAPABILITIES = "CAPABILITIES";
focal_class.type: String
focal_class.var_name: CAPABILITIES
focal_class.file: alien4cloud-core/src/main/java/alien4cloud/tosca/PaaSUtils.java
focal_class.identifier: PaaSUtils
focal_class.class_method_signature: PaaSUtils.getMandatoryHostTemplate(final PaaSNodeTemplate paaSNodeTemplate)
focal_class.full_signature: public static PaaSNodeTemplate getMandatoryHostTemplate(final PaaSNodeTemplate paaSNodeTemplate)
focal_class.identifier: getMandatoryHostTemplate
focal_class.modifiers: public static
focal_class.parameters: (final PaaSNodeTemplate paaSNodeTemplate)
focal_class.return: PaaSNodeTemplate
focal_class.signature: PaaSNodeTemplate getMandatoryHostTemplate(final PaaSNodeTemplate paaSNodeTemplate)
focal_class.class_method_signature: PaaSUtils.getHostTemplate(PaaSNodeTemplate paaSNodeTemplate)
focal_class.full_signature: public static PaaSNodeTemplate getHostTemplate(PaaSNodeTemplate paaSNodeTemplate)
focal_class.identifier: getHostTemplate
focal_class.modifiers: public static
focal_class.parameters: (PaaSNodeTemplate paaSNodeTemplate)
focal_class.return: PaaSNodeTemplate
focal_class.signature: PaaSNodeTemplate getHostTemplate(PaaSNodeTemplate paaSNodeTemplate)
focal_class.class_method_signature: PaaSUtils.injectPropertiesAsOperationInputs(Map<String, PaaSNodeTemplate> nodeTemplates)
focal_class.full_signature: public static void injectPropertiesAsOperationInputs(Map<String, PaaSNodeTemplate> nodeTemplates)
focal_class.identifier: injectPropertiesAsOperationInputs
focal_class.modifiers: public static
focal_class.parameters: (Map<String, PaaSNodeTemplate> nodeTemplates)
focal_class.return: void
focal_class.signature: void injectPropertiesAsOperationInputs(Map<String, PaaSNodeTemplate> nodeTemplates)
focal_class.class_method_signature: PaaSUtils.processNodeTemplateProperties(PaaSNodeTemplate paaSTemplate)
focal_class.full_signature: public static void processNodeTemplateProperties(PaaSNodeTemplate paaSTemplate)
focal_class.identifier: processNodeTemplateProperties
focal_class.modifiers: public static
focal_class.parameters: (PaaSNodeTemplate paaSTemplate)
focal_class.return: void
focal_class.signature: void processNodeTemplateProperties(PaaSNodeTemplate paaSTemplate)
focal_class.class_method_signature: PaaSUtils.injectCapabilitiesProperties(NodeTemplate template, Map<String, Interface> interfaces)
focal_class.full_signature: private static void injectCapabilitiesProperties(NodeTemplate template, Map<String, Interface> interfaces)
focal_class.identifier: injectCapabilitiesProperties
focal_class.modifiers: private static
focal_class.parameters: (NodeTemplate template, Map<String, Interface> interfaces)
focal_class.return: void
focal_class.signature: void injectCapabilitiesProperties(NodeTemplate template, Map<String, Interface> interfaces)
focal_class.class_method_signature: PaaSUtils.processRelationshipTemplateProperties(PaaSRelationshipTemplate paaSRelationshipTemplate,
              Map<String, PaaSNodeTemplate> paaSNodeTemplates)
focal_class.full_signature: public static void processRelationshipTemplateProperties(PaaSRelationshipTemplate paaSRelationshipTemplate,
              Map<String, PaaSNodeTemplate> paaSNodeTemplates)
focal_class.identifier: processRelationshipTemplateProperties
focal_class.modifiers: public static
focal_class.parameters: (PaaSRelationshipTemplate paaSRelationshipTemplate,
              Map<String, PaaSNodeTemplate> paaSNodeTemplates)
focal_class.return: void
focal_class.signature: void processRelationshipTemplateProperties(PaaSRelationshipTemplate paaSRelationshipTemplate,
              Map<String, PaaSNodeTemplate> paaSNodeTemplates)
focal_class.class_method_signature: PaaSUtils.injectTargetedCapabilityProperties(PaaSNodeTemplate target, String capabilityName, Map<String, Interface> interfaces)
focal_class.full_signature: private static void injectTargetedCapabilityProperties(PaaSNodeTemplate target, String capabilityName, Map<String, Interface> interfaces)
focal_class.identifier: injectTargetedCapabilityProperties
focal_class.modifiers: private static
focal_class.parameters: (PaaSNodeTemplate target, String capabilityName, Map<String, Interface> interfaces)
focal_class.return: void
focal_class.signature: void injectTargetedCapabilityProperties(PaaSNodeTemplate target, String capabilityName, Map<String, Interface> interfaces)
focal_class.class_method_signature: PaaSUtils.injectSourcePropertiesAsInputs(PaaSNodeTemplate source, Map<String, Interface> interfaces)
focal_class.full_signature: private static void injectSourcePropertiesAsInputs(PaaSNodeTemplate source, Map<String, Interface> interfaces)
focal_class.identifier: injectSourcePropertiesAsInputs
focal_class.modifiers: private static
focal_class.parameters: (PaaSNodeTemplate source, Map<String, Interface> interfaces)
focal_class.return: void
focal_class.signature: void injectSourcePropertiesAsInputs(PaaSNodeTemplate source, Map<String, Interface> interfaces)
focal_class.class_method_signature: PaaSUtils.injectTargetPropertiesAsInputs(PaaSNodeTemplate target, Map<String, Interface> interfaces)
focal_class.full_signature: private static void injectTargetPropertiesAsInputs(PaaSNodeTemplate target, Map<String, Interface> interfaces)
focal_class.identifier: injectTargetPropertiesAsInputs
focal_class.modifiers: private static
focal_class.parameters: (PaaSNodeTemplate target, Map<String, Interface> interfaces)
focal_class.return: void
focal_class.signature: void injectTargetPropertiesAsInputs(PaaSNodeTemplate target, Map<String, Interface> interfaces)
focal_class.class_method_signature: PaaSUtils.injectPropertiesAsInputs(String entity, String capabilityName, Map<String, AbstractPropertyValue> properties,
              Map<String, Interface> interfaces, Function<String, String> inputNameBuilder)
focal_class.full_signature: private static void injectPropertiesAsInputs(String entity, String capabilityName, Map<String, AbstractPropertyValue> properties,
              Map<String, Interface> interfaces, Function<String, String> inputNameBuilder)
focal_class.identifier: injectPropertiesAsInputs
focal_class.modifiers: private static
focal_class.parameters: (String entity, String capabilityName, Map<String, AbstractPropertyValue> properties,
              Map<String, Interface> interfaces, Function<String, String> inputNameBuilder)
focal_class.return: void
focal_class.signature: void injectPropertiesAsInputs(String entity, String capabilityName, Map<String, AbstractPropertyValue> properties,
              Map<String, Interface> interfaces, Function<String, String> inputNameBuilder)
focal_class.class_method_signature: PaaSUtils.injectInputIntoOperations(String inputName, List<String> path, AbstractPropertyValue value, Map<String, Operation> operations)
focal_class.full_signature: private static void injectInputIntoOperations(String inputName, List<String> path, AbstractPropertyValue value, Map<String, Operation> operations)
focal_class.identifier: injectInputIntoOperations
focal_class.modifiers: private static
focal_class.parameters: (String inputName, List<String> path, AbstractPropertyValue value, Map<String, Operation> operations)
focal_class.return: void
focal_class.signature: void injectInputIntoOperations(String inputName, List<String> path, AbstractPropertyValue value, Map<String, Operation> operations)
focal_method.body: public static void processNodeTemplateProperties(PaaSNodeTemplate paaSTemplate) {
          NodeTemplate template = paaSTemplate.getTemplate();
          // inject nodetemplate properties
          if (MapUtils.isNotEmpty(template.getProperties())) {
              injectPropertiesAsInputs(ToscaFunctionConstants.SELF, null, template.getProperties(), paaSTemplate.getInterfaces(),
                      baseName -> StringUtils.joinWith(AlienUtils.DEFAULT_PREFIX_SEPARATOR, ToscaFunctionConstants.SELF, baseName));
          }
          // inject capabilities properties
          injectCapabilitiesProperties(template, paaSTemplate.getInterfaces());
      }
focal_method.class_method_signature: PaaSUtils.processNodeTemplateProperties(PaaSNodeTemplate paaSTemplate)
focal_method.full_signature: public static void processNodeTemplateProperties(PaaSNodeTemplate paaSTemplate)
focal_method.identifier: processNodeTemplateProperties
focal_method.invocations: getTemplate isNotEmpty getProperties injectPropertiesAsInputs getProperties getInterfaces joinWith injectCapabilitiesProperties getInterfaces
focal_method.modifiers: public static
focal_method.parameters: (PaaSNodeTemplate paaSTemplate)
focal_method.return: void
focal_method.signature: void processNodeTemplateProperties(PaaSNodeTemplate paaSTemplate)