com.microsoft.tfs.core.clients.workitem.query
Class QueryDocument
java.lang.Object
com.microsoft.tfs.core.clients.workitem.query.QueryDocument
public class QueryDocument
- extends java.lang.Object
A QueryDocument is used in the UI to represent a work item query. Some
QueryDocuments conceptually represent other significant objects in the
system. For example, QueryDocument
s can be used to represent
StoredQuery
s or WIQ files on disk. However, some
QueryDocument
s represent nothing, such as a QueryDocument
used to create a new query or a QueryDocument
used to represent a
power search.
A QueryDocument
is not immutable. However, once created, a
QueryDocument
will only ever represent a single conceptual item. For
example, a QueryDocument
instance that represents a
StoredQuery
will never change and start representing a WIQ file.
QueryDocument
s can be obtained from the QueryDocument
service. The QueryDocumentService is also used to manage the lifecycle of
QueryDocument
s that represent persistent items like
StoredQuery
s and WIQ files.
- Since:
- TEE-SDK-10.1
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
QueryDocument
public QueryDocument(WorkItemClient workItemClient)
getDefaultResultOptions
public static ResultOptions getDefaultResultOptions(FieldDefinitionCollection fieldDefinitions,
QueryDocument queryDocument)
setFile
public void setFile(java.io.File file)
setGUID
public void setGUID(com.microsoft.tfs.util.GUID guid)
restoreGUIDAndFile
public void restoreGUIDAndFile(com.microsoft.tfs.util.GUID guid,
java.io.File file)
setParentGUID
public void setParentGUID(com.microsoft.tfs.util.GUID parentGuid)
load
public void load()
save
public void save()
getExistingQueryByName
public QueryItem getExistingQueryByName(java.lang.String name)
getQueryScope
public QueryScope getQueryScope()
setQueryScope
public void setQueryScope(QueryScope scope)
getResultOptions
public ResultOptions getResultOptions()
setResultOptions
public void setResultOptions(ResultOptions resultOptions)
getFilterExpression
public java.lang.String getFilterExpression()
setFilterExpression
public void setFilterExpression(java.lang.String filterExpression)
getName
public java.lang.String getName()
setName
public void setName(java.lang.String name)
updateName
public void updateName(java.lang.String name)
- Update the document name without marking the document dirty.
- Parameters:
name
- The new name for the document.
getHierarchicalPath
public java.lang.String getHierarchicalPath()
getDescription
public java.lang.String getDescription()
setDescription
public void setDescription(java.lang.String description)
getQueryText
public java.lang.String getQueryText()
setQueryText
public void setQueryText(java.lang.String queryText)
getQueryMode
public LinkQueryMode getQueryMode()
setQueryMode
public void setQueryMode(LinkQueryMode queryMode)
getQueryType
public QueryType getQueryType()
setQueryType
public void setQueryType(QueryType queryType)
reset
public void reset()
getGUID
public com.microsoft.tfs.util.GUID getGUID()
getParentGUID
public com.microsoft.tfs.util.GUID getParentGUID()
getFile
public java.io.File getFile()
getProjectName
public java.lang.String getProjectName()
setProjectName
public void setProjectName(java.lang.String projectName)
getTeamName
public java.lang.String getTeamName()
setTeamName
public void setTeamName(java.lang.String teamName)
getWorkItemClient
public WorkItemClient getWorkItemClient()
isDirty
public boolean isDirty()
clearDirty
public void clearDirty()
addDirtyListener
public void addDirtyListener(QueryDocumentDirtyListener listener)
removeDirtyListener
public void removeDirtyListener(QueryDocumentDirtyListener listener)
addSaveListener
public void addSaveListener(QueryDocumentSaveListener listener)
removeSaveListener
public void removeSaveListener(QueryDocumentSaveListener listener)
isLinkQuery
public boolean isLinkQuery()
isTreeQuery
public boolean isTreeQuery()
© 2015 Microsoft. All rights reserved.