Process and retrieve the component arguments that are needed to init the component template
546996
function() {
    // determine if cpt supports template arguments
    if (this.template) {
      // as template can be changed dynamically we have to sync the constructor
      this.ctlConstuctor=this.template.controllerConstructor;
    }
    var ctlProto=this.ctlConstuctor.prototype;
    this.ctlAttributes=ctlProto.$attributes;
    this.ctlElements=ctlProto.$elements;

    // load template arguments
    this.loadCptAttElements();

    // load child elements before processing the template
    var cptArgs={
      nodeInstance:this,
      $attributes:{},
      $content:null
    };
    var attributes=cptArgs.$attributes, att;

    if (this.atts) {
      // some attributes have been passed to this instance - so we push them to cptArgs
      // so that they are set on the controller when the template are rendered
      var atts = this.atts, eh = this.eh, pvs = this.vscope, nm;
      if (atts) {
        for (var i = 0, sz = this.atts.length; sz > i; i++) {
          att = atts[i];
          nm = att.name;
          if (this.ctlAttributes[nm].type!=="template") {
            attributes[nm]=att.getValue(eh, pvs, null);
          }
        }
      }
    }

    if (this.tplAttributes) {
      var tpa=this.tplAttributes;
      for (var k in tpa) {
        // set the template attribute value on the controller
        if (tpa.hasOwnProperty(k)) {
          attributes[k]=tpa[k];
        }
      }
    }
    if (this.childElements) {
      cptArgs.$content=this.getControllerContent();
    }
    return cptArgs;
  }
1250887
function getComponents(templateSrc, filename, options){
  var $ = cheerio.load('<div>' + templateSrc + '</div>');
  var components = [];

  var nodeIndex = 0;

  $('*').contents().map(function(index, $el) {
  
    if ($el.type === 'comment') {
      var src = $el.data.trim();

      // keyword check
      if(isComponentComment(src, options.keyword)){
        src = src.substring(options.keyword.length);
        var meta = YAML.safeLoad(src) || {};
        
        var nodes = getComponentHtml($, $el, $.html($($el).nextAll()), options.keyword, meta);
        var html = nodes.filter(function(node) { 
          return (node.trim() !== '');
        }).join('\n');

        var output = render(html, meta, options.block);

        var component = {
          meta: meta,
          file: filename,
          output: output.trim()
        };

        // push comment
        return components.push(component);
      }
    }
  }.bind(this));

  return components;
}
84804
function initModule (args) {
    // require string name
    this.assert(typeof args.name === 'string' && args.name.length, 101)
    // component must not already be defined
    this.assert(!defined(this.global().components[args.name]), 102, `${args.name} component already defined`)
    // store name
    this.name = args.name
    // create module name from string with `Component` appended
    this.moduleName = `${this.name}Component`
    // create new module - throws error if defined
    this.module = ImmutableCore.module(this.moduleName, {})
    // add info to module meta
    this.module.meta.class = 'ImmutableCoreComponent'
    this.module.meta.instance = this
    // add component to global register
    this.global().components[this.name] = this
}
274438
private void processPropDefaultValues() {
    getMethodsWithAnnotation(component, PropDefault.class).forEach(method -> {
      PropDefault propValidator = method.getAnnotation(PropDefault.class);

      String exposedMethodName = exposeExistingJavaMethodToJs(method);
      String propertyName = propValidator.value();
      optionsBuilder.addStatement("options.addJavaPropDefaultValue(p.$L, $S)",
          exposedMethodName,
          propertyName);
    });
  }
514434
public void init() {
        OptionsParam options = Model.getSingleton().getOptionsParam();
        mainFrame = new MainFrame(options, getRequestPanel(), getResponsePanel());
        mainFrame.getWorkbench().addPanel(View.getSingleton().getSiteTreePanel(), WorkbenchPanel.PanelType.SELECT);

        // Install default editor and renderer for TextMessageLocationHighlight
        MessageLocationHighlightRenderersEditors.getInstance().addEditor(
                TextMessageLocationHighlight.class,
                new TextMessageLocationHighlightEditor());
        MessageLocationHighlightRenderersEditors.getInstance().addRenderer(
                TextMessageLocationHighlight.class,
                new TextMessageLocationHighlightRenderer());
        
        String statusString;
        for(Status status : AddOn.Status.values()) {     	
        	// Handle the case AddOn.Status gets out of sync with cfu.status i18n entries
        	String i18nKey = "cfu.status." + status.toString();
        	if (Constant.messages.containsKey(i18nKey)) {
        		statusString = Constant.messages.getString(i18nKey);
        	} else {
        		statusString = status.toString();
        	}
        	statusMap.put(status, new StatusUI(status, statusString));
        }
    }
