Creates a SoySauce.
494934
public SoySauce build() {
    if (scopedData == null) {
      scopedData = new SoySimpleScope();
    }
    if (loader == null) {
      loader = SoySauceBuilder.class.getClassLoader();
    }
    return new SoySauceImpl(
        new CompiledTemplates(readDelTemplatesFromMetaInf(loader), loader),
        scopedData.enterable(),
        userFunctions, // We don't need internal functions because they only matter at compile time
        ImmutableMap.<String, SoyPrintDirective>builder()
            // but internal directives are still required at render time.
            // in order to handle escaping logging function invocations.
            .putAll(InternalPlugins.internalDirectiveMap(scopedData))
            .putAll(userDirectives)
            .build(),
        userPluginInstances);
  }
903428
private static void addCodeToProvideSoyNamespace(StringBuilder header, SoyFileNode soyFile) {
    header.append("goog.provide('").append(soyFile.getNamespace()).append("');\n");
  }
1211013
public CmsJspStandardContextBean createCopy() {

        CmsJspStandardContextBean result = new CmsJspStandardContextBean();
        result.m_container = m_container;
        if (m_detailContentResource != null) {
            result.m_detailContentResource = m_detailContentResource.getCopy();
        }
        result.m_element = m_element;
        result.setPage(m_page);
        return result;
    }
282874
private void createSystemMenu()
	{

		JMenu system = new JMenu("System");

		JMenuItem importConfig = new JMenuItem("Import Configuration");
		importConfig.addActionListener(new ActionListener()
		{
			@Override
			public void actionPerformed(final ActionEvent e)
			{
				controller.loadConfiguration();
			}
		});

		system.add(importConfig);

		JMenuItem exportConfig = new JMenuItem("Export Configuration");
		exportConfig.addActionListener(new ActionListener()
		{
			@Override
			public void actionPerformed(final ActionEvent e)
			{
				controller.saveConfiguration();
			}
		});

		system.add(exportConfig);

		system.addSeparator();

		JMenuItem defaultConfig = new JMenuItem(
				"Reset to default parameters");
		defaultConfig.addActionListener(new ActionListener()
		{
			@Override
			public void actionPerformed(final ActionEvent e)
			{
				controller.defaultConfiguration();
			}
		});

		system.add(defaultConfig);

		system.addSeparator();

		JMenuItem systemClose = new JMenuItem("Close");
		systemClose.addActionListener(new ActionListener()
		{
			@Override
			public void actionPerformed(final ActionEvent e)
			{
				System.exit(-1);
			}
		});

		system.add(systemClose);

		this.add(system);
	}
881711
static SoyExpression createProto(
      ProtoInitNode node,
      Function<ExprNode, SoyExpression> compilerFunction,
      Supplier<? extends ExpressionDetacher> detacher,
      TemplateVariableManager varManager) {
    return new ProtoInitGenerator(node, compilerFunction, detacher, varManager).generate();
  }
968942
private CmsContextMenuEntry createMenuEntryForElementView(
        final CmsElementViewInfo elementView,
        boolean isActive,
        I_CmsContextMenuHandler handler) {

        CmsContextMenuEntry menuEntry = new CmsContextMenuEntry(handler, null, new I_CmsContextMenuCommand() {

            public void execute(
                CmsUUID innerStructureId,
                I_CmsContextMenuHandler innerHandler,
                CmsContextMenuEntryBean bean) {

                setElementView(elementView, null);
            }

            public A_CmsContextMenuItem getItemWidget(
                CmsUUID innerStructureId,
                I_CmsContextMenuHandler innerHandler,
                CmsContextMenuEntryBean bean) {

                return null;
            }

            public boolean hasItemWidget() {

                return false;
            }
        });
        CmsContextMenuEntryBean bean = new CmsContextMenuEntryBean();
        bean.setLabel(elementView.getTitle());

        I_CmsInputCss inputCss = I_CmsInputLayoutBundle.INSTANCE.inputCss();
        bean.setIconClass(isActive ? inputCss.checkBoxImageChecked() : "");
        bean.setActive(!isActive);
        bean.setVisible(true);
        menuEntry.setBean(bean);
        return menuEntry;

    }
80148
@Override
  public SoyMsgBundle exec(SoyNode node) {
    Preconditions.checkArgument(node instanceof SoyFileSetNode || node instanceof SoyFileNode);

    msgs = Lists.newArrayList();
    visit(node);
    Collections.sort(msgs, SOURCE_LOCATION_ORDERING);
    return new SoyMsgBundleImpl(null, msgs);
  }
598523
public final JMenuItem createMenuItem(String faceDescriptorId, MenuFactory menuFactory) {
		return createMenuItem(faceDescriptorId, menuFactory, getMenuItemButtonConfigurer());
	}
910444
private void generateOnCreate(String dataSourceNameClazz) {
		MethodSpec.Builder methodBuilder = MethodSpec.methodBuilder("onCreate").addModifiers(Modifier.PUBLIC).addAnnotation(Override.class).returns(Boolean.TYPE);

		methodBuilder.addJavadoc("<p>Create datasource and open database in read mode.</p>\n");
		methodBuilder.addJavadoc("\n");
		methodBuilder.addJavadoc("@see android.content.ContentProvider#onCreate()\n");

		methodBuilder.beginControlFlow("if ($T.getContext()==null)", KriptonLibrary.class);
		methodBuilder.addStatement("KriptonLibrary.init(getContext())");
		methodBuilder.endControlFlow();
		methodBuilder.addStatement("dataSource = $L.getInstance()", dataSourceNameClazz);
		methodBuilder.addStatement("dataSource.openWritableDatabase()");

		methodBuilder.addCode("return true;\n");

		classBuilder.addMethod(methodBuilder.build());
	}
