Search:

# CWIS Developers Documentation

# MetadataSchema Class Reference

Collaboration diagram for MetadataSchema:

[legend]

## Public Member Functions
| MetadataSchema ()
| CacheData ($NewValue)
| AddField ($FieldName, $FieldType, $Optional=TRUE, $DefaultValue=NULL)
| DropField ($FieldId)
| GetField ($FieldId)
| GetFieldByName ($FieldName, $IgnoreCase=FALSE)
| GetFieldIdByName ($FieldName, $IgnoreCase=FALSE)
| FieldExists ($FieldName)
| GetFields ($FieldTypes=NULL, $OrderType=NULL, $IncludeDisabledFields=FALSE, $IncludeTempFields=FALSE)
| GetFieldNames ($FieldTypes=NULL, $OrderType=NULL, $IncludeDisabledFields=FALSE, $IncludeTempFields=FALSE)
| GetFieldTypes ()
| GetAllowedFieldTypes ()
| RemoveQualifierAssociations ($QualifierIdOrObject)
| QualifierIsInUse ($QualifierIdOrObject)
| MoveUpInOrder ($FieldIdOrObj, $OrderType)
| MoveDownInOrder ($FieldIdOrObj, $OrderType)
| GetHighestFieldId ()
| MoveFieldInOrder ($FieldIdOrObj, $OrderType, $MoveFieldDown)
| CompareFieldOrder ($FieldA, $FieldB)
## Public Attributes
const | MDFORDER_DISPLAY = 1
const | MDFORDER_EDITING = 2
const | MDFTYPE_TEXT = 1
const | MDFTYPE_PARAGRAPH = 2
const | MDFTYPE_NUMBER = 4
const | MDFTYPE_DATE = 8
const | MDFTYPE_TIMESTAMP = 16
const | MDFTYPE_FLAG = 32
const | MDFTYPE_TREE = 64
const | MDFTYPE_CONTROLLEDNAME = 128
const | MDFTYPE_OPTION = 256
const | MDFTYPE_USER = 512
const | MDFTYPE_IMAGE = 1024
const | MDFTYPE_FILE = 2048
const | MDFTYPE_URL = 4096
const | MDFTYPE_POINT = 8192
const | MDFSTAT_OK = 1
const | MDFSTAT_DUPLICATENAME = 2
const | MDFSTAT_DUPLICATEDBCOLUMN = 4
const | MDFSTAT_ILLEGALNAME = 8
const | MDFSTAT_FIELDDOESNOTEXIST = 16
| $FieldCompareType
| $CachingOn

List of all members.

## Detailed Description

Definition at line 38 of file MetadataSchema.php.

Inheritance diagram for MetadataSchema:

[legend]

## Member Function Documentation

MetadataSchema::AddField | ( | $ | FieldName,
|  | $ | FieldType,
|  | $ | Optional = `TRUE`,
|  | $ | DefaultValue = `NULL` |
| ) |  |  |

Definition at line 88 of file MetadataSchema.php.

References MDFSTAT_OK.

MetadataSchema::CacheData | ( | $ | NewValue | ) |

Definition at line 82 of file MetadataSchema.php.

MetadataSchema::CompareFieldOrder | ( | $ | FieldA,
|  | $ | FieldB |
| ) |  |  |

Definition at line 344 of file MetadataSchema.php.

MetadataSchema::DropField | ( | $ | FieldId | ) |

Definition at line 105 of file MetadataSchema.php.

References ItemFactory::$FieldId.

MetadataSchema::FieldExists | ( | $ | FieldName | ) |

Definition at line 154 of file MetadataSchema.php.

References GetFieldByName().

MetadataSchema::GetAllowedFieldTypes | ( |  | ) |

Definition at line 247 of file MetadataSchema.php.

References MetadataField::$FieldTypeDBAllowedEnums.

MetadataSchema::GetField | ( | $ | FieldId | ) |

Definition at line 112 of file MetadataSchema.php.

References ItemFactory::$FieldId.

Referenced by GetFieldByName().

Here is the caller graph for this function:

MetadataSchema::GetFieldByName | ( | $ | FieldName,
|  | $ | IgnoreCase = `FALSE` |
| ) |  |  |

Definition at line 128 of file MetadataSchema.php.

References ItemFactory::$FieldId, GetField(), and GetFieldIdByName().

Referenced by FieldExists().

Here is the caller graph for this function:

MetadataSchema::GetFieldIdByName | ( | $ | FieldName,
|  | $ | IgnoreCase = `FALSE` |
| ) |  |  |

Definition at line 135 of file MetadataSchema.php.

Referenced by GetFieldByName().