376095
private void initComponents() {
		fileLabel = new JLabel();
		fileTextField = new ZapTextField();
		browseButton = new JButton();
		nameLabel = new JLabel();
		nameTextField = new ZapTextField();
		slotLabel = new JLabel();
		slotTextField = new ZapTextField();
		slotListIndexLabel = new JLabel();
		slotListIndexTextField = new ZapTextField();
		addButton = new JButton();
		deleteButton = new JButton();
		closeButton = new JButton();
		driverScrollPane = new JScrollPane();
		driverTable = new JTable();

		setTitle(Constant.messages.getString("certificates.pkcs11.drivers.title"));
		fileLabel.setText(Constant.messages.getString("certificates.pkcs11.drivers.label.path"));

		browseButton.setText(Constant.messages.getString("certificates.pkcs11.drivers.button.browse"));
		browseButton.addActionListener(new ActionListener() {
			@Override
			public void actionPerformed(ActionEvent evt) {
				browseButtonActionPerformed(evt);
			}
		});

		nameLabel.setText(Constant.messages.getString("certificates.pkcs11.drivers.label.name"));

		slotLabel.setText(Constant.messages.getString("certificates.pkcs11.drivers.label.slot"));

		slotListIndexLabel.setText(Constant.messages.getString("certificates.pkcs11.drivers.label.slotIndex"));

		addButton.setText(Constant.messages.getString("certificates.pkcs11.drivers.button.add"));
		addButton.addActionListener(new ActionListener() {
			@Override
			public void actionPerformed(ActionEvent evt) {
				addButtonActionPerformed(evt);
			}
		});

		deleteButton.setText(Constant.messages.getString("certificates.pkcs11.drivers.button.delete"));
		deleteButton.addActionListener(new ActionListener() {
			@Override
			public void actionPerformed(ActionEvent evt) {
				deleteButtonActionPerformed(evt);
			}
		});

		closeButton.setText(Constant.messages.getString("certificates.pkcs11.drivers.button.close"));
		closeButton.addActionListener(new ActionListener() {
			@Override
			public void actionPerformed(ActionEvent evt) {
				closeButtonActionPerformed(evt);
			}
		});

		driverTable.setModel(driverTableModel);
		driverScrollPane.setViewportView(driverTable);

		// When experimental SlotListIndex support is used, the slotTextField is disabled (and vice versa),
		// as only one of these parameters is actually used.
		if (!Model.getSingleton().getOptionsParam().getExperimentalFeaturesParam().isExerimentalSliSupportEnabled()) {
			slotTextField.setEnabled(false);
		}
		
		
		final GroupLayout layout = new GroupLayout(getContentPane());
		getContentPane().setLayout(layout);
		layout.setHorizontalGroup(layout
				.createParallelGroup(GroupLayout.Alignment.LEADING)
				.addGroup(
						layout.createSequentialGroup()
								.addContainerGap()
								.addGroup(
										layout.createParallelGroup(
												GroupLayout.Alignment.LEADING)
												.addComponent(fileLabel)
												.addComponent(nameLabel)
												.addComponent(slotLabel)
												.addComponent(slotListIndexLabel)
												.addGroup(
														layout.createSequentialGroup()
																.addGroup(
																		layout.createParallelGroup(
																				GroupLayout.Alignment.TRAILING,
																				false)
																				.addComponent(
																						nameTextField,
																						GroupLayout.Alignment.LEADING)
																				.addComponent(
																						slotTextField,
																						GroupLayout.Alignment.LEADING)
																				.addComponent(
																						slotListIndexTextField,
																						GroupLayout.Alignment.LEADING)
																				.addComponent(
																						fileTextField,
																						GroupLayout.Alignment.LEADING,
																						GroupLayout.DEFAULT_SIZE,
																						322,
																						Short.MAX_VALUE))

																.addPreferredGap(
																		LayoutStyle.ComponentPlacement.RELATED)
																.addGroup(
																		layout.createParallelGroup(
																				GroupLayout.Alignment.LEADING)
																				.addComponent(
																						addButton,
																						GroupLayout.DEFAULT_SIZE,
																						80,
																						Short.MAX_VALUE)
																				.addComponent(
																						browseButton))))
								.addContainerGap(165, Short.MAX_VALUE))
				.addGroup(
						GroupLayout.Alignment.TRAILING,
						layout.createSequentialGroup()
								.addGap(499, 499, 499)
								.addComponent(closeButton,
										GroupLayout.DEFAULT_SIZE, 74,
										Short.MAX_VALUE).addContainerGap())
				.addGroup(
						layout.createSequentialGroup()
								.addContainerGap()
								.addComponent(driverScrollPane,
										GroupLayout.DEFAULT_SIZE, 561,
										Short.MAX_VALUE).addContainerGap())
				.addGroup(
						GroupLayout.Alignment.TRAILING,
						layout.createSequentialGroup()
								.addContainerGap(499, Short.MAX_VALUE)
								.addComponent(deleteButton).addContainerGap()));
		layout.setVerticalGroup(layout
				.createParallelGroup(GroupLayout.Alignment.LEADING)
				.addGroup(
						GroupLayout.Alignment.TRAILING,
						layout.createSequentialGroup()
								.addContainerGap()

								.addComponent(fileLabel)
								.addPreferredGap(
										LayoutStyle.ComponentPlacement.RELATED)
								.addGroup(
										layout.createParallelGroup(
												GroupLayout.Alignment.LEADING,
												false)
												.addComponent(browseButton, 0,
														0, Short.MAX_VALUE)
												.addComponent(fileTextField))
								.addPreferredGap(
										LayoutStyle.ComponentPlacement.RELATED)

								.addComponent(nameLabel)
								.addPreferredGap(
										LayoutStyle.ComponentPlacement.RELATED)
								.addGroup(
										layout.createParallelGroup(
												GroupLayout.Alignment.BASELINE)
												.addComponent(
														nameTextField,
														GroupLayout.PREFERRED_SIZE,
														GroupLayout.DEFAULT_SIZE,
														GroupLayout.PREFERRED_SIZE))
								.addPreferredGap(
										LayoutStyle.ComponentPlacement.RELATED)

								.addComponent(slotLabel)
								.addPreferredGap(
										LayoutStyle.ComponentPlacement.RELATED)
								.addGroup(
										layout.createParallelGroup(
												GroupLayout.Alignment.BASELINE)
												.addComponent(
														slotTextField,
														GroupLayout.PREFERRED_SIZE,
														GroupLayout.DEFAULT_SIZE,
														GroupLayout.PREFERRED_SIZE))
								.addGap(28, 28, 28)

								.addComponent(slotListIndexLabel)
								.addPreferredGap(
										LayoutStyle.ComponentPlacement.RELATED)
								.addGroup(
										layout.createParallelGroup(
												GroupLayout.Alignment.BASELINE)
												.addComponent(
														slotListIndexTextField,
														GroupLayout.PREFERRED_SIZE,
														GroupLayout.DEFAULT_SIZE,
														GroupLayout.PREFERRED_SIZE)
												.addComponent(
														addButton,
														GroupLayout.PREFERRED_SIZE,
														19,
														GroupLayout.PREFERRED_SIZE))
								.addGap(28, 28, 28)

								.addComponent(driverScrollPane,
										GroupLayout.PREFERRED_SIZE, 195,
										GroupLayout.PREFERRED_SIZE)
								.addPreferredGap(
										LayoutStyle.ComponentPlacement.RELATED)
								.addComponent(deleteButton)
								.addPreferredGap(
										LayoutStyle.ComponentPlacement.RELATED,
										9, Short.MAX_VALUE)
								.addComponent(closeButton,
										GroupLayout.PREFERRED_SIZE, 10,
										GroupLayout.PREFERRED_SIZE)
								.addContainerGap()));

		layout.linkSize(SwingConstants.VERTICAL, new Component[] { addButton,
				browseButton, closeButton, deleteButton, fileTextField,
				nameTextField });

		for (int i=0; i<driverTableModel.getColumnCount(); i++) {
			driverTable.getColumnModel().getColumn(i).setPreferredWidth(driverTableModel.getPreferredWith(i));
		}

		pack();
	}
