Package com._1c.g5.v8.dt.dcs.dataset
Class DataSetWrapperBase<T extends DataSet>
- java.lang.Object
-
- com._1c.g5.v8.dt.dcs.dataset.DataSetWrapperBase<T>
-
- All Implemented Interfaces:
IDataSetWrapper
- Direct Known Subclasses:
DataSetsWrapperBase
public abstract class DataSetWrapperBase<T extends DataSet> extends Object implements IDataSetWrapper
Base implementation ofIDataSetWrapper
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com._1c.g5.v8.dt.dcs.dataset.IDataSetWrapper
IDataSetWrapper.FieldRestriction, IDataSetWrapper.FieldSynonym
-
-
Field Summary
Fields Modifier and Type Field Description protected TdataSetprotected DataSetsFieldsTreefieldsTreeprotected Map<DataSetField,IDataSetFieldsWrapper>fieldsWrappersprotected Map<String,IDataSetFieldsWrapper>fieldsWrappersByNameprotected Map<String,IDataSetWrapper.FieldRestriction>restrictionsprotected Map<String,IDataSetWrapper.FieldSynonym>synonyms
-
Constructor Summary
Constructors Constructor Description DataSetWrapperBase(T dataSet)Constructor
-
Method Summary
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com._1c.g5.v8.dt.dcs.dataset.IDataSetWrapper
copyField, getCurrentAlias, getCurrentLanguageCode, removeField, setFieldAttrUseRestiction, setFieldName, setFieldPath, setFieldTitle, setFieldUseRestiction
-
-
-
-
Field Detail
-
fieldsTree
protected DataSetsFieldsTree fieldsTree
-
fieldsWrappers
protected Map<DataSetField,IDataSetFieldsWrapper> fieldsWrappers
-
fieldsWrappersByName
protected Map<String,IDataSetFieldsWrapper> fieldsWrappersByName
-
synonyms
protected Map<String,IDataSetWrapper.FieldSynonym> synonyms
-
restrictions
protected Map<String,IDataSetWrapper.FieldRestriction> restrictions
-
-
Method Detail
-
init
public void init()
Description copied from interface:IDataSetWrapperInitialize- Specified by:
initin interfaceIDataSetWrapper
-
addField
public void addField(DataSetField currentField, DataSetField field) throws DcsPathException
Description copied from interface:IDataSetWrapperAdd field- Specified by:
addFieldin interfaceIDataSetWrapper- Parameters:
currentField- current field, can benullfield- field, can't benull- Throws:
DcsPathException
-
fillDataSetFields
public V8Commands.CompoundV8Command fillDataSetFields(List<DcsDataSetInfoAvailableFieldInfo> avialableFields)
FillsDataSet.getFields()fromDcsDataSetInfoAvailableFieldInfofields- Parameters:
avialableFields-DcsDataSetInfoAvailableFieldInfofields for creating DataSetField by them, can't benull- Returns:
V8Commands.CompoundV8Commandwith information of changing ofDataSet, nevernull
-
moveField
public void moveField(DataSetField field, String parentPathNew)
Description copied from interface:IDataSetWrapperMove field- Specified by:
moveFieldin interfaceIDataSetWrapper- Parameters:
field- field, can't benullparentPathNew- destination folder path ornull(empty) for root
-
getFieldsWrappers
public Collection<IDataSetFieldsWrapper> getFieldsWrappers()
Description copied from interface:IDataSetWrapperGet fields wrappers- Specified by:
getFieldsWrappersin interfaceIDataSetWrapper- Returns:
- collection of fields wrappers, never
null
-
getChildFields
public List<DataSetField> getChildFields(DataSetField parentField)
Description copied from interface:IDataSetWrapperGet child fields or root fields- Specified by:
getChildFieldsin interfaceIDataSetWrapper- Parameters:
parentField- parent field, can't benull- Returns:
- list of fields, never
null
-
getFieldName
public String getFieldName(DataSetField field)
Description copied from interface:IDataSetWrapperGet 'Field' property of field- Specified by:
getFieldNamein interfaceIDataSetWrapper- Parameters:
field- field, can't benull- Returns:
- value of 'Field' property
name from source, never
null, empty for folder
-
getFieldParentPath
public String getFieldParentPath(DataSetField field)
Description copied from interface:IDataSetWrapperGet path of field parent- Specified by:
getFieldParentPathin interfaceIDataSetWrapper- Parameters:
field- field, can't benull- Returns:
- path of field parent, can be
null
-
getAncestorField
public DataSetField getAncestorField(DataSetField field)
Description copied from interface:IDataSetWrapperGet ancestor for field- Specified by:
getAncestorFieldin interfaceIDataSetWrapper- Parameters:
field- field, can't benull- Returns:
- ancestor if exists or
null
-
getFieldSynonym
public IDataSetWrapper.FieldSynonym getFieldSynonym(String path)
Description copied from interface:IDataSetWrapperGet field synonym- Specified by:
getFieldSynonymin interfaceIDataSetWrapper- Parameters:
path- path of field, can't benull- Returns:
- synonym or
null
-
getFieldRestriction
public IDataSetWrapper.FieldRestriction getFieldRestriction(String path)
Description copied from interface:IDataSetWrapperGet field restriction- Specified by:
getFieldRestrictionin interfaceIDataSetWrapper- Parameters:
path- path of field, can't benull- Returns:
- restriction or
null
-
getField
public DataSetField getField(String path)
Description copied from interface:IDataSetWrapperGet field- Specified by:
getFieldin interfaceIDataSetWrapper- Parameters:
path- field path, can't benull- Returns:
- field or
nullif field not found
-
getFieldPath
public String getFieldPath(DataSetField field)
Description copied from interface:IDataSetWrapperGet 'Data path' property of field- Specified by:
getFieldPathin interfaceIDataSetWrapper- Parameters:
field- field, can't benull- Returns:
- value of 'Data path' property, never
null
-
createPath
public DcsPath createPath(String path) throws IDataSetFieldsWrapper.FieldRenameException
Description copied from interface:IDataSetWrapperCreate path from string- Specified by:
createPathin interfaceIDataSetWrapper- Parameters:
path- string path, nevernull- Returns:
- DCS path, never
null - Throws:
IDataSetFieldsWrapper.FieldRenameException- if path is not valid
-
createFieldWrapper
protected IDataSetFieldsWrapper createFieldWrapper(DataSetField field)
Create field wrapper- Parameters:
field- field, can't benull- Returns:
- wrapper or
nullif field type unknown
-
fillFieldsWrappers
protected void fillFieldsWrappers(List<DataSetField> fields)
Fills wrapper fields- Parameters:
fields- fields for wrapping, can't benull
-
addFieldWrapper
protected void addFieldWrapper(IDataSetFieldsWrapper fieldWrapper)
Add field wrapper- Parameters:
fieldWrapper- wrapper, can't benull
-
-