Here is the caller graph for this function:

MetadataSchema::GetFieldNames | ( | $ | FieldTypes = `NULL`,
|  | $ | OrderType = `NULL`,
|  | $ | IncludeDisabledFields = `FALSE`,
|  | $ | IncludeTempFields = `FALSE` |
| ) |  |  |

Definition at line 222 of file MetadataSchema.php.

References ItemFactory::$DB, and GetFields().

MetadataSchema::GetFields | ( | $ | FieldTypes = `NULL`,
|  | $ | OrderType = `NULL`,
|  | $ | IncludeDisabledFields = `FALSE`,
|  | $ | IncludeTempFields = `FALSE` |
| ) |  |  |

Definition at line 160 of file MetadataSchema.php.

References MetadataField::$FieldTypePHPEnums.

Referenced by GetFieldNames(), and MoveFieldInOrder().

Here is the caller graph for this function:

MetadataSchema::GetFieldTypes | ( |  | ) |

Definition at line 241 of file MetadataSchema.php.

References MetadataField::$FieldTypeDBEnums.

MetadataSchema::GetHighestFieldId | ( |  | ) |

Definition at line 296 of file MetadataSchema.php.

References ItemFactory::GetHighestItemId().

MetadataSchema::MetadataSchema | ( |  | ) |

Definition at line 72 of file MetadataSchema.php.

References ItemFactory::ItemFactory().

MetadataSchema::MoveDownInOrder | ( | $ | FieldIdOrObj,
|  | $ | OrderType |
| ) |  |  |

Definition at line 290 of file MetadataSchema.php.

References MoveFieldInOrder().

MetadataSchema::MoveFieldInOrder | ( | $ | FieldIdOrObj,
|  | $ | OrderType,
|  | $ | MoveFieldDown |
| ) |  |  |

Definition at line 307 of file MetadataSchema.php.

References ItemFactory::$FieldId, and GetFields().

Referenced by MoveDownInOrder(), and MoveUpInOrder().

Here is the caller graph for this function:

MetadataSchema::MoveUpInOrder | ( | $ | FieldIdOrObj,
|  | $ | OrderType |
| ) |  |  |

Definition at line 286 of file MetadataSchema.php.

References MoveFieldInOrder().

MetadataSchema::QualifierIsInUse | ( | $ | QualifierIdOrObject | ) |

Definition at line 265 of file MetadataSchema.php.

MetadataSchema::RemoveQualifierAssociations | ( | $ | QualifierIdOrObject | ) |

Definition at line 253 of file MetadataSchema.php.

## Member Data Documentation

MetadataSchema::$CachingOn

Definition at line 305 of file MetadataSchema.php.

MetadataSchema::$FieldCompareType

Definition at line 304 of file MetadataSchema.php.

const MetadataSchema::MDFORDER_DISPLAY = 1

Definition at line 43 of file MetadataSchema.php.

Referenced by MetadataField::MetadataField(), and MetadataField::OrderPosition().

const MetadataSchema::MDFORDER_EDITING = 2

Definition at line 44 of file MetadataSchema.php.

Referenced by MetadataField::MetadataField(), and MetadataField::OrderPosition().

const MetadataSchema::MDFSTAT_DUPLICATEDBCOLUMN = 4

Definition at line 67 of file MetadataSchema.php.

const MetadataSchema::MDFSTAT_DUPLICATENAME = 2

Definition at line 66 of file MetadataSchema.php.

Referenced by MetadataField::MetadataField(), and MetadataField::Name().

const MetadataSchema::MDFSTAT_FIELDDOESNOTEXIST = 16

Definition at line 69 of file MetadataSchema.php.

Referenced by MetadataField::MetadataField().

const MetadataSchema::MDFSTAT_ILLEGALNAME = 8

Definition at line 68 of file MetadataSchema.php.

Referenced by MetadataField::IsTempItem(), and MetadataField::Name().

const MetadataSchema::MDFSTAT_OK = 1

Definition at line 65 of file MetadataSchema.php.

Referenced by AddField(), MetadataField::MetadataField(), and MetadataField::Name().

const MetadataSchema::MDFTYPE_CONTROLLEDNAME = 128

Definition at line 56 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), MetadataField::GetCountOfPossibleValues(), MetadataField::GetFactory(), MetadataField::GetIdForValue(), MetadataField::GetPossibleValues(), Resource::GetQualifierByField(), SPTOAIItem::GetSets(), MetadataField::GetValueForId(), SPTOAIItemFactory::LoadSetNameInfo(), MetadataField::ModifyField(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), and SPTSearchEngine::SPTSearchEngine().

