# Class Thelia\Model\om\BaseProduct | thelia

# Class BaseProduct

Base class that represents a row from the 'product' table.

  BaseObject
  Thelia\Model\om\BaseProduct implements Persistent

#### Direct known subclasses

Thelia\Model\Product
Abstract
Namespace: Thelia\Model\om
Package: propel\generator\Thelia\Model\om
Located at core/lib/Thelia/Model/om/BaseProduct.php

Methods summary

`public`

# `applyDefaultValues( )`

Applies default values to this object. This method should be called from the object's constructor (or equivalent initialization method).

Applies default values to this object. This method should be called from the object's constructor (or equivalent initialization method).

#### See

``Thelia\Model\om\BaseProduct::__construct()``

`public`

# `__construct( )`

Initializes internal state of BaseProduct object.

Initializes internal state of BaseProduct object.

#### See

applyDefaults()

`public integer`

# `getId( )`

Get the [id] column value.

Get the [id] column value.

#### Returns

`integer`

`public integer`

# `getTaxRuleId( )`

Get the [tax_rule_id] column value.

Get the [tax_rule_id] column value.

#### Returns

`integer`

`public string`

# `getRef( )`

Get the [ref] column value.

Get the [ref] column value.

#### Returns

`string`

`public float`

# `getPrice( )`

Get the [price] column value.

Get the [price] column value.

#### Returns

`float`

`public float`

# `getPrice2( )`

Get the [price2] column value.

Get the [price2] column value.

#### Returns

`float`

`public float`

# `getEcotax( )`

Get the [ecotax] column value.

Get the [ecotax] column value.

#### Returns

`float`

`public integer`

# `getNewness( )`

Get the [newness] column value.

Get the [newness] column value.

#### Returns

`integer`

`public integer`

# `getPromo( )`

Get the [promo] column value.

Get the [promo] column value.

#### Returns

`integer`

`public integer`

# `getStock( )`

Get the [stock] column value.

Get the [stock] column value.

#### Returns

`integer`

`public integer`

# `getVisible( )`

Get the [visible] column value.

Get the [visible] column value.

#### Returns

`integer`

`public float`

# `getWeight( )`

Get the [weight] column value.

Get the [weight] column value.

#### Returns

`float`

`public integer`

# `getPosition( )`

Get the [position] column value.

Get the [position] column value.

#### Returns

`integer`

`public mixed`

# `getCreatedAt( string $format = 'Y-m-d H:i:s' )`

Get the [optionally formatted] temporal [created_at] column value.

Get the [optionally formatted] temporal [created_at] column value.

#### Parameters

$format
  `string`
  $format The date/time format string (either date()-style or strftime()-style). If format is null, then the raw DateTime object will be returned.

#### Returns

`mixed`
Formatted date/time value as string or DateTime object (if format is null), null if column is null, and 0 if column value is 0000-00-00 00:00:00

#### Throws

`PropelException`
- if unable to parse/validate the date/time value.

`public mixed`

# `getUpdatedAt( string $format = 'Y-m-d H:i:s' )`

Get the [optionally formatted] temporal [updated_at] column value.

Get the [optionally formatted] temporal [updated_at] column value.

#### Parameters

$format
  `string`
  $format The date/time format string (either date()-style or strftime()-style). If format is null, then the raw DateTime object will be returned.

#### Returns

`mixed`
Formatted date/time value as string or DateTime object (if format is null), null if column is null, and 0 if column value is 0000-00-00 00:00:00

#### Throws

`PropelException`
- if unable to parse/validate the date/time value.

`public integer`

# `getVersion( )`

Get the [version] column value.

Get the [version] column value.

#### Returns

`integer`

`public mixed`

# `getVersionCreatedAt( string $format = 'Y-m-d H:i:s' )`

Get the [optionally formatted] temporal [version_created_at] column value.

Get the [optionally formatted] temporal [version_created_at] column value.

#### Parameters

$format
  `string`
  $format The date/time format string (either date()-style or strftime()-style). If format is null, then the raw DateTime object will be returned.

#### Returns

`mixed`
Formatted date/time value as string or DateTime object (if format is null), null if column is null, and 0 if column value is 0000-00-00 00:00:00

#### Throws

`PropelException`
- if unable to parse/validate the date/time value.

`public string`

# `getVersionCreatedBy( )`

Get the [version_created_by] column value.

Get the [version_created_by] column value.

#### Returns

`string`

`public `Thelia\Model\Product``

# `setId( integer $v )`

Set the value of [id] column.

Set the value of [id] column.

#### Parameters

$v
  `integer`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setTaxRuleId( integer $v )`

Set the value of [tax_rule_id] column.

Set the value of [tax_rule_id] column.

#### Parameters

$v
  `integer`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setRef( string $v )`

Set the value of [ref] column.

Set the value of [ref] column.

#### Parameters

$v
  `string`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setPrice( float $v )`

Set the value of [price] column.

Set the value of [price] column.

#### Parameters

$v
  `float`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setPrice2( float $v )`

Set the value of [price2] column.

Set the value of [price2] column.

#### Parameters

$v
  `float`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setEcotax( float $v )`

Set the value of [ecotax] column.

Set the value of [ecotax] column.

#### Parameters

$v
  `float`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setNewness( integer $v )`

Set the value of [newness] column.

Set the value of [newness] column.

#### Parameters

$v
  `integer`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setPromo( integer $v )`

Set the value of [promo] column.

Set the value of [promo] column.

#### Parameters

$v
  `integer`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setStock( integer $v )`

Set the value of [stock] column.

Set the value of [stock] column.

#### Parameters

$v
  `integer`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setVisible( integer $v )`

Set the value of [visible] column.

Set the value of [visible] column.

#### Parameters

$v
  `integer`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setWeight( float $v )`

Set the value of [weight] column.

Set the value of [weight] column.

#### Parameters

$v
  `float`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setPosition( integer $v )`

Set the value of [position] column.

Set the value of [position] column.

#### Parameters

$v
  `integer`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setCreatedAt( mixed $v )`

Sets the value of [created_at] column to a normalized version of the date/time value specified.

Sets the value of [created_at] column to a normalized version of the date/time value specified.

#### Parameters

$v
  `mixed`
  $v string, integer (timestamp), or DateTime value. Empty strings are treated as null.

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setUpdatedAt( mixed $v )`

Sets the value of [updated_at] column to a normalized version of the date/time value specified.

Sets the value of [updated_at] column to a normalized version of the date/time value specified.

#### Parameters

$v
  `mixed`
  $v string, integer (timestamp), or DateTime value. Empty strings are treated as null.

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setVersion( integer $v )`

Set the value of [version] column.

Set the value of [version] column.

#### Parameters

$v
  `integer`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setVersionCreatedAt( mixed $v )`

Sets the value of [version_created_at] column to a normalized version of the date/time value specified.

Sets the value of [version_created_at] column to a normalized version of the date/time value specified.

#### Parameters

$v
  `mixed`
  $v string, integer (timestamp), or DateTime value. Empty strings are treated as null.

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setVersionCreatedBy( string $v )`

Set the value of [version_created_by] column.

Set the value of [version_created_by] column.

#### Parameters

