Inititalize data

@param  string | array $property
@return Collection
353474
public function initialize($property = null) {
		if (! isset($this->_map[0])) {
			return $this;
		}
		
		$key  = $this->_map[0];
		$item = &$this->_data[$key];
		
		if (isset($item[$property])) {
			return $this;
		}
		
		$this->getItem($key)->initialize($property);
		
		return $this;
	}
1115454
public function populate(array $data) {
        foreach ($data as $property => $value) {
            $property = \Util::_toCamel($property);
            $method = 'set' . ucfirst($property);
            if (method_exists($this, $method)) {
                $this->$method($value);
            }
            elseif (property_exists($this, $property)) {
                $this->$property = $value;
            }
        }

        return $this;
    }
85047
public static function init($object, array $options)
    {
        foreach ($options as $property => $value) {
            if (is_numeric($property)) {
                continue;
            }

            $setter = 'set' . ucfirst($property);

            // has setter
            if (method_exists($object, $setter)) {
                $object->$setter($value);
            } else {
                $object->$property = $value;
            }
        }

        return $object;
    }
1112209
public function load($properties)
    {
        $keys = $this->_entity->getIdentifyingData();

        $this->_entity->getRepository()->getCommandChain()->disable();

        $query = $this->_entity->getRepository()->getQuery()
                    ->columns($properties)
                    ->where($keys);

        $data = $this->_entity->getRepository()->fetch($query, AnDomain::FETCH_ROW);

        if (!empty($data)) {
            $this->_row = array_merge($this->_row, (array) $data);

            foreach ($properties as $property) {
                unset($this->_materialized[$property]);
            }
        }

        $this->_entity->getRepository()->getCommandChain()->enable();

        return !empty($data);
    }
778478
public function setProperties(array $properties = [])
    {
        foreach ($properties as $property => $value) {
            $method = 'set'.ucfirst($property);
            if (!method_exists($this, $method)) {
                throw new \RuntimeException("Undefined method $method.");
            }

            if (!in_array($property, $this->validProperties)) {
                throw new \Exception('You are trying to set invalid properties. Please check valid properties.');
            }

            $this->{$method}($value);
        }
    }
1282387
public function add($property)
    {
        $iri    = IriFactory::create($property);
        $values = (is_object($property) && isset($property->values)) ? (array)$property->values : [];

        // Create the property values list if necessary
        if (!$this->offsetExists($iri)) {
            $this->offsetSet($iri, $values);

            return;
        }

        $propertyValues =& $this->offsetGet($iri);
        $propertyValues = array_merge($propertyValues, $values);
    }
748349
public function initialize(array $properties = null)
    {
        $attributes = [];
        $embedOne = [];
        $embedMany = [];

        if (null !== $properties) {
            $attributes = $this->applyDefaultAttrValues($attributes);
            foreach ($properties as $key => $value) {
                if (true === $this->isAttribute($key)) {
                    // Load attribute.
                    $attributes[$key] = $this->convertAttributeValue($key, $value);
                } else if (true === $this->isEmbedHasOne($key) && is_array($value)) {
                    // Load embed one.
                    $embedOne[$key] = $this->getStore()->loadEmbed($this->getMetadata()->getEmbed($key)->embedMeta, $value);
                }
            }
        }

        foreach ($this->getMetadata()->getEmbeds() as $key => $embeddedPropMeta) {
            // Always load embedded collections, regardless if data is set.
            if (true === $embeddedPropMeta->isOne()) {
                continue;
            }
            $embeds = !isset($properties[$key]) ? [] : $properties[$key];
            $embedMany[$key] = $this->getStore()->createEmbedCollection($embeddedPropMeta, $embeds);
        }

        $this->attributes    = (null === $this->attributes) ? new Attributes($attributes) : $this->attributes->replace($attributes);
        $this->hasOneEmbeds  = (null === $this->hasOneEmbeds) ? new Embeds\HasOne($embedOne) : $this->hasOneEmbeds->replace($embedOne);
        $this->hasManyEmbeds = (null === $this->hasManyEmbeds) ? new Embeds\HasMany($embedMany) : $this->hasManyEmbeds->replace($embedMany);

        if (true === $this->getState()->is('new')) {
            // Ensure default values are applied to new models.
            $this->apply([]);
        }

        $this->doDirtyCheck();
        return $this;
    }
329312
public function set($property, $value = null)
    {
        if (is_array($property)) {
            foreach ($property as $k => $v) {
                $this->set($k, $v);
            }

            return $this;
        }

        if ($this->has($property)) {
            $method = 'set' . Str::studly($property);
            $value  = $this->sanitizeSetterValue($method, $value);

            $this->message->{$method}($value);
        }

        return $this;
    }
534359
public function group($property)
    {
        $list = [];

        /** @var ObjectInterface $element */
        foreach ($this->getIterator() as $element) {
            $list[(string) $element->getProperty($property)][] = $element;
        }

        return $list;
    }
700230
public function setFieldsPropertyValues($property,$values){
		$i=0;
		if(\is_array($values)===false){
			$values=\array_fill(0, $this->count(),$values);
		}
		foreach ($values as $value){
			$c=$this->content[$i++];
			if(isset($c)){
				$df=$c->getDataField();
				$df->setProperty($property,$value);
			}
			else{
				return $this;
			}
		}
		return $this;
	}
381582
public function data(array $properties = null)
    {
        $data = [];
        $properties = $this->properties($properties);
        foreach ($properties as $propertyIdent => $property) {
            // Ensure objects are properly encoded.
            $val = $this->propertyValue($propertyIdent);
            $val = $this->serializedValue($val);
            $data[$propertyIdent] = $val;
        }

        return $data;
    }
18029
public function getKeyedByProperty($property)
    {
        $results = [];
        foreach ($this as $item) {
            $results[$item->$property] = $item;
        }
        return new static($results);
    }
864767
public function setPredefindProperties(array $properties)
    {
        foreach ($this->predefinedKeyMapping as $key => $property) {
            if (Helpers::isKeyExists($properties, $key)) {
                if (is_array($property)) {
                    foreach ($property as $name) {
                        $this->{$name} = $properties[$key];
                    }
                } else {
                    $this->{$property} = $properties[$key];
                }
            }
        }

        return $this;
    }
600694
public function setUnsigned(array $properties)
    {
        $this->isUnsigned = (Helpers::isKeyExists($properties, 'is-unsigned') && $properties['is-unsigned'])
        || in_array($this->getEloquentDataMethod(), $this->unsignedTypes);

        return $this;
    }
758363
public function setClean($property = null)
    {
        if ($property === null) {
            $this->_dirty = [];
        } else {
            unset($this->_dirty[$property]);
        }

        return $this;
    }
649072
public function createMany(array $records, array $properties = array())
    {
        $instances = new Collection;

        foreach ($records as $record)
        {
            $instances->push($this->create($record, $properties));
        }

        return $instances;
    }
494361
public function collectionGroup($property)
    {
        $collections = [];
        foreach ($this->group($property) as $id => $elements) {
            $collection = $this->createFrom($elements);

            $collections[$id] = $collection;
        }

        return $collections;
    }