Given some data, creates a PaymillMethod object

@param array $data Data

@return PaymillMethod PaymillMethod instance
777306
private function createPaymillMethod(array $data)
    {
        $paymentMethod = new PaymillMethod();
        $paymentMethod
            ->setApiToken($data['api_token'])
            ->setCreditCardNumber($data['credit_card_1'] . $data['credit_card_2'] . $data['credit_card_3'] . $data['credit_card_4'])
            ->setCreditCardOwner($data['credit_card_owner'])
            ->setCreditCardExpirationMonth($data['credit_card_expiration_month'])
            ->setCreditCardExpirationYear($data['credit_card_expiration_year'])
            ->setCreditCardSecurity($data['credit_card_security']);

        return $paymentMethod;
    }
552260
public static function createFromData(array $data): self
    {
        if (!isset($data['method'])) {
            throw new DomainException(self::REQUIRED_METHOD);
        }

        switch ($data['method']) {
            case self::METHOD_ACCOUNT_WEIGHTS:
                $instruction = new AccountWeights($data);

                break;
            case self::METHOD_ACQUIRER_WEIGHTS:
                $instruction = new AcquirerWeights($data);

                break;
            default:
                throw new DomainException(
                    sprintf(self::UNEXPECTED_METHOD, implode(', ', self::methods()))
                );
        }

        return $instruction;
    }
364108
public static function CreateFromResponse(array $data)
    {
        if (array_key_exists("data", $data) && is_array($data["data"]))
        {
            $data = $data["data"];
        }

        $object_field = new self($data["alias"], $data["type"], $data["options"], $data["required"], $data["unique"]);
        if ($data["field"])
        {
            $object_field->setField($data["field"]);
        }
        if ($data["id"])
        {
            $object_field->setId($data["id"]);
        }
        return $object_field;
    }
644506
static function createFromData($data) {
        $instance = new static();

        $instance->day = $data[0];
        $instance->hour = $data[1];
        $instance->numberCommits = $data[2];

        return $instance;
    }
154425
public function create(array $data)
  {
    $AccountType = new AccountType();
    $AccountType->setConnection($this->databaseConnectionName);
    $AccountType->fill($data)->save();

    return $AccountType;
  }
899015
public function create($data)
    {
        $methodDescriptor = new MethodDescriptor();
        $methodDescriptor->setNamespace(
            substr(
                (string) $data->getFqsen(),
                0,
                -strlen($data->getName()) - 4
            )
        );
        $this->mapReflectorToDescriptor($data, $methodDescriptor);

        $this->assembleDocBlock($data->getDocBlock(), $methodDescriptor);
        $this->addArguments($data, $methodDescriptor);
        $this->addVariadicArgument($data, $methodDescriptor);

        return $methodDescriptor;
    }
1303142
function factory(array $data) {
        $presence = new \CharlotteDunois\Yasmin\Models\Presence($this->client, $data);
        $this->set($presence->userID, $presence);
        return $presence;
    }
1280634
public function create($data)
    {
        $descriptor = new MethodDescriptor($data->getName());
        $descriptor->setDescription($data->getDescription());
        $descriptor->setMethodName($data->getMethodName());

        $response = new ReturnDescriptor('return');
        $response->setTypes($this->builder->buildDescriptor(new Collection($data->getTypes())));
        $descriptor->setResponse($response);

        foreach ($data->getArguments() as $argument) {
            $argumentDescriptor = $this->createArgumentDescriptorForMagicMethod($argument);
            $descriptor->getArguments()->set($argumentDescriptor->getName(), $argumentDescriptor);
        }

        return $descriptor;
    }
625770
static public function create(array $data = null)
    {
        if (empty($data["type"]) && isset($data["transaction"])) {
            $type = $data["transaction"]["type"];
        }
        elseif (! $data || empty($data["type"])) {
            return new static($data);
        }
        else {
            $type = $data["type"];
        }

        // valid transaction type input
        $validTypes = array_keys(self::$typesClassMap);
        if (! $type || ! in_array($type, $validTypes)) {
            $type = TransactionType::TRANSFER;
        }

        // mutate transaction (morph specialized class)
        $classTx = self::$typesClassMap[$type];

        if ($type === TransactionType::TRANSFER
            && in_array($data["version"], [self::VERSION_2, self::VERSION_2_TEST, self::VERSION_2_MIJIN])) {

            $classTx = "\\NEM\\Models\\Transaction\\MosaicTransfer";
        }

        return new $classTx($data);
    }
370419
public function create(array $data = [])
    {
        $engine = $this->scopeConfig->getValue($this->configPath, ScopeInterface::SCOPE_STORE);

        $fullActionClass = $this->fullActionPool['default'];

        if (isset($this->fullActionPool[$engine])) {
            $fullActionClass = $this->fullActionPool[$engine];
        }

        return $this->objectManager->create($fullActionClass, ['data' => $data]);
    }
1155489
public static function newPayReturn($data)
	{
		$order = new PayReturn;
		$order->order_id = $data['order_id'];
		$order->sum = $data['sum'];
		$order->comment = isset($data['comment']) ? $data['comment'] : '';
		$order->status = Order::C_RETURN_STATUS_ON_RETURN;
		$order->save();

		return $order;
	}
420200
public static function create($data)
    {
        if ($data instanceof self) {
            return $data;
        }

        if (\is_array($data)) {
            return self::_createFromArray($data);
        }

        if (\is_string($data)) {
            $class = self::class === \get_called_class() ? Script::class : \get_called_class();

            return new $class($data);
        }

        throw new InvalidException('Failed to create script. Invalid data passed.');
    }
967383
public function create(array $data)
    {
        if (array_key_exists('password', $data)) {
            $data['password'] = bcrypt($data['password']);
        }

        return parent::create($data);
    }
845427
public function create(array $data) : Model
    {
        $model_class = $this->getModelName();
        return $this->postCreate($data, $model_class::create($this->preCreate($this->parseData($data))));
    }
460187
public function createFromImportedData($data)
    {
        $group = new Group($data['name'], $data['include_pattern'], $data['exclude_pattern']);
        if (isset($data['type'])) {
            $group->setType($data['type']);
        }
        $group->setOrdering($data['ordering']);
        foreach ($data['classes'] as $className => $classData) {
            $group->addClass($this->getGroupClassFactory()->createFromImportedData($className, $classData));
        }
        return $group;
    }
1372091
public function createPayment($data, $filters = [])
    {
        return $this->client->orderPayments->createFor($this, $data, $filters);
    }
1125366
public static function fromData(array $data)
    {
        $reflection = new \ReflectionClass(static::class);
        $instance = $reflection->newInstanceWithoutConstructor();
        $instance->data = $data;
        $instance->jsonUnserialize($data);
        return $instance;
    }