1235531
function Init(arg) {
    array.push.apply(this, arg && (arg.nodeType || /^o/.test(typeof arg)) && !u.isArray(arg) && arg !== null ? [arg] : u.isArray(arg) ? arg : '' + arg === arg ? u.isHtml(arg) ? u.toHtml(arg) : document.querySelectorAll(arg) : undefined);
  }
556945
function process( $tpl, &$textElements, $functionName, $functionChildren, $functionParameters, $functionPlacement, $rootNamespace, $currentNamespace )
    {
        $params = $functionParameters;
        switch ( $functionName )
        {
            case $this->BlockName:
            {
                $viewMode = "full";
                $name = $currentNamespace;
                // Read ini file
                $toolbarIni = eZINI::instance( "toolbar.ini" );

                if ( isset( $functionParameters["view"] ) )
                {
                    $viewMode = $tpl->elementValue( $functionParameters["view"], $rootNamespace, $currentNamespace, $functionPlacement );
                }

                if ( isset( $functionParameters["name"] ) )
                {
                    reset( $params );
                    $whatParamsShouldBeUnset = array();
                    $whatParamsShouldBeReplaced = array();
                    while ( ( $key = key( $params ) ) !== null )
                    {
                        $item =& $params[$key];
                        switch ( $key )
                        {
                            case "name":
                            case "view":
                                break;

                            default:
                            {
                                if ( !$tpl->hasVariable( $key, $name ) )
                                {
                                    $whatParamsShouldBeUnset[] = $key; // Tpl vars should be removed after including
                                }
                                else
                                {
                                    $whatParamsShouldBeReplaced[$key] = $tpl->variable( $key, $name ); // Tpl vars should be replaced after including
                                }

                                $item_value = $tpl->elementValue( $item, $rootNamespace, $currentNamespace, $functionPlacement );
                                $tpl->setVariable( $key, $item_value, $name );
                            } break;
                        }
                        next( $params );
                    }
                    $toolbarPosition = $tpl->elementValue( $functionParameters["name"], $rootNamespace, $currentNamespace, $functionPlacement );
                    $definedVariables = array();
                    $toolbarName = "Toolbar_" . $toolbarPosition;
                    $toolArray = $toolbarIni->variable( $toolbarName, 'Tool' );

                    if ( !is_array( $toolArray ) )
                        $toolArray = array();

                    $actionParameters = array();
                    foreach ( array_keys( $toolArray ) as $toolKey )
                    {
                        $definedVariables = array();
                        $tool = $toolArray[$toolKey];
                        $placement = $toolKey + 1;
                        if ( $toolbarIni->hasGroup( "Tool_" . $tool ) )
                        {
                            $actionParameters = $toolbarIni->group( "Tool_" . $tool );
                        }
                        if ( $toolbarIni->hasGroup( "Tool_" . $toolbarPosition . "_" . $tool . "_" . $placement ) )
                        {
                            $actionParameters = array_merge( $actionParameters, $toolbarIni->group( "Tool_" . $toolbarPosition . "_" . $tool . "_" . $placement ) );
                        }
                        foreach ( array_keys( $actionParameters ) as $key )
                        {
                            $itemValue = $actionParameters[$key];
                            $tpl->setVariable( $key, $itemValue, $name );
                            $definedVariables[] = $key;
                        }
                        $toolIDValue =  "Tool_" . $toolbarPosition . "_" . $tool . "_" . $placement;
                        $tpl->setVariable( "tool_id", $toolIDValue, $name );
                        $definedVariables[] = "tool_id";
                        $toolOffset = $placement;
                        $tpl->setVariable( "offset", $toolOffset, $name );
                        $definedVariables[] = "offset";
                        $uri = "design:toolbar/$viewMode/$tool.tpl";

                        if ( $placement == 1 )
                        {
                            if ( count( $toolArray ) == 1 )
                            {
                                $tpl->setVariable( "first", true );
                                $tpl->setVariable( "last", true );
                                $tpl->setVariable( "placement", "last" );
                                $definedVariables[] = "first";
                                $definedVariables[] = "last";
                                $definedVariables[] = "placement";
                            }
                            else
                            {
                                $tpl->setVariable( "first", true );
                                $tpl->setVariable( "last", false );
                                $tpl->setVariable( "placement", "first" );
                                $definedVariables[] = "first";
                                $definedVariables[] = "last";
                                $definedVariables[] = "placement";
                            }
                        }
                        else if ( $placement == count( $toolArray ) )
                        {
                            $tpl->setVariable( "first", false );
                            $tpl->setVariable( "last", true );
                            $tpl->setVariable( "placement", "last" );
                            $definedVariables[] = "first";
                            $definedVariables[] = "last";
                            $definedVariables[] = "placement";
                        }
                        else
                        {
                            $tpl->setVariable( "first", false );
                            $tpl->setVariable( "last",  false );
                            $tpl->setVariable( "placement", "" );
                            $definedVariables[] = "placement";
                        }
                        $tpl->processURI( $uri, true, $extraParameters, $textElements, $name, $name );
                        // unset var
                        foreach ( $whatParamsShouldBeUnset as $key )
                        {
                            $tpl->unsetVariable( $key, $name );
                        }
                        // replace var
                        foreach ( $whatParamsShouldBeReplaced as $key => $item_value )
                        {
                            $tpl->setVariable( $key, $item_value, $name );
                        }
                    }
                }
            }
        }
    }
