Creates a new content object.

@param string $name Name of the content
@return MW_Container_Content_Interface New content object
337369
public function create( $name )
	{
		$sheet = $this->_container->createSheet();
		$sheet->setTitle( $name );

		return new MW_Container_Content_PHPExcel( $sheet, $name, $this->_getOptions() );
	}
1094276
protected function create($name) {
    $c = $this->avaibleModules[$name]['class'];
    $module = new $c($this->project, $this->inTests);
    $module->setName($name);
    
    $this->modules[$name] = $module;
    
    PSC::getEventManager()->dispatchEvent('Psc.ModuleCreated', NULL, $module);
    
    return $module;
  }
632225
protected static function createFreshMockInstance($name)
    {
        static::$instance[$name] = $mock = static::createMockByName($name);

        if (isset(static::$container)) {
            static::$container->instance($name, $mock);
        }

        return $mock;
    }
961381
public static function createDocument( $name )
    {
        // Check if a document with the given name exists.
        if ( !isset( self::$documents[$name] ) )
        {
            throw new phpillowNoSuchPropertyException( $name );
        }

        // Instantiate and return document.
        $className = self::$documents[$name];
        return call_user_func( array( $className, 'createNew' ) );
    }
685139
public function getOrCreateSubject($name)
    {
        if (isset($this->subjects[$name])) {
            return $this->subjects[$name];
        }

        $this->subjects[$name] = new SubjectMetadata($this, $name);

        return $this->subjects[$name];
    }
415132
private function createTaxon($name)
    {
        /** @var TaxonInterface $taxon */
        $taxon = $this->taxonFactory->createNew();
        $taxon->setName($name);
        $taxon->setCode(StringInflector::nameToCode($name));
        $taxon->setSlug($this->taxonSlugGenerator->generate($taxon));

        return $taxon;
    }
1091520
public function loadOrCreateTag($name)
    {
        $tag = $this->loadTag($name);
        if (null === $tag) {
            $tag = $this->createTag($name);
        }

        return $tag;
    }
1193897
public function getContentMeta($name = null)
    {
        if ($name) {
            if (isset($this->content_meta[$name])) {
                return $this->content_meta[$name];
            }

            return null;
        }

        return $this->content_meta;
    }
333913
public function createPage($name)
    {
        $pageClass = $this->classNameResolver->resolvePage($name);

        return $this->instantiatePage($pageClass);
    }
331379
public static function fill($name)
    {
        $email = Content::find()->where(['name' => $name])->limit(1)->one();
        if (empty($email)) {
            $email = Content::prepareDefault($name);
        }
        return $email;
    }
437887
public function newTable(string $name){
            
            $status = file_put_contents($file = $this->base . '/' . $name . '.json', "[]");

            return new \NonDB\Components\Status($status);

        }
1241222
public function method($name)
    {
        $method = new Method($name);
        $this->container->put($name, $method);

        return $method;
    }
688125
public static function create($name, $content = '', $attribs = [], $forcePair = false)
    {
        $name = trim($name);

        $tag = '<' . $name;

        $tag .= static::buildAttributes($attribs);

        if ($content !== null) {
            $tag .= '>' . $content . '</' . $name . '>';
        } else {
            $tag .= $forcePair ? '></' . $name . '>' : ' />';
        }

        return $tag;
    }
245602
protected function createRole($name)
    {
        $role = RoleProxy::create(['name' => $name])->fresh();

        $role->givePermissionTo(ResourcePermissions::allPermissionsFor('user'));
        $role->givePermissionTo(ResourcePermissions::allPermissionsFor('role'));

        return $role;
    }
129144
public static function newInstance($name)
    {
        $bean       = \Mix\Core\Bean::config($name);
        $class      = $bean['class'];
        $properties = $bean['properties'] ?? [];
        return new $class($properties);
    }
611906
public static function createSub($name = '', $content = null)
	{
		$class = get_called_class();
		$element = new $class($name, $content);
		$element->sub = true;
		return $element;
	}
1330193
public function createMailbox(string $name): MailboxInterface
    {
        if (false === \imap_createmailbox($this->resource->getStream(), $this->server . \mb_convert_encoding($name, 'UTF7-IMAP', 'UTF-8'))) {
            throw new CreateMailboxException(\sprintf('Can not create "%s" mailbox at "%s"', $name, $this->server));
        }

        $this->mailboxNames = $this->mailboxes = null;
        $this->resource->clearLastMailboxUsedCache();

        return $this->getMailbox($name);
    }