$v
  `string`
  $v new value

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public boolean`

# `hasOnlyDefaultValues( )`

Indicates whether the columns in this object are only set to default values.

Indicates whether the columns in this object are only set to default values.

This method can be used in conjunction with isModified() to indicate whether an object is both modified _and_ has some values set which are non-default.

#### Returns

`boolean`
Whether the columns in this object are only been set with default values.

`public integer`

# `hydrate( array $row, integer $startcol = 0, boolean $rehydrate = false )`

Hydrates (populates) the object variables with values from the database resultset.

Hydrates (populates) the object variables with values from the database resultset.

An offset (0-based "start column") is specified so that objects can be hydrated with a subset of the columns in the resultset rows. This is needed, for example, for results of JOIN queries where the resultset row includes columns from two or more tables.

#### Parameters

$row
  `array`
  $row The row returned by PDOStatement->fetch(PDO::FETCH_NUM)
$startcol
  `integer`
  $startcol 0-based offset column which indicates which restultset column to start with.
$rehydrate
  `boolean`
  $rehydrate Whether this object is being re-hydrated from the database.

#### Returns

`integer`
next starting column

#### Throws

`PropelException`
- Any caught Exception will be rewrapped as a PropelException.

`public`

# `ensureConsistency( )`

Checks and repairs the internal consistency of the object.

Checks and repairs the internal consistency of the object.

This method is executed after an already-instantiated object is re-hydrated from the database. It exists to check any foreign keys to make sure that the objects related to the current object are correct based on foreign key.

You can override this method in the stub class, but you should always invoke the base method from the overridden method (i.e. parent::ensureConsistency()), in case your model changes.

#### Throws

`PropelException`

`public`

# `reload( boolean $deep = false, PropelPDO $con = null )`

Reloads this object from datastore based on primary key and (optionally) resets all associated objects.

Reloads this object from datastore based on primary key and (optionally) resets all associated objects.

This will only work if the object has been saved and has a valid primary key set.

#### Parameters

$deep
  `boolean`
  $deep (optional) Whether to also de-associated any related objects.
$con
  `PropelPDO`
  $con (optional) The PropelPDO connection to use.

#### Throws

`PropelException`
- if this object is deleted, unsaved or doesn't have pk match in db

`public`

# `delete( PropelPDO $con = null )`

Removes this object from datastore and sets delete attribute.

Removes this object from datastore and sets delete attribute.

#### Parameters

$con
  `PropelPDO`
  $con

#### Throws

`PropelException`
``Exception``

#### See

BaseObject::setDeleted()
BaseObject::isDeleted()

`public integer`

# `save( PropelPDO $con = null )`

Persists this object to the database.

Persists this object to the database.

If the object is new, it inserts it; otherwise an update is performed. All modified related objects will also be persisted in the doSave() method. This method wraps all precipitate database operations in a single transaction.

#### Parameters

$con
  `PropelPDO`
  $con

#### Returns

`integer`
The number of rows affected by this insert/update and any referring fk objects' save() operations.

#### Throws

`PropelException`
``Exception``

#### See

``Thelia\Model\om\BaseProduct::doSave()``

`protected integer`

# `doSave( PropelPDO $con )`

Performs the work of inserting or updating the row in the database.

Performs the work of inserting or updating the row in the database.

If the object is new, it inserts it; otherwise an update is performed. All related objects are also updated in this method.

#### Parameters

$con
  `PropelPDO`
  $con

#### Returns

`integer`
The number of rows affected by this insert/update and any referring fk objects' save() operations.

#### Throws

`PropelException`

#### See

``Thelia\Model\om\BaseProduct::save()``

`protected`

# `doInsert( PropelPDO $con )`

Insert the row in the database.

Insert the row in the database.

#### Parameters

$con
  `PropelPDO`
  $con

#### Throws

`PropelException`

#### See

``Thelia\Model\om\BaseProduct::doSave()``

`protected`

# `doUpdate( PropelPDO $con )`

Update the row in the database.

Update the row in the database.

#### Parameters

$con
  `PropelPDO`
  $con

#### See

``Thelia\Model\om\BaseProduct::doSave()``

`public array`

# `getValidationFailures( )`

Gets any ValidationFailed objects that resulted from last call to validate().

Gets any ValidationFailed objects that resulted from last call to validate().

#### Returns

`array`
ValidationFailed[]

#### See

``Thelia\Model\om\BaseProduct::validate()``

`public boolean`

# `validate( mixed $columns = null )`

Validates the objects modified field values and all objects related to this table.

Validates the objects modified field values and all objects related to this table.

If $columns is either a column name or an array of column names only those columns are validated.

#### Parameters

$columns
  `mixed`
  $columns Column name or an array of column names.

#### Returns

`boolean`
Whether all columns pass validation.

#### See

``Thelia\Model\om\BaseProduct::doValidate()``
``Thelia\Model\om\BaseProduct::getValidationFailures()``

`protected mixed`

# `doValidate( array $columns = null )`

This function performs the validation work for complex object models.

This function performs the validation work for complex object models.

In addition to checking the current object, all related objects will also be validated. If all pass then `<span class="php-keyword1">true</span>` is returned; otherwise an aggreagated array of ValidationFailed objects will be returned.

#### Parameters

$columns
  `array`
  $columns Array of column names to validate.

#### Returns

`mixed`
`<span class="php-keyword1">true</span>` if all validations pass; array of `ValidationFailed` objets otherwise.

`public mixed`

# `getByName( string $name, string $type = Thelia\Model\om\BasePeer::TYPE_PHPNAME )`

Retrieves a field from the object by name passed in as a string.

Retrieves a field from the object by name passed in as a string.

#### Parameters

$name
  `string`
  $name name
$type
  `string`
  $type The type of fieldname the $name is of: one of the class type constants BasePeer::TYPE_PHPNAME, BasePeer::TYPE_STUDLYPHPNAME BasePeer::TYPE_COLNAME, BasePeer::TYPE_FIELDNAME, BasePeer::TYPE_NUM. Defaults to BasePeer::TYPE_PHPNAME

#### Returns

`mixed`
Value of field.

`public mixed`

# `getByPosition( integer $pos )`

Retrieves a field from the object by Position as specified in the xml schema. Zero-based.

Retrieves a field from the object by Position as specified in the xml schema. Zero-based.

#### Parameters

$pos
  `integer`
  $pos position in xml schema

#### Returns

`mixed`
Value of field at $pos

`public array`

# `toArray( string $keyType = Thelia\Model\om\BasePeer::TYPE_PHPNAME, boolean $includeLazyLoadColumns = true, array $alreadyDumpedObjects = array(), boolean $includeForeignObjects = false )`

Exports the object as an array.

Exports the object as an array.

You can specify the key type of the array by passing one of the class type constants.

#### Parameters

$keyType
  `string`
  $keyType (optional) One of the class type constants BasePeer::TYPE_PHPNAME, BasePeer::TYPE_STUDLYPHPNAME, BasePeer::TYPE_COLNAME, BasePeer::TYPE_FIELDNAME, BasePeer::TYPE_NUM. Defaults to BasePeer::TYPE_PHPNAME.
$includeLazyLoadColumns
  `boolean`
  $includeLazyLoadColumns (optional) Whether to include lazy loaded columns. Defaults to true.
$alreadyDumpedObjects
  `array`
  $alreadyDumpedObjects List of objects to skip to avoid recursion
$includeForeignObjects
  `boolean`
  $includeForeignObjects (optional) Whether to include hydrated related objects. Default to FALSE.

#### Returns

`array`
an associative array containing the field names (as keys) and field values

`public`

# `setByName( string $name, mixed $value, string $type = Thelia\Model\om\BasePeer::TYPE_PHPNAME )`

Sets a field from the object by name passed in as a string.

Sets a field from the object by name passed in as a string.

#### Parameters

$name
  `string`
  $name peer name
$value
  `mixed`
  $value field value
$type
  `string`
  $type The type of fieldname the $name is of: one of the class type constants BasePeer::TYPE_PHPNAME, BasePeer::TYPE_STUDLYPHPNAME BasePeer::TYPE_COLNAME, BasePeer::TYPE_FIELDNAME, BasePeer::TYPE_NUM. Defaults to BasePeer::TYPE_PHPNAME

`public`

# `setByPosition( integer $pos, mixed $value )`

Sets a field from the object by Position as specified in the xml schema. Zero-based.

Sets a field from the object by Position as specified in the xml schema. Zero-based.

#### Parameters

$pos
  `integer`
  $pos position in xml schema
$value
  `mixed`
  $value field value

`public`

# `fromArray( array $arr, string $keyType = Thelia\Model\om\BasePeer::TYPE_PHPNAME )`

Populates the object using an array.

Populates the object using an array.

This is particularly useful when populating an object from one of the request arrays (e.g. $_POST). This method goes through the column names, checking to see whether a matching key exists in populated array. If so the setByName() method is called for that column.

You can specify the key type of the array by additionally passing one of the class type constants BasePeer::TYPE_PHPNAME, BasePeer::TYPE_STUDLYPHPNAME, BasePeer::TYPE_COLNAME, BasePeer::TYPE_FIELDNAME, BasePeer::TYPE_NUM. The default key type is the column's BasePeer::TYPE_PHPNAME

#### Parameters

$arr
  `array`
  $arr An array to populate the object from.
$keyType
  `string`
  $keyType The type of keys the array uses.

`public Criteria`

# `buildCriteria( )`

Build a Criteria object containing the values of all modified columns in this object.

Build a Criteria object containing the values of all modified columns in this object.

#### Returns

`Criteria`
The Criteria object containing all modified values.

`public Criteria`

# `buildPkeyCriteria( )`

Builds a Criteria object containing the primary key for this object.

Builds a Criteria object containing the primary key for this object.

Unlike buildCriteria() this method includes the primary key values regardless of whether or not they have been modified.

#### Returns

`Criteria`
The Criteria object containing value(s) for primary key(s).

`public integer`

# `getPrimaryKey( )`

Returns the primary key for this object (row).

Returns the primary key for this object (row).

#### Returns

`integer`

`public`

# `setPrimaryKey( integer $key )`

Generic method to set the primary key (id column).

Generic method to set the primary key (id column).

#### Parameters

$key
  `integer`
  $key Primary key.

`public boolean`

# `isPrimaryKeyNull( )`

Returns true if the primary key for this object is null.

Returns true if the primary key for this object is null.

#### Returns

`boolean`

`public`

# `copyInto( object $copyObj, boolean $deepCopy = false, boolean $makeNew = true )`

Sets contents of passed object to values from current object.

Sets contents of passed object to values from current object.

If desired, this method can also make copies of all associated (fkey referrers) objects.

#### Parameters

$copyObj
  `object`
  $copyObj An object of Product (or compatible) type.
$deepCopy
  `boolean`
  $deepCopy Whether to also copy all rows that refer (by fkey) to the current row.
$makeNew
  `boolean`
  $makeNew Whether to reset autoincrement PKs and make the object new.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `copy( boolean $deepCopy = false )`

Makes a copy of this object that will be inserted as a new row in table when saved. It creates a new object filling in the simple attributes, but skipping any primary keys that are defined for the table.

Makes a copy of this object that will be inserted as a new row in table when saved. It creates a new object filling in the simple attributes, but skipping any primary keys that are defined for the table.

If desired, this method can also make copies of all associated (fkey referrers) objects.

#### Parameters

$deepCopy
  `boolean`
  $deepCopy Whether to also copy all rows that refer (by fkey) to the current row.

#### Returns

``Thelia\Model\Product``
Clone of current object.

#### Throws

`PropelException`

`public `Thelia\Model\ProductPeer``

# `getPeer( )`

Returns a peer instance associated with this om.

Returns a peer instance associated with this om.

Since Peer classes are not to have any instance attributes, this method returns the same instance for all member of this class. The method could therefore be static, but this would prevent one from overriding the behavior.

#### Returns

``Thelia\Model\ProductPeer``

`public `Thelia\Model\Product``

# `setTaxRule( `Thelia\Model\TaxRule` $v = null )`

Declares an association between this object and a TaxRule object.

Declares an association between this object and a TaxRule object.

#### Parameters

$v
  ``Thelia\Model\TaxRule``
  $v

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

#### Throws

`PropelException`

`public `Thelia\Model\TaxRule``

# `getTaxRule( PropelPDO $con = null )`

Get the associated TaxRule object

Get the associated TaxRule object

#### Parameters

$con
  `PropelPDO`
  $con Optional Connection object.

#### Returns

``Thelia\Model\TaxRule``
The associated TaxRule object.

#### Throws

`PropelException`

`public`

# `initRelation( string $relationName )`

Initializes a collection based on the name of a relation. Avoids crafting an 'init[$relationName]s' method name that wouldn't work when StandardEnglishPluralizer is used.

Initializes a collection based on the name of a relation. Avoids crafting an 'init[$relationName]s' method name that wouldn't work when StandardEnglishPluralizer is used.

#### Parameters

$relationName
  `string`
  $relationName The name of the relation to initialize

`public`

# `clearProductCategorys( )`

Clears out the collProductCategorys collection

Clears out the collProductCategorys collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addProductCategorys()

`public` | # `resetPartialProductCategorys( mixed $v = true )` reset is the collProductCategorys collection loaded partially reset is the collProductCategorys collection loaded partially

`public`

# `initProductCategorys( boolean $overrideExisting = true )`

Initializes the collProductCategorys collection.

Initializes the collProductCategorys collection.

By default this just sets the collProductCategorys collection to an empty array (like clearcollProductCategorys()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\ProductCategory[]``

# `getProductCategorys( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of ProductCategory objects which contain a foreign key that references this object.

Gets an array of ProductCategory objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\ProductCategory[]``
List of ProductCategory objects

#### Throws

`PropelException`

`public`

# `setProductCategorys( PropelCollection $productCategorys, PropelPDO $con = null )`

Sets a collection of ProductCategory objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of ProductCategory objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$productCategorys
  `PropelCollection`
  $productCategorys A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countProductCategorys( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related ProductCategory objects.

Returns the number of related ProductCategory objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related ProductCategory objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addProductCategory( `Thelia\Model\ProductCategory` $l )`

Method called to associate a ProductCategory object to this object through the ProductCategory foreign key attribute.

Method called to associate a ProductCategory object to this object through the ProductCategory foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\ProductCategory``
  $l ProductCategory

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddProductCategory( `Thelia\Model\ProductCategory` $productCategory )`

#### Parameters

$productCategory
  ``Thelia\Model\ProductCategory``
  $productCategory The productCategory object to add.

`public`

# `removeProductCategory( `Thelia\Model\ProductCategory` $productCategory )`

#### Parameters

$productCategory
  ``Thelia\Model\ProductCategory``
  $productCategory The productCategory object to remove.

`public PropelObjectCollection|`Thelia\Model\ProductCategory[]``

# `getProductCategorysJoinCategory( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related ProductCategorys from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related ProductCategorys from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\ProductCategory[]``
List of ProductCategory objects

`public`

# `clearFeatureProds( )`

Clears out the collFeatureProds collection

Clears out the collFeatureProds collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addFeatureProds()

`public` | # `resetPartialFeatureProds( mixed $v = true )` reset is the collFeatureProds collection loaded partially reset is the collFeatureProds collection loaded partially

`public`

# `initFeatureProds( boolean $overrideExisting = true )`

Initializes the collFeatureProds collection.

Initializes the collFeatureProds collection.

By default this just sets the collFeatureProds collection to an empty array (like clearcollFeatureProds()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\FeatureProd[]``

# `getFeatureProds( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of FeatureProd objects which contain a foreign key that references this object.

Gets an array of FeatureProd objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\FeatureProd[]``
List of FeatureProd objects

#### Throws

`PropelException`

`public`

# `setFeatureProds( PropelCollection $featureProds, PropelPDO $con = null )`

Sets a collection of FeatureProd objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of FeatureProd objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$featureProds
  `PropelCollection`
  $featureProds A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countFeatureProds( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related FeatureProd objects.

Returns the number of related FeatureProd objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related FeatureProd objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addFeatureProd( `Thelia\Model\FeatureProd` $l )`

Method called to associate a FeatureProd object to this object through the FeatureProd foreign key attribute.

Method called to associate a FeatureProd object to this object through the FeatureProd foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\FeatureProd``
  $l FeatureProd

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddFeatureProd( `Thelia\Model\FeatureProd` $featureProd )`

#### Parameters

$featureProd
  ``Thelia\Model\FeatureProd``
  $featureProd The featureProd object to add.

`public`

# `removeFeatureProd( `Thelia\Model\FeatureProd` $featureProd )`

#### Parameters

$featureProd
  ``Thelia\Model\FeatureProd``
  $featureProd The featureProd object to remove.

`public PropelObjectCollection|`Thelia\Model\FeatureProd[]``

# `getFeatureProdsJoinFeature( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related FeatureProds from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related FeatureProds from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\FeatureProd[]``
List of FeatureProd objects

`public PropelObjectCollection|`Thelia\Model\FeatureProd[]``

# `getFeatureProdsJoinFeatureAv( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related FeatureProds from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related FeatureProds from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\FeatureProd[]``
List of FeatureProd objects

`public`

# `clearStocks( )`

Clears out the collStocks collection

Clears out the collStocks collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addStocks()

`public` | # `resetPartialStocks( mixed $v = true )` reset is the collStocks collection loaded partially reset is the collStocks collection loaded partially

`public`

# `initStocks( boolean $overrideExisting = true )`

Initializes the collStocks collection.

Initializes the collStocks collection.

By default this just sets the collStocks collection to an empty array (like clearcollStocks()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\Stock[]``

# `getStocks( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of Stock objects which contain a foreign key that references this object.

Gets an array of Stock objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\Stock[]``
List of Stock objects

#### Throws

`PropelException`

`public`

# `setStocks( PropelCollection $stocks, PropelPDO $con = null )`

Sets a collection of Stock objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of Stock objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$stocks
  `PropelCollection`
  $stocks A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countStocks( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related Stock objects.

Returns the number of related Stock objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related Stock objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addStock( `Thelia\Model\Stock` $l )`

Method called to associate a Stock object to this object through the Stock foreign key attribute.

Method called to associate a Stock object to this object through the Stock foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\Stock``
  $l Stock

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddStock( `Thelia\Model\Stock` $stock )`

#### Parameters

$stock
  ``Thelia\Model\Stock``
  $stock The stock object to add.

`public`

# `removeStock( `Thelia\Model\Stock` $stock )`

#### Parameters

$stock
  ``Thelia\Model\Stock``
  $stock The stock object to remove.

`public PropelObjectCollection|`Thelia\Model\Stock[]``

# `getStocksJoinCombination( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Stocks from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Stocks from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\Stock[]``
List of Stock objects

`public`

# `clearContentAssocs( )`

Clears out the collContentAssocs collection

Clears out the collContentAssocs collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addContentAssocs()

`public` | # `resetPartialContentAssocs( mixed $v = true )` reset is the collContentAssocs collection loaded partially reset is the collContentAssocs collection loaded partially

`public`

# `initContentAssocs( boolean $overrideExisting = true )`

Initializes the collContentAssocs collection.

Initializes the collContentAssocs collection.

By default this just sets the collContentAssocs collection to an empty array (like clearcollContentAssocs()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\ContentAssoc[]``

# `getContentAssocs( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of ContentAssoc objects which contain a foreign key that references this object.

Gets an array of ContentAssoc objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\ContentAssoc[]``
List of ContentAssoc objects

#### Throws

`PropelException`

`public`

# `setContentAssocs( PropelCollection $contentAssocs, PropelPDO $con = null )`

Sets a collection of ContentAssoc objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of ContentAssoc objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$contentAssocs
  `PropelCollection`
  $contentAssocs A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countContentAssocs( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related ContentAssoc objects.

Returns the number of related ContentAssoc objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related ContentAssoc objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addContentAssoc( `Thelia\Model\ContentAssoc` $l )`

Method called to associate a ContentAssoc object to this object through the ContentAssoc foreign key attribute.

Method called to associate a ContentAssoc object to this object through the ContentAssoc foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\ContentAssoc``
  $l ContentAssoc

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddContentAssoc( `Thelia\Model\ContentAssoc` $contentAssoc )`

#### Parameters

$contentAssoc
  ``Thelia\Model\ContentAssoc``
  $contentAssoc The contentAssoc object to add.

`public`

# `removeContentAssoc( `Thelia\Model\ContentAssoc` $contentAssoc )`

#### Parameters

$contentAssoc
  ``Thelia\Model\ContentAssoc``
  $contentAssoc The contentAssoc object to remove.

`public PropelObjectCollection|`Thelia\Model\ContentAssoc[]``

# `getContentAssocsJoinCategory( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related ContentAssocs from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related ContentAssocs from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\ContentAssoc[]``
List of ContentAssoc objects

`public PropelObjectCollection|`Thelia\Model\ContentAssoc[]``

# `getContentAssocsJoinContent( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related ContentAssocs from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related ContentAssocs from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\ContentAssoc[]``
List of ContentAssoc objects

`public`

# `clearImages( )`

Clears out the collImages collection

Clears out the collImages collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addImages()

`public` | # `resetPartialImages( mixed $v = true )` reset is the collImages collection loaded partially reset is the collImages collection loaded partially

`public`

# `initImages( boolean $overrideExisting = true )`

Initializes the collImages collection.

Initializes the collImages collection.

By default this just sets the collImages collection to an empty array (like clearcollImages()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\Image[]``

# `getImages( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of Image objects which contain a foreign key that references this object.

Gets an array of Image objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\Image[]``
List of Image objects

#### Throws

`PropelException`

`public`

# `setImages( PropelCollection $images, PropelPDO $con = null )`

Sets a collection of Image objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of Image objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$images
  `PropelCollection`
  $images A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countImages( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related Image objects.

Returns the number of related Image objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related Image objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addImage( `Thelia\Model\Image` $l )`

Method called to associate a Image object to this object through the Image foreign key attribute.

Method called to associate a Image object to this object through the Image foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\Image``
  $l Image

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddImage( `Thelia\Model\Image` $image )`

#### Parameters

$image
  ``Thelia\Model\Image``
  $image The image object to add.

`public`

# `removeImage( `Thelia\Model\Image` $image )`

#### Parameters

$image
  ``Thelia\Model\Image``
  $image The image object to remove.

`public PropelObjectCollection|`Thelia\Model\Image[]``

# `getImagesJoinCategory( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Images from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Images from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\Image[]``
List of Image objects

`public PropelObjectCollection|`Thelia\Model\Image[]``

# `getImagesJoinContent( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Images from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Images from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\Image[]``
List of Image objects

`public PropelObjectCollection|`Thelia\Model\Image[]``

# `getImagesJoinFolder( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Images from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Images from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\Image[]``
List of Image objects

`public`

# `clearDocuments( )`

Clears out the collDocuments collection

Clears out the collDocuments collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addDocuments()

`public` | # `resetPartialDocuments( mixed $v = true )` reset is the collDocuments collection loaded partially reset is the collDocuments collection loaded partially

`public`

# `initDocuments( boolean $overrideExisting = true )`

Initializes the collDocuments collection.

Initializes the collDocuments collection.

By default this just sets the collDocuments collection to an empty array (like clearcollDocuments()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\Document[]``

# `getDocuments( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of Document objects which contain a foreign key that references this object.

Gets an array of Document objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\Document[]``
List of Document objects

#### Throws

`PropelException`

`public`

# `setDocuments( PropelCollection $documents, PropelPDO $con = null )`

Sets a collection of Document objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of Document objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$documents
  `PropelCollection`
  $documents A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countDocuments( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related Document objects.

Returns the number of related Document objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related Document objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addDocument( `Thelia\Model\Document` $l )`

Method called to associate a Document object to this object through the Document foreign key attribute.

Method called to associate a Document object to this object through the Document foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\Document``
  $l Document

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddDocument( `Thelia\Model\Document` $document )`

#### Parameters

$document
  ``Thelia\Model\Document``
  $document The document object to add.

`public`

# `removeDocument( `Thelia\Model\Document` $document )`

#### Parameters

$document
  ``Thelia\Model\Document``
  $document The document object to remove.

`public PropelObjectCollection|`Thelia\Model\Document[]``

# `getDocumentsJoinCategory( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Documents from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Documents from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\Document[]``
List of Document objects

`public PropelObjectCollection|`Thelia\Model\Document[]``

# `getDocumentsJoinContent( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Documents from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Documents from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\Document[]``
List of Document objects

`public PropelObjectCollection|`Thelia\Model\Document[]``

# `getDocumentsJoinFolder( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Documents from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Documents from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\Document[]``
List of Document objects

`public`

# `clearAccessorysRelatedByProductId( )`

Clears out the collAccessorysRelatedByProductId collection

Clears out the collAccessorysRelatedByProductId collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addAccessorysRelatedByProductId()

`public` | # `resetPartialAccessorysRelatedByProductId( mixed $v = true )` reset is the collAccessorysRelatedByProductId collection loaded partially reset is the collAccessorysRelatedByProductId collection loaded partially

`public`

# `initAccessorysRelatedByProductId( boolean $overrideExisting = true )`

Initializes the collAccessorysRelatedByProductId collection.

Initializes the collAccessorysRelatedByProductId collection.

By default this just sets the collAccessorysRelatedByProductId collection to an empty array (like clearcollAccessorysRelatedByProductId()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\Accessory[]``

# `getAccessorysRelatedByProductId( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of Accessory objects which contain a foreign key that references this object.

Gets an array of Accessory objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\Accessory[]``
List of Accessory objects

#### Throws

`PropelException`

`public`

# `setAccessorysRelatedByProductId( PropelCollection $accessorysRelatedByProductId, PropelPDO $con = null )`

Sets a collection of AccessoryRelatedByProductId objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of AccessoryRelatedByProductId objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$accessorysRelatedByProductId
  `PropelCollection`
  $accessorysRelatedByProductId A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countAccessorysRelatedByProductId( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related Accessory objects.

Returns the number of related Accessory objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related Accessory objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addAccessoryRelatedByProductId( `Thelia\Model\Accessory` $l )`

Method called to associate a Accessory object to this object through the Accessory foreign key attribute.

Method called to associate a Accessory object to this object through the Accessory foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\Accessory``
  $l Accessory

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddAccessoryRelatedByProductId( AccessoryRelatedByProductId $accessoryRelatedByProductId )`

#### Parameters

$accessoryRelatedByProductId
  `AccessoryRelatedByProductId`
  $accessoryRelatedByProductId The accessoryRelatedByProductId object to add.

`public`

# `removeAccessoryRelatedByProductId( AccessoryRelatedByProductId $accessoryRelatedByProductId )`

#### Parameters

$accessoryRelatedByProductId
  `AccessoryRelatedByProductId`
  $accessoryRelatedByProductId The accessoryRelatedByProductId object to remove.

`public`

# `clearAccessorysRelatedByAccessory( )`

Clears out the collAccessorysRelatedByAccessory collection

Clears out the collAccessorysRelatedByAccessory collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addAccessorysRelatedByAccessory()

`public` | # `resetPartialAccessorysRelatedByAccessory( mixed $v = true )` reset is the collAccessorysRelatedByAccessory collection loaded partially reset is the collAccessorysRelatedByAccessory collection loaded partially

`public`

# `initAccessorysRelatedByAccessory( boolean $overrideExisting = true )`

Initializes the collAccessorysRelatedByAccessory collection.

Initializes the collAccessorysRelatedByAccessory collection.

By default this just sets the collAccessorysRelatedByAccessory collection to an empty array (like clearcollAccessorysRelatedByAccessory()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\Accessory[]``

# `getAccessorysRelatedByAccessory( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of Accessory objects which contain a foreign key that references this object.

Gets an array of Accessory objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\Accessory[]``
List of Accessory objects

#### Throws

`PropelException`

`public`

# `setAccessorysRelatedByAccessory( PropelCollection $accessorysRelatedByAccessory, PropelPDO $con = null )`

Sets a collection of AccessoryRelatedByAccessory objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of AccessoryRelatedByAccessory objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$accessorysRelatedByAccessory
  `PropelCollection`
  $accessorysRelatedByAccessory A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countAccessorysRelatedByAccessory( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related Accessory objects.

Returns the number of related Accessory objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related Accessory objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addAccessoryRelatedByAccessory( `Thelia\Model\Accessory` $l )`

Method called to associate a Accessory object to this object through the Accessory foreign key attribute.

Method called to associate a Accessory object to this object through the Accessory foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\Accessory``
  $l Accessory

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddAccessoryRelatedByAccessory( AccessoryRelatedByAccessory $accessoryRelatedByAccessory )`

#### Parameters

$accessoryRelatedByAccessory
  `AccessoryRelatedByAccessory`
  $accessoryRelatedByAccessory The accessoryRelatedByAccessory object to add.

`public`

# `removeAccessoryRelatedByAccessory( AccessoryRelatedByAccessory $accessoryRelatedByAccessory )`

#### Parameters

$accessoryRelatedByAccessory
  `AccessoryRelatedByAccessory`
  $accessoryRelatedByAccessory The accessoryRelatedByAccessory object to remove.

`public`

# `clearRewritings( )`

Clears out the collRewritings collection

Clears out the collRewritings collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addRewritings()

`public` | # `resetPartialRewritings( mixed $v = true )` reset is the collRewritings collection loaded partially reset is the collRewritings collection loaded partially

`public`

# `initRewritings( boolean $overrideExisting = true )`

Initializes the collRewritings collection.

Initializes the collRewritings collection.

By default this just sets the collRewritings collection to an empty array (like clearcollRewritings()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\Rewriting[]``

# `getRewritings( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of Rewriting objects which contain a foreign key that references this object.

Gets an array of Rewriting objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\Rewriting[]``
List of Rewriting objects

#### Throws

`PropelException`

`public`

# `setRewritings( PropelCollection $rewritings, PropelPDO $con = null )`

Sets a collection of Rewriting objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of Rewriting objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$rewritings
  `PropelCollection`
  $rewritings A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countRewritings( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related Rewriting objects.

Returns the number of related Rewriting objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related Rewriting objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addRewriting( `Thelia\Model\Rewriting` $l )`

Method called to associate a Rewriting object to this object through the Rewriting foreign key attribute.

Method called to associate a Rewriting object to this object through the Rewriting foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\Rewriting``
  $l Rewriting

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddRewriting( `Thelia\Model\Rewriting` $rewriting )`

#### Parameters

$rewriting
  ``Thelia\Model\Rewriting``
  $rewriting The rewriting object to add.

`public`

# `removeRewriting( `Thelia\Model\Rewriting` $rewriting )`

#### Parameters

$rewriting
  ``Thelia\Model\Rewriting``
  $rewriting The rewriting object to remove.

`public PropelObjectCollection|`Thelia\Model\Rewriting[]``

# `getRewritingsJoinCategory( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Rewritings from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Rewritings from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\Rewriting[]``
List of Rewriting objects

`public PropelObjectCollection|`Thelia\Model\Rewriting[]``

# `getRewritingsJoinFolder( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Rewritings from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Rewritings from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\Rewriting[]``
List of Rewriting objects

`public PropelObjectCollection|`Thelia\Model\Rewriting[]``

# `getRewritingsJoinContent( Criteria $criteria = null, PropelPDO $con = null, string $join_behavior = Thelia\Model\om\Criteria::LEFT_JOIN )`

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Rewritings from storage.

If this collection has already been initialized with an identical criteria, it returns the collection. Otherwise if this Product is new, it will return an empty collection; or if this Product has previously been saved, it will retrieve related Rewritings from storage.

This method is protected by default in order to keep the public api reasonable. You can provide public methods for those you actually need in Product.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object
$join_behavior
  `string`
  $join_behavior optional join type to use (defaults to Criteria::LEFT_JOIN)

#### Returns

`PropelObjectCollection|`Thelia\Model\Rewriting[]``
List of Rewriting objects

`public`

# `clearProductI18ns( )`

Clears out the collProductI18ns collection

Clears out the collProductI18ns collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addProductI18ns()

`public` | # `resetPartialProductI18ns( mixed $v = true )` reset is the collProductI18ns collection loaded partially reset is the collProductI18ns collection loaded partially

`public`

# `initProductI18ns( boolean $overrideExisting = true )`

Initializes the collProductI18ns collection.

Initializes the collProductI18ns collection.

By default this just sets the collProductI18ns collection to an empty array (like clearcollProductI18ns()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\ProductI18n[]``

# `getProductI18ns( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of ProductI18n objects which contain a foreign key that references this object.

Gets an array of ProductI18n objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\ProductI18n[]``
List of ProductI18n objects

#### Throws

`PropelException`

`public`

# `setProductI18ns( PropelCollection $productI18ns, PropelPDO $con = null )`

Sets a collection of ProductI18n objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of ProductI18n objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$productI18ns
  `PropelCollection`
  $productI18ns A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countProductI18ns( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related ProductI18n objects.

Returns the number of related ProductI18n objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related ProductI18n objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addProductI18n( `Thelia\Model\ProductI18n` $l )`

Method called to associate a ProductI18n object to this object through the ProductI18n foreign key attribute.

Method called to associate a ProductI18n object to this object through the ProductI18n foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\ProductI18n``
  $l ProductI18n

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddProductI18n( `Thelia\Model\ProductI18n` $productI18n )`

#### Parameters

$productI18n
  ``Thelia\Model\ProductI18n``
  $productI18n The productI18n object to add.

`public`

# `removeProductI18n( `Thelia\Model\ProductI18n` $productI18n )`

#### Parameters

$productI18n
  ``Thelia\Model\ProductI18n``
  $productI18n The productI18n object to remove.

`public`

# `clearProductVersions( )`

Clears out the collProductVersions collection

Clears out the collProductVersions collection

This does not modify the database; however, it will remove any associated objects, causing them to be refetched by subsequent calls to accessor method.

#### See

addProductVersions()

`public` | # `resetPartialProductVersions( mixed $v = true )` reset is the collProductVersions collection loaded partially reset is the collProductVersions collection loaded partially

`public`

# `initProductVersions( boolean $overrideExisting = true )`

Initializes the collProductVersions collection.

Initializes the collProductVersions collection.

By default this just sets the collProductVersions collection to an empty array (like clearcollProductVersions()); however, you may wish to override this method in your stub class to provide setting appropriate to your application -- for example, setting the initial array to the values stored in database.

#### Parameters

$overrideExisting
  `boolean`
  $overrideExisting If set to true, the method call initializes the collection even if it is not empty

`public PropelObjectCollection|`Thelia\Model\ProductVersion[]``

# `getProductVersions( Criteria $criteria = null, PropelPDO $con = null )`

Gets an array of ProductVersion objects which contain a foreign key that references this object.

Gets an array of ProductVersion objects which contain a foreign key that references this object.

If the $criteria is not null, it is used to always fetch the results from the database. Otherwise the results are fetched from the database the first time, then cached. Next time the same method is called without $criteria, the cached collection is returned. If this Product is new, it will return an empty collection or the current collection; the criteria is ignored on a new object.

#### Parameters

$criteria
  `Criteria`
  $criteria optional Criteria object to narrow the query
$con
  `PropelPDO`
  $con optional connection object

#### Returns

`PropelObjectCollection|`Thelia\Model\ProductVersion[]``
List of ProductVersion objects

#### Throws

`PropelException`

`public`

# `setProductVersions( PropelCollection $productVersions, PropelPDO $con = null )`

Sets a collection of ProductVersion objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

Sets a collection of ProductVersion objects related by a one-to-many relationship to the current object. It will also schedule objects for deletion based on a diff between old objects (aka persisted) and new objects from the given Propel collection.

#### Parameters

$productVersions
  `PropelCollection`
  $productVersions A Propel collection.
$con
  `PropelPDO`
  $con Optional connection object

`public integer`

# `countProductVersions( Criteria $criteria = null, boolean $distinct = false, PropelPDO $con = null )`

Returns the number of related ProductVersion objects.

Returns the number of related ProductVersion objects.

#### Parameters

$criteria
  `Criteria`
  $criteria
$distinct
  `boolean`
  $distinct
$con
  `PropelPDO`
  $con

#### Returns

`integer`
Count of related ProductVersion objects.

#### Throws

`PropelException`

`public `Thelia\Model\Product``

# `addProductVersion( `Thelia\Model\ProductVersion` $l )`

Method called to associate a ProductVersion object to this object through the ProductVersion foreign key attribute.

Method called to associate a ProductVersion object to this object through the ProductVersion foreign key attribute.

#### Parameters

$l
  ``Thelia\Model\ProductVersion``
  $l ProductVersion

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`protected`

# `doAddProductVersion( `Thelia\Model\ProductVersion` $productVersion )`

#### Parameters

$productVersion
  ``Thelia\Model\ProductVersion``
  $productVersion The productVersion object to add.

`public`

# `removeProductVersion( `Thelia\Model\ProductVersion` $productVersion )`

#### Parameters

$productVersion
  ``Thelia\Model\ProductVersion``
  $productVersion The productVersion object to remove.

`public` | # `clear( )` Clears the current object and sets all attributes to their default values Clears the current object and sets all attributes to their default values

`public`

# `clearAllReferences( boolean $deep = false )`

Resets all references to other model objects or collections of model objects.

Resets all references to other model objects or collections of model objects.

This method is a user-space workaround for PHP's inability to garbage collect objects with circular references (even in PHP 5.3). This is currently necessary when using Propel in certain daemon or large-volumne/high-memory operations.

#### Parameters

$deep
  `boolean`
  $deep Whether to also clear the references on all referrer objects.

`public string`

# `__toString( )`

return the string representation of this object

return the string representation of this object

#### Returns

`string`

`public boolean`

# `isAlreadyInSave( )`

return true is the object is in saving state

return true is the object is in saving state

#### Returns

`boolean`

`public `Thelia\Model\Product``

# `keepUpdateDateUnchanged( )`

Mark the current object so that the update date doesn't get updated during next save

Mark the current object so that the update date doesn't get updated during next save

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `setLocale( string $locale = 'en_EN' )`

Sets the locale for translations

Sets the locale for translations

#### Parameters

$locale
  `string`
  $locale Locale to use for the translation, e.g. 'fr_FR'

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public string`

# `getLocale( )`

Gets the locale for translations

Gets the locale for translations

#### Returns

`string`
$locale Locale to use for the translation, e.g. 'fr_FR'

`public `Thelia\Model\ProductI18n``

# `getTranslation( string $locale = 'en_EN', PropelPDO $con = null )`

Returns the current translation for a given locale

Returns the current translation for a given locale

#### Parameters

$locale
  `string`
  $locale Locale to use for the translation, e.g. 'fr_FR'
$con
  `PropelPDO`
  $con an optional connection object

#### Returns

``Thelia\Model\ProductI18n``

`public `Thelia\Model\Product``

# `removeTranslation( string $locale = 'en_EN', PropelPDO $con = null )`

Remove the translation for a given locale

Remove the translation for a given locale

#### Parameters

$locale
  `string`
  $locale Locale to use for the translation, e.g. 'fr_FR'
$con
  `PropelPDO`
  $con an optional connection object

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public `Thelia\Model\ProductI18n``

# `getCurrentTranslation( PropelPDO $con = null )`

Returns the current translation

Returns the current translation

#### Parameters

$con
  `PropelPDO`
  $con an optional connection object

#### Returns

``Thelia\Model\ProductI18n``

`public string`

# `getTitle( )`

Get the [title] column value.

Get the [title] column value.

#### Returns

`string`

`public `Thelia\Model\ProductI18n``

# `setTitle( string $v )`

Set the value of [title] column.

Set the value of [title] column.

#### Parameters

$v
  `string`
  $v new value

#### Returns

``Thelia\Model\ProductI18n``
The current object (for fluent API support)

`public string`

# `getDescription( )`

Get the [description] column value.

Get the [description] column value.

#### Returns

`string`

`public `Thelia\Model\ProductI18n``

# `setDescription( string $v )`

Set the value of [description] column.

Set the value of [description] column.

#### Parameters

$v
  `string`
  $v new value

#### Returns

``Thelia\Model\ProductI18n``
The current object (for fluent API support)

`public string`

# `getChapo( )`

Get the [chapo] column value.

Get the [chapo] column value.

#### Returns

`string`

`public `Thelia\Model\ProductI18n``

# `setChapo( string $v )`

Set the value of [chapo] column.

Set the value of [chapo] column.

#### Parameters

$v
  `string`
  $v new value

#### Returns

``Thelia\Model\ProductI18n``
The current object (for fluent API support)

`public string`

# `getPostscriptum( )`

Get the [postscriptum] column value.

Get the [postscriptum] column value.

#### Returns

`string`

`public `Thelia\Model\ProductI18n``

# `setPostscriptum( string $v )`

Set the value of [postscriptum] column.

Set the value of [postscriptum] column.

#### Parameters

$v
  `string`
  $v new value

#### Returns

``Thelia\Model\ProductI18n``
The current object (for fluent API support)

`public `Thelia\Model\Product``

# `enforceVersioning( )`

Enforce a new Version of this object upon next save.

Enforce a new Version of this object upon next save.

#### Returns

``Thelia\Model\Product``

`public boolean`

# `isVersioningNecessary( PropelPDO $con = null )`

Checks whether the current state must be recorded as a version

Checks whether the current state must be recorded as a version

#### Parameters

$con
  `PropelPDO`
  $con An optional PropelPDO connection to use.

#### Returns

`boolean`

`public `Thelia\Model\ProductVersion``

# `addVersion( PropelPDO $con = null )`

Creates a version of the current object and saves it.

Creates a version of the current object and saves it.

#### Parameters

$con
  `PropelPDO`
  $con the connection to use

#### Returns

``Thelia\Model\ProductVersion``
A version object

`public `Thelia\Model\Product``

# `toVersion( integer $versionNumber, PropelPDO $con = null )`

Sets the properties of the curent object to the value they had at a specific version

Sets the properties of the curent object to the value they had at a specific version

#### Parameters

$versionNumber
  `integer`
  $versionNumber The version number to read
$con
  `PropelPDO`
  $con the connection to use

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

#### Throws

`PropelException`
- if no object with the given version can be found.

`public `Thelia\Model\Product``

# `populateFromVersion( `Thelia\Model\ProductVersion` $version, PropelPDO $con = null, array & $loadedObjects = array() )`

Sets the properties of the curent object to the value they had at a specific version

Sets the properties of the curent object to the value they had at a specific version

#### Parameters

$version
  ``Thelia\Model\ProductVersion``
  $version The version object to use
$con
  `PropelPDO`
  $con the connection to use
$loadedObjects
  `array`
  $loadedObjects objects thats been loaded in a chain of populateFromVersion calls on referrer or fk objects.

#### Returns

``Thelia\Model\Product``
The current object (for fluent API support)

`public integer`

# `getLastVersionNumber( PropelPDO $con = null )`

Gets the latest persisted version number for the current object

Gets the latest persisted version number for the current object

#### Parameters

$con
  `PropelPDO`
  $con the connection to use

#### Returns

`integer`

`public boolean`

# `isLastVersion( PropelPDO $con = null )`

Checks whether the current object is the latest one

Checks whether the current object is the latest one

#### Parameters

$con
  `PropelPDO`
  $con the connection to use

#### Returns

`boolean`

`public `Thelia\Model\ProductVersion``

# `getOneVersion( integer $versionNumber, PropelPDO $con = null )`

Retrieves a version object for this entity and a version number

Retrieves a version object for this entity and a version number

#### Parameters

$versionNumber
  `integer`
  $versionNumber The version number to read
$con
  `PropelPDO`
  $con the connection to use

#### Returns

``Thelia\Model\ProductVersion``
A version object

`public PropelObjectCollection`

# `getAllVersions( PropelPDO $con = null )`

Gets all the versions of this object, in incremental order

Gets all the versions of this object, in incremental order

#### Parameters

$con
  `PropelPDO`
  $con the connection to use

#### Returns

`PropelObjectCollection`
A list of ProductVersion objects

`public array`

# `compareVersion( integer $versionNumber, string $keys = 'columns', PropelPDO $con = null, array $ignoredColumns = array() )`

Compares the current object with another of its version.

    print_r($book->compareVersion(1));
    => array(
      '1' => array('Title' => 'Book title at version 1'),
      '2' => array('Title' => 'Book title at version 2')
    );

Compares the current object with another of its version.

    print_r($book->compareVersion(1));
    => array(
      '1' => array('Title' => 'Book title at version 1'),
      '2' => array('Title' => 'Book title at version 2')
    );

#### Parameters

$versionNumber
  `integer`
  $versionNumber
$keys
  `string`
  $keys Main key used for the result diff (versions|columns)
$con
  `PropelPDO`
  $con the connection to use
$ignoredColumns
  `array`
  $ignoredColumns The columns to exclude from the diff.

#### Returns

`array`
A list of differences

`public array`

# `compareVersions( integer $fromVersionNumber, integer $toVersionNumber, string $keys = 'columns', PropelPDO $con = null, array $ignoredColumns = array() )`

Compares two versions of the current object.

    print_r($book->compareVersions(1, 2));
    => array(
      '1' => array('Title' => 'Book title at version 1'),
      '2' => array('Title' => 'Book title at version 2')
    );

Compares two versions of the current object.

    print_r($book->compareVersions(1, 2));
    => array(
      '1' => array('Title' => 'Book title at version 1'),
      '2' => array('Title' => 'Book title at version 2')
    );

#### Parameters

$fromVersionNumber
  `integer`
  $fromVersionNumber
$toVersionNumber
  `integer`
  $toVersionNumber
$keys
  `string`
  $keys Main key used for the result diff (versions|columns)
$con
  `PropelPDO`
  $con the connection to use
$ignoredColumns
  `array`
  $ignoredColumns The columns to exclude from the diff.

#### Returns

`array`
A list of differences

`protected array`

# `computeDiff( array $fromVersion, array $toVersion, string $keys = 'columns', array $ignoredColumns = array() )`

Computes the diff between two versions.

    print_r($this->computeDiff(1, 2));
    => array(
      '1' => array('Title' => 'Book title at version 1'),
      '2' => array('Title' => 'Book title at version 2')
    );

Computes the diff between two versions.

    print_r($this->computeDiff(1, 2));
    => array(
      '1' => array('Title' => 'Book title at version 1'),
      '2' => array('Title' => 'Book title at version 2')
    );

#### Parameters

$fromVersion
  `array`
  $fromVersion An array representing the original version.
$toVersion
  `array`
  $toVersion An array representing the destination version.
$keys
  `string`
  $keys Main key used for the result diff (versions|columns).
$ignoredColumns
  `array`
  $ignoredColumns The columns to exclude from the diff.

#### Returns

`array`
A list of differences

`public PropelCollection|`Thelia\Model\ProductVersion[]``

# `getLastVersions( integer $number = 10, `Thelia\Model\ProductVersionQuery`|Criteria $criteria = null, PropelPDO $con = null )`

retrieve the last $number versions.

retrieve the last $number versions.

#### Parameters

$number
  `integer`
  $number the number of record to return.
$criteria
  ``Thelia\Model\ProductVersionQuery`|Criteria`
  $criteria Additional criteria to filter.
$con
  `PropelPDO`
  $con An optional connection to use.

#### Returns

`PropelCollection|`Thelia\Model\ProductVersion[]``
List of ProductVersion objects

Constants summary
`string` | `PEER` | `'Thelia\\Model\\ProductPeer'` | # Peer class name Peer class name

Properties summary
`protected static `Thelia\Model\ProductPeer`` | $peer | `` | # The Peer class. Instance provides a convenient way of calling static methods on a class that calling code may not be able to identify. The Peer class. Instance provides a convenient way of calling static methods on a class that calling code may not be able to identify.
`protected boolean` | $startCopy | `false` | # The flag var to prevent infinit loop in deep copy The flag var to prevent infinit loop in deep copy
`protected integer` | $id | `` | # The value for the id field. The value for the id field.
`protected integer` | $tax_rule_id | `` | # The value for the tax_rule_id field. The value for the tax_rule_id field.
`protected string` | $ref | `` | # The value for the ref field. The value for the ref field.
`protected float` | $price | `` | # The value for the price field. The value for the price field.
`protected float` | $price2 | `` | # The value for the price2 field. The value for the price2 field.
`protected float` | $ecotax | `` | # The value for the ecotax field. The value for the ecotax field.
`protected integer` | $newness | `` | # The value for the newness field. Note: this column has a database default value of: 0 The value for the newness field. Note: this column has a database default value of: 0
`protected integer` | $promo | `` | # The value for the promo field. Note: this column has a database default value of: 0 The value for the promo field. Note: this column has a database default value of: 0
`protected integer` | $stock | `` | # The value for the stock field. Note: this column has a database default value of: 0 The value for the stock field. Note: this column has a database default value of: 0
`protected integer` | $visible | `` | # The value for the visible field. Note: this column has a database default value of: 0 The value for the visible field. Note: this column has a database default value of: 0
`protected float` | $weight | `` | # The value for the weight field. The value for the weight field.
`protected integer` | $position | `` | # The value for the position field. The value for the position field.
`protected string` | $created_at | `` | # The value for the created_at field. The value for the created_at field.
`protected string` | $updated_at | `` | # The value for the updated_at field. The value for the updated_at field.
`protected integer` | $version | `` | # The value for the version field. Note: this column has a database default value of: 0 The value for the version field. Note: this column has a database default value of: 0
`protected string` | $version_created_at | `` | # The value for the version_created_at field. The value for the version_created_at field.
`protected string` | $version_created_by | `` | # The value for the version_created_by field. The value for the version_created_by field.
`protected `Thelia\Model\TaxRule`` | $aTaxRule | `` | #
`protected PropelObjectCollection|`Thelia\Model\ProductCategory[]`` | $collProductCategorys | `` | # Collection to store aggregation of ProductCategory objects. Collection to store aggregation of ProductCategory objects.
`protected mixed` | $collProductCategorysPartial | `` | #
`protected PropelObjectCollection|`Thelia\Model\FeatureProd[]`` | $collFeatureProds | `` | # Collection to store aggregation of FeatureProd objects. Collection to store aggregation of FeatureProd objects.
`protected mixed` | $collFeatureProdsPartial | `` | #
`protected PropelObjectCollection|`Thelia\Model\Stock[]`` | $collStocks | `` | # Collection to store aggregation of Stock objects. Collection to store aggregation of Stock objects.
`protected mixed` | $collStocksPartial | `` | #
`protected PropelObjectCollection|`Thelia\Model\ContentAssoc[]`` | $collContentAssocs | `` | # Collection to store aggregation of ContentAssoc objects. Collection to store aggregation of ContentAssoc objects.
`protected mixed` | $collContentAssocsPartial | `` | #
`protected PropelObjectCollection|`Thelia\Model\Image[]`` | $collImages | `` | # Collection to store aggregation of Image objects. Collection to store aggregation of Image objects.
`protected mixed` | $collImagesPartial | `` | #
`protected PropelObjectCollection|`Thelia\Model\Document[]`` | $collDocuments | `` | # Collection to store aggregation of Document objects. Collection to store aggregation of Document objects.
`protected mixed` | $collDocumentsPartial | `` | #
`protected PropelObjectCollection|`Thelia\Model\Accessory[]`` | $collAccessorysRelatedByProductId | `` | # Collection to store aggregation of Accessory objects. Collection to store aggregation of Accessory objects.
`protected mixed` | $collAccessorysRelatedByProductIdPartial | `` | #
`protected PropelObjectCollection|`Thelia\Model\Accessory[]`` | $collAccessorysRelatedByAccessory | `` | # Collection to store aggregation of Accessory objects. Collection to store aggregation of Accessory objects.
`protected mixed` | $collAccessorysRelatedByAccessoryPartial | `` | #
`protected PropelObjectCollection|`Thelia\Model\Rewriting[]`` | $collRewritings | `` | # Collection to store aggregation of Rewriting objects. Collection to store aggregation of Rewriting objects.
`protected mixed` | $collRewritingsPartial | `` | #
`protected PropelObjectCollection|`Thelia\Model\ProductI18n[]`` | $collProductI18ns | `` | # Collection to store aggregation of ProductI18n objects. Collection to store aggregation of ProductI18n objects.
`protected mixed` | $collProductI18nsPartial | `` | #
`protected PropelObjectCollection|`Thelia\Model\ProductVersion[]`` | $collProductVersions | `` | # Collection to store aggregation of ProductVersion objects. Collection to store aggregation of ProductVersion objects.
`protected mixed` | $collProductVersionsPartial | `` | #
`protected boolean` | $alreadyInSave | `false` | # Flag to prevent endless save loop, if this object is referenced by another object which falls in this transaction. Flag to prevent endless save loop, if this object is referenced by another object which falls in this transaction.
`protected boolean` | $alreadyInValidation | `false` | # Flag to prevent endless validation loop, if this object is referenced by another object which falls in this transaction. Flag to prevent endless validation loop, if this object is referenced by another object which falls in this transaction.
`protected string` | $currentLocale | `'en_EN'` | # Current locale Current locale
`protected array[ProductI18n]` | $currentTranslations | `` | # Current translation objects Current translation objects
`protected boolean` | $enforceVersion | `false` | #
`protected PropelObjectCollection` | $productCategorysScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected PropelObjectCollection` | $featureProdsScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected PropelObjectCollection` | $stocksScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected PropelObjectCollection` | $contentAssocsScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected PropelObjectCollection` | $imagesScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected PropelObjectCollection` | $documentsScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected PropelObjectCollection` | $accessorysRelatedByProductIdScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected PropelObjectCollection` | $accessorysRelatedByAccessoryScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected PropelObjectCollection` | $rewritingsScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected PropelObjectCollection` | $productI18nsScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected PropelObjectCollection` | $productVersionsScheduledForDeletion | `null` | # An array of objects scheduled for deletion. An array of objects scheduled for deletion.
`protected array` | $validationFailures | `array()` | # Array of ValidationFailed objects. Array of ValidationFailed objects.