1239066
def get_initkwargs(cls, *args, **kwargs):
        
        assert 'url_name' in kwargs, 'URL name is needed to resolve correct wizard URLs'
        extra_kwargs = {
            'done_step_name': kwargs.pop('done_step_name', 'done'),
            'url_name': kwargs.pop('url_name'),
        }

        initkwargs = super(NamedUrlWizardView, cls).get_initkwargs(*args, **kwargs)
        initkwargs.update(extra_kwargs)

        assert initkwargs['done_step_name'] not in initkwargs['form_list'], \
            'step name "%s" is reserved for "done" view' % initkwargs['done_step_name']
        return initkwargs
445318
protected final void init() {

    Type genericComponentType = null;
    Type genericKeyType = null;
    if (this.type instanceof GenericArrayType) {
      GenericArrayType arrayType = (GenericArrayType) this.type;
      genericComponentType = arrayType.getGenericComponentType();
    }
    if (genericComponentType == null) {
      TypeVariable<?> keyTypeVariable = null;
      TypeVariable<?> componentTypeVariable = null;
      if (this.retrievalClass.isArray()) {
        genericComponentType = this.retrievalClass.getComponentType();
      } else if (Collection.class.isAssignableFrom(this.retrievalClass)) {
        componentTypeVariable = CommonTypeVariables.TYPE_VARIABLE_COLLECTION_ELEMENT;
      } else if (Map.class.isAssignableFrom(this.retrievalClass)) {
        componentTypeVariable = CommonTypeVariables.TYPE_VARIABLE_MAP_VALUE;
        keyTypeVariable = CommonTypeVariables.TYPE_VARIABLE_MAP_KEY;
      }
      if (componentTypeVariable != null) {
        genericComponentType = resolveTypeVariable(componentTypeVariable, this);
        if (genericComponentType == null) {
          genericComponentType = componentTypeVariable;
        }
      }
      if (keyTypeVariable != null) {
        genericKeyType = resolveTypeVariable(keyTypeVariable, this);
        if (genericKeyType == null) {
          genericKeyType = keyTypeVariable;
        }
      }
    }
    if (genericComponentType == null) {
      this.componentType = null;
    } else {
      this.componentType = create(genericComponentType, this.definingType);
    }
    if (genericKeyType == null) {
      this.keyType = null;
    } else {
      this.keyType = create(genericKeyType, this.definingType);
    }
  }