174059
private ServerCompilationPrimitives compileForServerRendering() {
    ParseResult result = parse();
    throwIfErrorsPresent();

    SoyFileSetNode soyTree = result.fileSet();
    TemplateRegistry registry = result.registry();
    // Clear the SoyDoc strings because they use unnecessary memory, unless we have a cache, in
    // which case it is pointless.
    if (cache == null) {
      new ClearSoyDocStringsVisitor().exec(soyTree);
    }

    throwIfErrorsPresent();
    return new ServerCompilationPrimitives(registry, soyTree);
  }
320538
def make_inst():
    """"""
    F,c,d = multidict({       # cost # composition
        "QPounder" :  [ 1.84, {"Cal":510, "Carbo":34, "Protein":28,
                               "VitA":15, "VitC":  6, "Calc":30, "Iron":20}],
        "McLean"   :  [ 2.19, {"Cal":370, "Carbo":35, "Protein":24, "VitA":15,
                               "VitC": 10, "Calc":20, "Iron":20}],
        "Big Mac"  :  [ 1.84, {"Cal":500, "Carbo":42, "Protein":25,
                               "VitA": 6, "VitC":  2, "Calc":25, "Iron":20}],
        "FFilet"   :  [ 1.44, {"Cal":370, "Carbo":38, "Protein":14,
                               "VitA": 2, "VitC":  0, "Calc":15, "Iron":10}],
        "Chicken"  :  [ 2.29, {"Cal":400, "Carbo":42, "Protein":31,
                               "VitA": 8, "VitC": 15, "Calc":15, "Iron": 8}],
        "Fries"    :  [  .77, {"Cal":220, "Carbo":26, "Protein": 3,
                               "VitA": 0, "VitC": 15, "Calc": 0, "Iron": 2}],
        "McMuffin" :  [ 1.29, {"Cal":345, "Carbo":27, "Protein":15,
                               "VitA": 4, "VitC":  0, "Calc":20, "Iron":15}],
        "1% LFMilk":  [  .60, {"Cal":110, "Carbo":12, "Protein": 9,
                               "VitA":10, "VitC":  4, "Calc":30, "Iron": 0}],
        "OrgJuice" :  [  .72, {"Cal": 80, "Carbo":20, "Protein": 1,
                               "VitA": 2, "VitC":120, "Calc": 2, "Iron": 2}],
        })

    N,a,b = multidict({       # min,max intake
        "Cal"     : [ 2000,  None ],
        "Carbo"   : [  350,  375 ],
        "Protein" : [   55,  None ],
        "VitA"    : [  100,  None ],
        "VitC"    : [  100,  None ],
        "Calc"    : [  100,  None ],
        "Iron"    : [  100,  None ],
     })

    return F,N,a,b,c,d
1350355
def create(cls, serializable_instance):
    """"""
    if not Serializable.is_serializable(serializable_instance):
      raise ValueError('Can only create pickles for Serializable objects, given {} of type {}'
                       .format(serializable_instance, type(serializable_instance).__name__))
    return cls(unpickle_func=_unpickle_serializable,
               args=(type(serializable_instance), serializable_instance._asdict()))
677446
@Provides
  SoyFileSet.Builder provideBuilder(SoyFileSet.CoreDependencies coreDeps) {
    return new SoyFileSet.Builder(coreDeps);
  }
1075125
@Override
    public ConsoleEditor create(String flavor, Terminal terminal, InputStream in, PrintStream out) throws EditorInitializationException {
        if (flavorMap.containsKey(flavor)) {
            Class<? extends ConsoleEditor> editorClass = flavorMap.get(flavor);
            try {
                return instantiate(editorClass, terminal, in, out);
            } catch (Exception e) {
                throw new EditorInitializationException("Failed to create Editor instance of class:" + editorClass.getName(), e);
            }
        } else {
            Class<? extends ConsoleEditor> editorClass = resolve(flavor);
            if (editorClass != null) {
                flavorMap.put(flavor, editorClass);
                return create(flavor, terminal);
            } else {
                throw new EditorInitializationException("Unknown flavor:" + flavor);
            }
        }
    }
222925
@Override
	public Contents createIfNotExists(Contents contents) throws SQLException {
		verifyCreate(contents);
		return super.createIfNotExists(contents);
	}
428016
def _create(attributes, execute_hooks = true)
      resource = repository.scope { model.send(execute_hooks ? :create : :create!, default_attributes.merge(attributes)) }
      self << resource if resource.saved?
      resource
    end
600134
def create(cls):
        

        class NewPopupCreateView(PopupCreateView, cls.parent_class):
            model = cls.model
            form_class = cls.form_class
            popup_name = cls.get_class_verbose_name()
            template_name = cls.get_template_name_create()
            permission_required = cls.get_permission_required('create')

            def get_context_data(self, **kwargs):
                kwargs.update(cls.context_for_all)
                kwargs.update(cls.context_for_create)
                return super(NewPopupCreateView, self).get_context_data(**kwargs)

        return NewPopupCreateView