Create a new MediaList instance.
        @param mrls: optional list of MRL strings
335254
def media_list_new(self, mrls=None):
        
        l = libvlc_media_list_new(self)
        # We should take the lock, but since we did not leak the
        # reference, nobody else can access it.
        if mrls:
            for m in mrls:
                l.add_media(m)
        l._instance = self
        return l
613784
protected void createDefaultLevels() {
        this.listLevels = new ArrayList();	// listlevels
        for(int i=0; i<=8; i++) {
            // create a list level
            RtfListLevel ll = new RtfListLevel(this.document);
            ll.setListType(RtfListLevel.LIST_TYPE_NUMBERED);
        	ll.setFirstIndent(0);
        	ll.setLeftIndent(0);
        	ll.setLevelTextNumber(i);
            ll.setTentative(true);
            ll.correctIndentation();
            this.listLevels.add(ll);
        }

    }
1041832
private void createMDAGNode(SimpleMDAGNode current, int fromIndex, MDAGNode[] toNodeArray, MDAGNode[] fromNodeArray)
    {
        MDAGNode from = (fromIndex == -1 ? sourceNode : toNodeArray[fromIndex]);
        int transitionSetBegin = current.getTransitionSetBeginIndex();
        int onePastTransitionSetEnd = transitionSetBegin + current.getOutgoingTransitionSetSize();

        for (int i = transitionSetBegin; i < onePastTransitionSetEnd; i++)
        {
            SimpleMDAGNode targetNode = mdagDataArray[i];
            if (toNodeArray[i] != null)
            {
                fromNodeArray[fromIndex].addOutgoingTransition(current.getLetter(), fromNodeArray[i]);
                toNodeArray[fromIndex] = fromNodeArray[i];
                continue;
            }
            toNodeArray[i] = from.addOutgoingTransition(targetNode.getLetter(), targetNode.isAcceptNode());
            fromNodeArray[i] = from;
            createMDAGNode(targetNode, i, toNodeArray, fromNodeArray);
        }
    }
563746
def create(blocks, mode='basic', inplanes=64, cardinality=4, image_features=64, divisor=4, num_classes=1000):
    
    block_dict = {
        # 'basic': BasicBlock,
        'bottleneck': ResNeXtBottleneck
    }

    def instantiate(**_):
        return ResNeXt(block_dict[mode], blocks, inplanes=inplanes, image_features=image_features, cardinality=cardinality, divisor=divisor, num_classes=num_classes)

    return ModelFactory.generic(instantiate)
1150552
@Override public DRFModel createImpl() {
    DRFV3.DRFParametersV3 p = this.parameters;
    DRFModel.DRFParameters parms = p.createImpl();
    return new DRFModel( model_id.key(), parms, new DRFModel.DRFOutput(null) );
  }
93516
def initialize__(cls):
        
        [cls.new(level=r[0], name=r[1]) for r in cls.ROLES]
144192
def createNew(cls, store, pathSegments):
        
        if isinstance(pathSegments, basestring):
            raise ValueError(
                'Received %r instead of a sequence' % (pathSegments,))
        if store.dbdir is None:
            self = cls(store=store, storepath=None)
        else:
            storepath = store.newDirectory(*pathSegments)
            self = cls(store=store, storepath=storepath)
        self.open()
        self.close()
        return self
884929
protected JChord createNormalizedChord(MultiNote mNote, ScoreMetrics mtrx, Point2D base) {
		return new JChord(mNote, getClef(), mtrx, base);
	}
402017
private void buildReplacementNodesFromSource(MsgNode msg) {

    currReplacementNodes = Lists.newArrayList();

    for (StandaloneNode child : msg.getChildren()) {

      if (child instanceof RawTextNode) {
        currReplacementNodes.add(child);

      } else if (child instanceof MsgPlaceholderNode) {
        for (StandaloneNode contentNode : ((MsgPlaceholderNode) child).getChildren()) {
          // If the content node is a MsgHtmlTagNode, it needs to be replaced by a number of
          // consecutive siblings. This is done by visiting the MsgHtmlTagNode. Otherwise, we
          // simply add the content node to the currReplacementNodes list being built.
          if (contentNode instanceof MsgHtmlTagNode) {
            currReplacementNodes.addAll(((MsgHtmlTagNode) contentNode).getChildren());
          } else {
            currReplacementNodes.add(contentNode);
          }
        }

      } else {
        throw new AssertionError();
      }
    }
  }
421261
def create(cls):
        
        if cls not in cls._instances:
            cls._instances[cls] = cls()

        return cls._instances[cls]
454213
static Matcher create(Matcher... matchers) {
    switch (matchers.length) {
      case 0:  return TrueMatcher.INSTANCE;
      case 1:  return matchers[0];
      default: return new OrMatcher(matchers);
    }
  }