58926
void initialize(AbstractCompiler compiler) throws Exception {
    checkState(
        !Strings.isNullOrEmpty(templateJs),
        "The template JS must be loaded before the scanner is used. "
            + "Make sure that the template file is not empty.");
    Node scriptRoot = new JsAst(SourceFile.fromCode(
        "template", templateJs)).getAstRoot(compiler);

    // The before-templates are kept in a LinkedHashMap, to ensure that they are later iterated
    // over in the order in which they appear in the template JS file.
    LinkedHashMap<String, Node> beforeTemplates = new LinkedHashMap<>();
    Map<String, SortedMap<Integer, Node>> afterTemplates = new HashMap<>();
    Set<String> hasChoices = new HashSet<>();
    for (Node templateNode : scriptRoot.children()) {
      if (templateNode.isFunction()) {
        String fnName = templateNode.getFirstChild().getQualifiedName();
        if (fnName.startsWith("before_")) {
          String templateName = fnName.substring("before_".length());
          Preconditions.checkState(
              !beforeTemplates.containsKey(templateName),
              "Found existing template with the same name: %s", beforeTemplates.get(templateName));
          checkState(
              templateNode.getLastChild().hasChildren(),
              "Before templates are not allowed to be empty!");
          beforeTemplates.put(templateName, templateNode);
        } else if (fnName.startsWith("after_option_")) {
          Matcher m = AFTER_CHOICE_PATTERN.matcher(fnName);
          checkState(m.matches(), "Template name %s must match pattern after_option_\\d*_", fnName);
          int optionNumber = Integer.parseInt(m.group(1));
          String templateName = m.group(2);
          if (!afterTemplates.containsKey(templateName)) {
            afterTemplates.put(templateName, new TreeMap<>());
            hasChoices.add(templateName);
          }
          checkState(
              hasChoices.contains(templateName),
              "Template %s can only be mixed with other after_option_ templates");
          checkState(
              !afterTemplates.get(templateName).containsKey(optionNumber),
              "Found duplicate template for %s, assign unique indexes for options",
              fnName);
          afterTemplates.get(templateName).put(optionNumber, templateNode);
        } else if (fnName.startsWith("after_")) {
          String templateName = fnName.substring("after_".length());
          Preconditions.checkState(
              !afterTemplates.containsKey(templateName),
              "Found existing template with the same name: %s", afterTemplates.get(templateName));
          afterTemplates.put(templateName, ImmutableSortedMap.of(0, templateNode));
        } else if (fnName.startsWith("do_not_change_")) {
          String templateName = fnName.substring("do_not_change_".length());
          Preconditions.checkState(
              !beforeTemplates.containsKey(templateName),
              "Found existing template with the same name: %s",
              beforeTemplates.get(templateName));
          Preconditions.checkState(
              !afterTemplates.containsKey(templateName),
              "Found existing template with the same name: %s",
              afterTemplates.get(templateName));
          beforeTemplates.put(templateName, templateNode);
          afterTemplates.put(templateName, ImmutableSortedMap.of(0, templateNode));
        }
      }
    }

    checkState(
        !beforeTemplates.isEmpty(),
        "Did not find any RefasterJs templates! Make sure that there are 2 functions defined "
            + "with the same name, one with a \"before_\" prefix and one with a \"after_\" prefix");

    // TODO(bangert): Get ImmutableLinkedMap into Guava?
    this.templates = new LinkedHashMap<>();
    for (String templateName : beforeTemplates.keySet()) {
      Preconditions.checkState(
          afterTemplates.containsKey(templateName) && !afterTemplates.get(templateName).isEmpty(),
          "Found before template without at least one corresponding after "
              + " template. Make sure there is an after_%s or after_option_1_%s function defined.",
          templateName,
          templateName);
      ImmutableList.Builder<RefasterJsTemplate> builder = ImmutableList.builder();
      for (Node afterTemplateOption : afterTemplates.get(templateName).values()) {
        builder.add(
            new RefasterJsTemplate(
                compiler.getTypeRegistry(),
                typeMatchingStrategy,
                beforeTemplates.get(templateName),
                afterTemplateOption));
      }
      ImmutableList<RefasterJsTemplate> afterOptions = builder.build();
      this.templates.put(afterOptions.get(0).matcher, afterOptions);
    }
  }