const MetadataSchema::MDFTYPE_DATE = 8

Definition at line 52 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), ResourceFactory::GetMatchingResources(), ResourceFactory::GetResourceIdsSortedBy(), MetadataField::ModifyField(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), and SPTSearchEngine::SPTSearchEngine().

const MetadataSchema::MDFTYPE_FILE = 2048

Definition at line 60 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), MetadataField::ModifyField(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), and SPTSearchEngine::SPTSearchEngine().

const MetadataSchema::MDFTYPE_FLAG = 32

Definition at line 54 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), MetadataField::GetCountOfPossibleValues(), ResourceFactory::GetMatchingResources(), MetadataField::GetPossibleValues(), MetadataField::ModifyField(), Resource::Resource(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), SPTSearchEngine::SPTSearchEngine(), and SavedSearch::TranslateValues().

const MetadataSchema::MDFTYPE_IMAGE = 1024

Definition at line 59 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), Resource::Delete(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), MetadataField::ModifyField(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), and SPTSearchEngine::SPTSearchEngine().

const MetadataSchema::MDFTYPE_NUMBER = 4

Definition at line 51 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), ResourceFactory::GetMatchingResources(), ResourceFactory::GetResourceIdsSortedBy(), MetadataField::ModifyField(), Resource::Resource(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), SPTSearchEngine::SPTSearchEngine(), SavedSearch::TranslateValues(), and UnitTest().

const MetadataSchema::MDFTYPE_OPTION = 256

Definition at line 57 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), MetadataField::GetCountOfPossibleValues(), MetadataField::GetFactory(), MetadataField::GetIdForValue(), MetadataField::GetPossibleValues(), Resource::GetQualifierByField(), SPTOAIItem::GetSets(), MetadataField::GetValueForId(), SPTOAIItemFactory::LoadSetNameInfo(), MetadataField::ModifyField(), Resource::Resource(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), SPTSearchEngine::SPTSearchEngine(), and SavedSearch::TranslateValues().

const MetadataSchema::MDFTYPE_PARAGRAPH = 2

Definition at line 50 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), ResourceFactory::GetMatchingResources(), ResourceFactory::GetResourceIdsSortedBy(), MetadataField::ModifyField(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), SPTSearchEngine::SPTSearchEngine(), and UnitTest().

const MetadataSchema::MDFTYPE_POINT = 8192

Definition at line 62 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::DefaultValue(), MetadataField::Drop(), Resource::Get(), ResourceFactory::GetMatchingResources(), MetadataField::ModifyField(), Resource::Resource(), Resource::Set(), and SPTSearchEngine::SPTSearchEngine().

const MetadataSchema::MDFTYPE_TEXT = 1

Definition at line 49 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), ResourceFactory::GetMatchingResources(), ResourceFactory::GetResourceIdsSortedBy(), MetadataField::ModifyField(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), and SPTSearchEngine::SPTSearchEngine().

const MetadataSchema::MDFTYPE_TIMESTAMP = 16

Definition at line 53 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), ResourceFactory::GetMatchingResources(), ResourceFactory::GetResourceIdsSortedBy(), MetadataField::ModifyField(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), and SPTSearchEngine::SPTSearchEngine().

const MetadataSchema::MDFTYPE_TREE = 64

Definition at line 55 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), MetadataField::GetCountOfPossibleValues(), MetadataField::GetFactory(), MetadataField::GetIdForValue(), MetadataField::GetPossibleValues(), Resource::GetQualifierByField(), SPTOAIItem::GetSets(), MetadataField::GetValueForId(), SPTOAIItemFactory::LoadSetNameInfo(), MetadataField::ModifyField(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), and SPTSearchEngine::SPTSearchEngine().

const MetadataSchema::MDFTYPE_URL = 4096

Definition at line 61 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), ResourceFactory::GetMatchingResources(), ResourceFactory::GetResourceIdsSortedBy(), MetadataField::ModifyField(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), and SPTSearchEngine::SPTSearchEngine().

const MetadataSchema::MDFTYPE_USER = 512

Definition at line 58 of file MetadataSchema.php.

Referenced by MetadataField::AddDatabaseFields(), Resource::ClearByField(), MetadataField::Drop(), Resource::Get(), MetadataField::GetAllowedConversionTypes(), MetadataField::ModifyField(), SPTSearchEngine::SearchFieldForPhrases(), SPTSearchEngine::SearchFieldsForComparisonMatches(), Resource::Set(), SPTRecommender::SPTRecommender(), SPTSearchEngine::SPTSearchEngine(), and SavedSearch::TranslateValues().

The documentation for this class was generated from the following file:

- MetadataSchema.php