Interface MTSymbolQuery
- All Superinterfaces:
MTContextQuery
,MTDateFilterQuery
,MTMissingTranslationsQuery
,MTPatternQuery
,MTQuery
,MTSortableQuery
public interface MTSymbolQuery
extends MTQuery, MTDateFilterQuery, MTPatternQuery, MTSortableQuery, MTMissingTranslationsQuery, MTContextQuery
-
Nested Class Summary
Nested classes/interfaces inherited from interface se.conciliate.extensions.store.query.MTQuery
MTQuery.ResultContext, MTQuery.SortColumn, MTQuery.State
-
Method Summary
Modifier and TypeMethodDescriptioninLockedModels
(boolean includeInitialRevisions) Selects only symbols in locked revisions of models.Selects symbols by their ID.Selects symbols by executing a list.Selects all symbols in the workspace.selectByModels
(MTModelHeader... models) Selects symbols that are used in given models.selectByNamedQuery
(MTNamedQuery namedQuery) Selects from a named query.selectByUUID
(List<String> uuids) Selects symbols by their UUID.Selects all symbols that are not used in any models.sort
(MTQuery.SortColumn sortColumn, boolean ascending, MTLanguage language, Locale locale) Sorts the selected symbols.storeContexts
(MTQuery.ResultContext... contexts) Stores the selected contexts for the results of the query, for filtering and grouping of results.withAttributeDataTypes
(List<String> attributeDataTypeID) Retains only symbols connected to attribute types with the given data type.withAttributeTypeUUIDs
(List<String> selectedUUIDs) Retains only symbols connected to any of the attribute types in the list.withAttributeValues
(MTAttributeFilter filter) Retains only symbols with selected attribute values.withChangesSince
(Date date) Excludes symbols that have not been modified since a given date.withCreators
(MTUserHeader... creators) Retains only symbols with at least one of the given users set as creator of the model.withDocuments
(Document.DocumentID... documents) Retains only symbols with at least one of the given documents connected to it.withGroups
(MTGroupHeader... groups) Retains only symbols with at least one of the given groups set as group of the symbol.withLastModifiedBy
(MTUserHeader... modifiers) Retains only symbols that was last modified by one of the given userswithLockedRevisions
(boolean includeInitialRevisions) Retains only locked revisions of symbols.Retains only symbols that are missing home models.withOwners
(MTUserHeader... owners) Retains only symbosl with at least one of the given users set as owner of the model.withPattern
(String pattern, MTLanguage language, boolean exactMatch, boolean ignoreCase) Excludes results where the title does not containpattern
as a substring.withTypes
(SymbolType... type) Exclude all symbols that does not have one of the given types.Methods inherited from interface se.conciliate.extensions.store.query.MTContextQuery
storeContextsLockedRevisions
Methods inherited from interface se.conciliate.extensions.store.query.MTMissingTranslationsQuery
withMissingTranslations
Methods inherited from interface se.conciliate.extensions.store.query.MTQuery
attributeTypes, clear, colorSchemes, documents, documentSources, documentTypes, entityProperties, execute, getResultTypes, getState, images, layerTypes, lists, models, pluginData, publishProfiles, serialize, subscribers, symbols, timestamps, users, variables, workspacePluginData
-
Method Details
-
selectAll
MTSymbolQuery selectAll()Selects all symbols in the workspace.- Returns:
- A new updated symbol query.
-
selectUnused
MTSymbolQuery selectUnused()Selects all symbols that are not used in any models.- Returns:
- A new updated symbol query.
-
select
Selects symbols by their ID.- Parameters:
ids
- The ID:s of the symbols to select.- Returns:
- A new updated symbol query.
-
selectByUUID
Selects symbols by their UUID.- Parameters:
uuids
- The UUID:s of the symbols to select.- Returns:
- A new updated symbol query.
-
select
Selects symbols by executing a list.- Parameters:
list
- The list to execute.- Returns:
- A new updated symbol query.
- Throws:
IllegalArgumentException
- Iflist.getResultType() != MTList.ResultType.SYMBOL
.
-
selectByNamedQuery
Selects from a named query. This way you can base queries on other named queries and filter them further.- Parameters:
namedQuery
- The named query to base this query on.- Returns:
- A new updated symbol query.
-
selectByModels
Selects symbols that are used in given models.- Parameters:
models
- The models.- Returns:
- A new updated symbol query.
-
withTypes
Exclude all symbols that does not have one of the given types.- Parameters:
type
- The types to include- Returns:
- A new updated symbol query.
-
withCurrentRevisions
MTSymbolQuery withCurrentRevisions() -
withLockedRevisions
Retains only locked revisions of symbols. If the current revision in the workspace is locked the previous (locked) revision of the symbol is selected instead.- Parameters:
includeInitialRevisions
- If true the initial revisions (rev 0) will still be included in the result even they are not locked.- Returns:
- A new updated symbol query.
-
withPattern
MTSymbolQuery withPattern(String pattern, MTLanguage language, boolean exactMatch, boolean ignoreCase) Excludes results where the title does not containpattern
as a substring.- Specified by:
withPattern
in interfaceMTPatternQuery
- Parameters:
pattern
- The pattern to search for.language
- The language of the title to find the pattern in.exactMatch
- Require the pattern to match the title exactly rather than containing the pattern.ignoreCase
- Ignores case. This makes "exact match" check lowercase strings for equality and "contains match" check lowercase for contains.- Returns:
- A new updated symbol query.
-
withChangesSince
Excludes symbols that have not been modified since a given date.- Specified by:
withChangesSince
in interfaceMTDateFilterQuery
- Parameters:
date
- The date to compare against.- Returns:
- A new updated symbol query.
-
withCreators
Retains only symbols with at least one of the given users set as creator of the model.- Parameters:
creators
- The accepted creators.- Returns:
- A new updated symbol query.
-
withOwners
Retains only symbosl with at least one of the given users set as owner of the model.- Parameters:
owners
- The accepted owners.- Returns:
- A new updated symbol query.
-
withGroups
Retains only symbols with at least one of the given groups set as group of the symbol.- Parameters:
groups
- The accepted groups.- Returns:
- A new updated symbol query.
-
withLastModifiedBy
Retains only symbols that was last modified by one of the given users- Parameters:
modifiers
- The accepted modifiers.- Returns:
- A new updated symbol query.
-
withAttributeValues
Retains only symbols with selected attribute values.- Parameters:
filter
- The filter used.- Returns:
- A new updated symbol query.
-
withAttributeDataTypes
Retains only symbols connected to attribute types with the given data type.- Parameters:
attributeDataTypeID
- The id of the attribute data type, i.e. "conciliate.rich.text" or whatever it is called.- Returns:
- A new updated symbol query.
-
withAttributeTypeUUIDs
Retains only symbols connected to any of the attribute types in the list.- Parameters:
selectedUUIDs
- The uuid of the attribute type.- Returns:
- A new updated symbol query.
-
withoutHomeModel
MTSymbolQuery withoutHomeModel()Retains only symbols that are missing home models.- Returns:
- A new updated symbol query.
-
withDocuments
Retains only symbols with at least one of the given documents connected to it.- Parameters:
documents
- The documents- Returns:
- A new updated symbol query.
-
sort
MTSymbolQuery sort(MTQuery.SortColumn sortColumn, boolean ascending, MTLanguage language, Locale locale) Sorts the selected symbols.- Specified by:
sort
in interfaceMTSortableQuery
- Parameters:
sortColumn
- The column to sort byascending
- true for ascending order, false for descendinglanguage
- The language to sort bylocale
- the locale to use when sorting- Returns:
- A new updated symbol query.
-
storeContexts
Description copied from interface:MTContextQuery
Stores the selected contexts for the results of the query, for filtering and grouping of results.- Specified by:
storeContexts
in interfaceMTContextQuery
-
inLockedModels
Selects only symbols in locked revisions of models.- Parameters:
includeInitialRevisions
- If true, includes symbols in initial revisions that have not yet been locked.- Returns:
- A new updated symbol query.
-