Adds the cp definition grouped entry to the database. Also notifies the appropriate model listeners.

@param cpDefinitionGroupedEntry the cp definition grouped entry
@return the cp definition grouped entry that was added
332992
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CPDefinitionGroupedEntry addCPDefinitionGroupedEntry(
		CPDefinitionGroupedEntry cpDefinitionGroupedEntry) {
		cpDefinitionGroupedEntry.setNew(true);

		return cpDefinitionGroupedEntryPersistence.update(cpDefinitionGroupedEntry);
	}
953862
public static com.liferay.commerce.model.CPDefinitionInventory deleteCPDefinitionInventory(
		com.liferay.commerce.model.CPDefinitionInventory cpDefinitionInventory) {
		return getService().deleteCPDefinitionInventory(cpDefinitionInventory);
	}
1203368
@Override
	public List<CPDefinitionSpecificationOptionValue> findByGroupId(
		long groupId) {
		return findByGroupId(groupId, QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}
870673
@Override
	public List<CPDefinition> findAll() {
		return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}
5525
@Override
	public void cacheResult(
		List<CPDefinitionGroupedEntry> cpDefinitionGroupedEntries) {
		for (CPDefinitionGroupedEntry cpDefinitionGroupedEntry : cpDefinitionGroupedEntries) {
			if (entityCache.getResult(
						CPDefinitionGroupedEntryModelImpl.ENTITY_CACHE_ENABLED,
						CPDefinitionGroupedEntryImpl.class,
						cpDefinitionGroupedEntry.getPrimaryKey()) == null) {
				cacheResult(cpDefinitionGroupedEntry);
			}
			else {
				cpDefinitionGroupedEntry.resetOriginalValues();
			}
		}
	}
92870
@Indexable(type = IndexableType.DELETE)
	@Override
	public CPDefinitionGroupedEntry deleteCPDefinitionGroupedEntry(
		CPDefinitionGroupedEntry cpDefinitionGroupedEntry) {
		return cpDefinitionGroupedEntryPersistence.remove(cpDefinitionGroupedEntry);
	}
924513
def AddMemberDefinition(self, member_definition):
    
    self.members.append(member_definition)
    member_definition.family_definition = self
213306
@Override
	public void cacheResult(CPDefinitionLocalization cpDefinitionLocalization) {
		entityCache.putResult(CPDefinitionLocalizationModelImpl.ENTITY_CACHE_ENABLED,
			CPDefinitionLocalizationImpl.class,
			cpDefinitionLocalization.getPrimaryKey(), cpDefinitionLocalization);

		finderCache.putResult(FINDER_PATH_FETCH_BY_CPDEFINITIONID_LANGUAGEID,
			new Object[] {
				cpDefinitionLocalization.getCPDefinitionId(),
				cpDefinitionLocalization.getLanguageId()
			}, cpDefinitionLocalization);

		cpDefinitionLocalization.resetOriginalValues();
	}
1309992
@Override
	public void clearCache() {
		entityCache.clearCache(CPDefinitionGroupedEntryImpl.class);

		finderCache.clearCache(FINDER_CLASS_NAME_ENTITY);
		finderCache.clearCache(FINDER_CLASS_NAME_LIST_WITH_PAGINATION);
		finderCache.clearCache(FINDER_CLASS_NAME_LIST_WITHOUT_PAGINATION);
	}
641767
@Override
	public void cacheResult(CPDefinition cpDefinition) {
		entityCache.putResult(CPDefinitionModelImpl.ENTITY_CACHE_ENABLED,
			CPDefinitionImpl.class, cpDefinition.getPrimaryKey(), cpDefinition);

		finderCache.putResult(FINDER_PATH_FETCH_BY_UUID_G,
			new Object[] { cpDefinition.getUuid(), cpDefinition.getGroupId() },
			cpDefinition);

		finderCache.putResult(FINDER_PATH_FETCH_BY_C_ERC,
			new Object[] {
				cpDefinition.getCompanyId(),
				cpDefinition.getExternalReferenceCode()
			}, cpDefinition);

		cpDefinition.resetOriginalValues();
	}
494217
@Override
	public CPDefinition create(long CPDefinitionId) {
		CPDefinition cpDefinition = new CPDefinitionImpl();

		cpDefinition.setNew(true);
		cpDefinition.setPrimaryKey(CPDefinitionId);

		String uuid = PortalUUIDUtil.generate();

		cpDefinition.setUuid(uuid);

		cpDefinition.setCompanyId(companyProvider.getCompanyId());

		return cpDefinition;
	}
1104310
@Override
	public List<CPDefinitionGroupedEntry> findAll() {
		return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}
779119
@Override
	public CPDefinitionInventory create(long CPDefinitionInventoryId) {
		CPDefinitionInventory cpDefinitionInventory = new CPDefinitionInventoryImpl();

		cpDefinitionInventory.setNew(true);
		cpDefinitionInventory.setPrimaryKey(CPDefinitionInventoryId);

		String uuid = PortalUUIDUtil.generate();

		cpDefinitionInventory.setUuid(uuid);

		cpDefinitionInventory.setCompanyId(companyProvider.getCompanyId());

		return cpDefinitionInventory;
	}
428460
public static com.liferay.commerce.product.type.virtual.model.CPDefinitionVirtualSetting addCPDefinitionVirtualSetting(
		com.liferay.commerce.product.type.virtual.model.CPDefinitionVirtualSetting cpDefinitionVirtualSetting) {
		return getService()
				   .addCPDefinitionVirtualSetting(cpDefinitionVirtualSetting);
	}
226993
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CPDefinition updateCPDefinition(CPDefinition cpDefinition) {
		return cpDefinitionPersistence.update(cpDefinition);
	}
735691
@Override
	public List<CPDefinitionOptionValueRel> findByGroupId(long groupId) {
		return findByGroupId(groupId, QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}
783938
def AddMemberDefinition(self, member_definition):
    
    self._byte_size = None
    self.members.append(member_definition)

    if self.sections:
      section_definition = self.sections[-1]
      section_definition.members.append(member_definition)