164801
protected void initComponent()
	{
		addOrReplace(form = newForm("form", getModel()));
		form.addOrReplace(signupPanel = newSignupPanel("signupPanel", getModel()));

		form.addOrReplace(submitButton = newButton("signupButton"));
		submitButton.add(
			buttonLabel = newButtonLabel("buttonLabel", "global.button.sign.up.label", "Sign up"));
		form.add(submitButton);

		form.add(new EqualPasswordInputValidator(
			signupPanel.getSigninPanel().getPassword().getPasswordTextField(),
			signupPanel.getRepeatPassword().getPasswordTextField()));
	}
1003607
def compiled_init_func(self):
        """"""

        def get_column_assignment(column_name):
            return ALCHEMY_TEMPLATES.col_assignment.safe_substitute(col_name=column_name)

        def get_compiled_args(arg_name):
            return ALCHEMY_TEMPLATES.func_arg.safe_substitute(arg_name=arg_name)

        join_string = "\n" + self.tab + self.tab
        column_assignments = join_string.join([get_column_assignment(n) for n in self.columns])
        init_args = ", ".join(get_compiled_args(n) for n in self.columns)
        return ALCHEMY_TEMPLATES.init_function.safe_substitute(col_assignments=column_assignments,
                                                               init_args=init_args)