734823
public static MultiLineString of(Iterable<LineString> lineStrings) {
        AreaPositions.Builder positionsBuilder = AreaPositions.builder();
        for(LineString lineString : lineStrings) {
            positionsBuilder.addLinearPosition(lineString.positions());
        }
        return new MultiLineString(positionsBuilder.build());
    }
1118553
private void createJmsTemplate() {
        Assert.isTrue(this.connectionFactory != null,
                "Neither 'jmsTemplate' nor 'connectionFactory' is set correctly.");

        jmsTemplate = new JmsTemplate();

        jmsTemplate.setConnectionFactory(this.connectionFactory);

        if (this.destination != null) {
            jmsTemplate.setDefaultDestination(this.destination);
        } else if (this.destinationName != null) {
            jmsTemplate.setDefaultDestinationName(this.destinationName);
        }

        if (this.destinationResolver != null) {
            jmsTemplate.setDestinationResolver(this.destinationResolver);
        }

        jmsTemplate.setPubSubDomain(pubSubDomain);
    }
936517
private IModel<List<SiteUrl>> newListModel()
	{
		return new LoadableDetachableModel<List<SiteUrl>>()
		{

			private static final long serialVersionUID = 1L;

			@Override
			protected List<SiteUrl> load()
			{
				final List<SiteUrl> list = new ArrayList<>();

				for (final Class<? extends WebPage> type : getAllPageClasses())
				{
					String loc = PATTERN.matcher(AbstractSiteMapPage.this.urlFor(type, null))
						.replaceFirst(getBaseUrl());

					if (loc.endsWith("/."))
					{
						loc = loc.replace("/.", "");
					}

					list.add(new SiteUrl(loc));
				}

				return list;
			}
		};
	}
1043771
function _createMROFDisplayList(refresh) {
        var $def = $.Deferred();
        
        var $mrofList, $link, $newItem;

        /**
         * Clears the MROF list in memory and pop over but retains the working set entries
         * @private
         */
        function _purgeAllExceptWorkingSet() {
            _mrofList = _createMROFList();
            $mrofList.empty();
            _createMROFDisplayList(true);
            $currentContext = null;
            PreferencesManager.setViewState(OPEN_FILES_VIEW_STATE, _mrofList, _getPrefsContext(), true);
        }

        if (!refresh) {
            // Call hide first to make sure we are not creating duplicate lists
            _hideMROFList();
            $mrofContainer = $(Mustache.render(htmlTemplate, {Strings: Strings})).appendTo('body');
            $("#mrof-list-close").one("click", _hideMROFList);
            // Attach clear list handler to the 'Clear All' button
            $("#mrof-container .footer > div#clear-mrof-list").on("click", _purgeAllExceptWorkingSet);
            $(window).on("keydown", _handleArrowKeys);
            $(window).on("keyup", _hideMROFListOnEscape);
        }
        
        $mrofList = $mrofContainer.find("#mrof-list");
        
        /**
         * Focus handler for the link in list item 
         * @private
         */
        function _onFocus(event) {
            var $scope = $(event.target).parent();
            $("#mrof-container #mrof-list > li.highlight").removeClass("highlight");
            $(event.target).parent().addClass("highlight");
            $mrofContainer.find("#recent-file-path").text($scope.data("path"));
            $mrofContainer.find("#recent-file-path").attr('title', ($scope.data("path")));
            $currentContext = $scope;
        }
        
        /**
         * Click handler for the link in list item 
         * @private
         */
        function _onClick(event) {
            var $scope = $(event.delegateTarget).parent();
            _openEditorForContext({
                path: $scope.data("path"),
                paneId: $scope.data("paneId"),
                cursor: $scope.data("cursor"),
                hideOnOpenFile: true
            });
        }

        var data, fileEntry;
        
        _syncWithFileSystem().always(function () {
            _mrofList = _mrofList.filter(function (e) {return e; });
            _createFileEntries($mrofList);
            var $fileLinks = $("#mrof-container #mrof-list > li > a.mroitem");
            // Handlers for mouse events on the list items
            $fileLinks.on("focus", _onFocus);
            $fileLinks.on("click", _onClick);
            $fileLinks.on("select", _onClick);

            // Put focus on the Most recent file link in the list
            $fileLinks.first().trigger("focus");

            $def.resolve();
        });

        return $def.promise();
    }
381750
public static <T> IterableJsonDeserializer<T> newInstance( JsonDeserializer<T> deserializer ) {
        return new IterableJsonDeserializer<T>( deserializer );
    }
264575
def new(self, inlineparent = None):
        '''
        
        '''
        v = list(range(0, self.size))
        for i in range(0, self.size):
            v[i] = self.innerparser.new()
        return v