404093
public void init ()
    {
        if (_initers == null) {
            log.warning("Refusing repeat init() request.");
            return;
        }

        ObserverList<InitComponent> list = _initers.toObserverList();
        _initers = null;
        list.apply(new ObserverList.ObserverOp<InitComponent>() {
            public boolean apply (InitComponent comp) {
                log.debug("Initializing component", "comp", comp);
                comp.init();
                return true;
            }
        });
    }
941812
private void processArgument() {
        final StringBuilder argumentBuilder = new StringBuilder();
        while (templateReader.hasNextCharacter()) {
            final char argumentCharacter = templateReader.nextCharacter();
            if (argumentCharacter == syntax.getArgumentClosing()) {
                final String argument = argumentBuilder.toString().trim(); // Getting actual argument name.
                if (Strings.startsWith(argument, syntax.getEquationMarker())) {
                    // Starts with an equation sign. Evaluating.
                    final String equation = LmlUtilities.stripMarker(argument);
                    templateReader.append(newEquation().getResult(equation), equation + " equation");
                } else if (Strings.startsWith(argument, syntax.getConditionMarker())) {
                    // Condition/ternary operator. Evaluating.
                    processConditionArgument(argument, argumentBuilder);
                } else { // Regular argument. Looking for value mapped to the selected key.
                    templateReader.append(Nullables.toString(data.getArgument(argument)), argument + " argument");
                }
                return;
            }
            argumentBuilder.append(argumentCharacter);
        }
    }
3149
function getTemplate(template, options) {
  stack.clear();
  parser.reset();

  let opts = typeof options === 'undefined' ? {} : options;
  opts.strict = typeof opts.strict === 'boolean' ? opts.strict : true;
  opts.preserveWhitespace = typeof opts.preserveWhitespace === 'boolean' ? opts.preserveWhitespace : false;
  opts.validateHtml = opts.validateHtml != null ? opts.validateHtml : 'strict';
  opts.logger = opts.logger != null ? opts.logger : {};

  let lambdas = {};
  if (_.isArray(opts.lambdas)) {
    for (let i = 0; i < opts.lambdas.length; i++) {
      lambdas[opts.lambdas[i]] = true;
    }
  }
  opts.lambdas = lambdas;
  opts.processingHTML = typeof opts.processingHTML === 'boolean' ? opts.processingHTML : true;

  compilerLogger.setStrictMode(opts.strict);
  compilerLogger.setOverrides(opts.logger);
  stack.setHtmlValidation(opts.validateHtml);

  let templateStr = template.toString();

  processTemplate(templateStr, opts);

  let output = {};

  if (stack.stack.length > 0) {
    compilerErrors.notAllTagsWereClosedProperly(stack.stack);
  }

  parser.end();
  output.templateObj = stack.getOutput();
  const Template = require('../template');
  output.template = new Template(output.templateObj);
  output.source = template;
  output.tokens = {};
  _.each(stack.tokens, function(values, type) {
    output.tokens[type] = _.keys(values);
  });
  return output;
}
141204
private Node initTemplate(Node templateFunctionNode) {
    Node prepped = templateFunctionNode.cloneTree();
    prepTemplatePlaceholders(prepped);

    Node body = prepped.getLastChild();
    Node startNode;
    if (body.hasOneChild() && body.getFirstChild().isExprResult()) {
      // When matching an expression, don't require it to be a complete
      // statement.
      startNode = body.getFirstFirstChild();
    } else {
      startNode = body.getFirstChild();
    }

    for (int i = 0; i < templateLocals.size(); i++) {
      // reserve space in the locals array.
      this.localVarMatches.add(null);
    }
    for (int i = 0; i < templateParams.size(); i++) {
      // reserve space in the params array.
      this.paramNodeMatches.add(null);
    }

    return startNode;
  }