Class Index | File Index

Classes


Class Monk.component.Component


Extends Workbench.lang.Object.
A class encompassing an Ext.Panel and related methods. These typically get rendered as "steps" in the workflow.
Defined in: workflowFeature.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
Field Summary
Field Attributes Field Name and Description
 
A method called every time the panel has been rendered.
 
A method called after the panel has been rendered for the first time, typically for initiallizing drag n drop.
 
Used to determine if the afterRenderFirstTime method has been called.
 
A method to call before the user "exits" the panel (by switching to a different one).
 
id
The ID for this component.
 
A label for the component, used for the corresponding toolbar button.
 
The base panel for this component.
Method Summary
Method Attributes Method Name and Description
 
addResultsToProject(resultsElement, projectData)
Adds results to the project data.
 
addTermsToChunk(chunkId, terms)
Associates a number of terms/features with a specific chunk.
 
alert(title, msg, target)
 
associativeArray2Arrays(associativeArray, innerValue)
Takes an associative array and returns two arrays: keys and values.
 
 
bind(store)
 
 
Removes the terms/features associated with a specific chunk.
 
Clears the worklist for the current workset.
 
confirm(title, msg, fn, scope, target)
 
 
createNewProject(projectElement)
Creates a new project object, suitable for addition to projectData.
 
Create a custom toolset config for viewing a result
 
Creates a new toolset config object.
 
doFeatureComparison(string, featureType, queryParam)
This functions calls the backend to do the analysis
 
doLoad(start)
 
doSimilarityQuery(queryParam, append)
This call allows all the containers -worksets/search criterion etc.
 
doSimpleQuery(queryParam, append)
 
 
Returns list of chunks saved from the previous similarity/search browse
 
This is a legacy method to adapt to the Nora services.
 
Returns the chunk currently being viewed.
 
Returns the decision tree
 
getDecisionTreeImage(decisionTree)
Set the decision tree summary.
 
Returns the decision tree summary
 
 
Returns the feature for this workset.
 
Returns the feature list.
 
Returns the instance ID for the most recent analysis result.
 
Returns the itinerary for this workset.
 
 
Returns the timestamp from the last load of workset
 
 
 
 
Returns the project ID for this workset.
 
Return the query parameter
 
getResults(type)
Gets results of a particular type.
 
 
Returns the result summary.
 
Returns the terms/features found in a specific chunk.
 
Returns the toolset ID for this toolset.
 
Returns the worklist for this workset.
 
Returns the current workset, including all the relevant properties.
 
Returns the workset ID for this workset.
 
Returns the workset label (longer form) for this workset.
 
Returns the name of this workset.
 
growl(title, msg, target)
 
Overwrite to handle Monk events.
 
handleResponse(response)
 
init(paging)
 
 
Methods for running analyses
 
Is this component's panel is currently being displayed? Typically used to determine if the component should handle certain events.
 
Returns true if there is unsaved workset data.
 
Checks for a minimum of 2 ratings in the workset, (before running an analysis).
 
load(params, reader, callback, scope, arg)
 
loadOrSet(num)
 
loadWorkset(worksetId)
 
 
 
 
 
notify(workbenchEvent, resultsData)
Notify the component manager of this event.
 
onInitView(paging)
 
onLoad(store, r, o)
 
 
 
 
onRender(ct, position)
 
processChunk(chunk)
Called when a user checks a chunk.
 
processResults(instanceId, resultsArray)
Processes results data and sets it in this DataManager.
 
 
progress(title, msg, progressTxt, target)
 
prompt(title, msg, target)
 
 
 
remove(data)
 
renderResults(numColumns, columnHeight)
 
renderWorksets(numColumns, columnHeight)
 
 
reset(resetProject)
Resets everything back to the initial values.
 
Reset the chunkList
 
 
Returns the results to their initial state
 
Returns the workset to its initial state
 
 
 
selectWorkset(worksetId)
 
 
Store the list of chunks retrieved as a result of a search/browse or Similarity search
 
Sets the chunk currently being viewed.
 
setDecisionTree(decisionTree)
Set the decision tree.
 
setDecisionTreeImage(decisionTree)
Set the decision tree summary.
 
setDecisionTreeSummary(decisionTree)
Set the decision tree summary.
 
setFeature(feature)
Sets the feature for this workset.
 
setFeatureList(featureList)
Set the feature list for this workset.
 
setInstanceId(instanceId)
Sets the instance ID for the most recent analysis result.
 
setItinerary(itinerary)
Sets the itinerary for this workset.
 
 
setProjectData(projectData)
Set the project data for this session
 
setProjectId(projectId)
Sets the project ID for this workset.
 
Set the result summary.
 
setSearchQueryParam(queryParams)
Set query param
 
setSimilarQueryParam(queryParam, append)
Set similar search query param
 
setTimer(token)
 
setToolsetId(toolsetId)
Sets the toolset ID for this toolset.
 
 
setUserRatings(trainingList, trainingListRating)
Sets the training list for this workset.
 
setWorklist(worklist, worklistRating, confidence)
Sets the worklist for this workset.
 
setWorkset(workset)
Loads a workset into the data manager.
 
setWorksetId(worksetId)
Sets the workset ID for this workset.
 
setWorksetName(worksetName)
Sets the name of this workset.
 
This query will retrieve the workset information from the middleware and update the common work store that is used by the result summary tool
 
show(config, target)
 
 
unbind(store)
 
update(newData, append)
 
 
 
Update the workset in projectData with the values from the currently loaded workset.
 
updateRecord(recordId, attributeObject)
 
 
wait(title, msg, target)
Class Detail
Monk.component.Component()
Field Detail
{Function} afterRenderEveryTime
A method called every time the panel has been rendered.

{Function} afterRenderFirstTime
A method called after the panel has been rendered for the first time, typically for initiallizing drag n drop.

{Boolean} afterRenderFirstTimeCalled
Used to determine if the afterRenderFirstTime method has been called.

{Function} beforeExit
A method to call before the user "exits" the panel (by switching to a different one).

{String} id
The ID for this component.

{String} label
A label for the component, used for the corresponding toolbar button.

{Ext.Panel} panel
The base panel for this component.
Method Detail
addResultsToProject(resultsElement, projectData)
Adds results to the project data.
Defined in: data-manager.js.
Parameters:
{Element} resultsElement
An element containing results info.
{Object} projectData
The project data to add to.

addTermsToChunk(chunkId, terms)
Associates a number of terms/features with a specific chunk.
Defined in: data-manager.js.
Parameters:
{String} chunkId
The chunk ID
{Array} terms
An array of terms to add

alert(title, msg, target)

Defined in: messenger.js.
Parameters:
title
msg
target

{Array} associativeArray2Arrays(associativeArray, innerValue)
Takes an associative array and returns two arrays: keys and values. If innerValue is passed, then the method looks for a property of value instead of the value itself e.g. value = object[key][innerValue].
Defined in: data-manager.js.
Parameters:
{Object} associativeArray
{String} innerValue
Returns:
{Array} An array containing two arrays of keys and values

beforeLoad()

Defined in: paging_toolbar_improvements.js.

bind(store)

Defined in: paging_toolbar_improvements.js.
Parameters:
store

cancelAnalysis()

Defined in: data-manager.js.

clearTermsForChunks()
Removes the terms/features associated with a specific chunk.
Defined in: data-manager.js.

clearWorklist()
Clears the worklist for the current workset.
Defined in: data-manager.js.

confirm(title, msg, fn, scope, target)

Defined in: messenger.js.
Parameters:
title
msg
fn
scope
target

contains(id)

Defined in: paging_memory_proxy.js.
Parameters:
id

{Object} createNewProject(projectElement)
Creates a new project object, suitable for addition to projectData.
Defined in: data-manager.js.
Parameters:
{Element} projectElement
An element containing project info.
Returns:
{Object} A project object

{Object} createResultToolset(key)
Create a custom toolset config for viewing a result
Defined in: WorksetSelector.js.
Parameters:
{String} key
The key of the result in the result collection
Returns:
{Object} The toolset config

createToolsetConfig(toolsetId)
Creates a new toolset config object.
Defined in: data-manager.js.
Parameters:
{String} toolsetId
The toolset ID to use

doFeatureComparison(string, featureType, queryParam)
This functions calls the backend to do the analysis
Defined in: data-manager.js.
Parameters:
string
type /workset/collection or author
featureType
feature_spelling_gender, feature_lemma_gender
queryParam

doLoad(start)

Defined in: paging_toolbar_improvements.js.
Parameters:
start

doSimilarityQuery(queryParam, append)
This call allows all the containers -worksets/search criterion etc. the setSimilarQueryParam call is redundant
Defined in: data-manager.js.
Parameters:
queryParam
append

doSimpleQuery(queryParam, append)

Defined in: data-manager.js.
Parameters:
queryParam
append

getActivePage()

Defined in: paging_toolbar_improvements.js.

getChunkSimilar()
Returns list of chunks saved from the previous similarity/search browse
Defined in: data-manager.js.

{String} getChunkType()
This is a legacy method to adapt to the Nora services. It tallies up the chunkTypes and sets the workset's chunkType to whichever is the most prevalent.
Defined in: data-manager.js.
Returns:
{String} The chunk type

{Object} getCurrentChunk()
Returns the chunk currently being viewed.
Defined in: data-manager.js.
Returns:
{Object} The current chunk.

{String} getDecisionTree()
Returns the decision tree
Defined in: data-manager.js.
Returns:
{String} The decision tree

getDecisionTreeImage(decisionTree)
Set the decision tree summary.
Defined in: data-manager.js.
Parameters:
{String} decisionTree
A decision tree string

{String} getDecisionTreeSummary()
Returns the decision tree summary
Defined in: data-manager.js.
Returns:
{String} The decision tree

getDocumentList()

Defined in: data-manager.js.

{String} getFeature()
Returns the feature for this workset.
Defined in: data-manager.js.
Returns:
{String} The feature

{Array} getFeatureList()
Returns the feature list.
Defined in: data-manager.js.
Returns:
{Array} The feature list

{String} getInstanceId()
Returns the instance ID for the most recent analysis result.
Defined in: data-manager.js.
Returns:
{String} The instance ID

{String} getItinerary()
Returns the itinerary for this workset.
Defined in: data-manager.js.
Returns:
{String} The itinerary

getLastPage()

Defined in: paging_toolbar_improvements.js.

{Number} getLastWorksetLoadedTimestamp()
Returns the timestamp from the last load of workset
Defined in: data-manager.js.
Returns:
{Number} The last timestamp

getPageData()

Defined in: paging_toolbar_improvements.js.

getPageSize()

Defined in: paging_toolbar_improvements.js.

{Object} getProjectData()

Defined in: data-manager.js.
Parameters:
{String} arguments.created
{String} arguments.label
{Integer} arguments.projectId
{Object} arguments.toolsets
{Object} arguments.worksets
Returns:
{Object} The data associated with the project for this session

{String} getProjectId()
Returns the project ID for this workset.
Defined in: data-manager.js.
Returns:
{String} The project ID

getQueryParam()
Return the query parameter
Defined in: data-manager.js.

{Array} getResults(type)
Gets results of a particular type.
Defined in: data-manager.js.
Parameters:
{String} type
Can be either: 'feature', 'tree', 'prediction'
Returns:
{Array} The filtered results

getResultStore()

Defined in: data-manager.js.

{String} getResultSummary()
Returns the result summary.
Defined in: data-manager.js.
Returns:
{String} The result summary

{Array} getTermsForChunk(chunkId)
Returns the terms/features found in a specific chunk.
Defined in: data-manager.js.
Parameters:
{String} chunkId
The chunk ID
Returns:
{Array} An array of terms

{String} getToolsetId()
Returns the toolset ID for this toolset.
Defined in: data-manager.js.
Returns:
{String} The toolset ID

{Object} getWorklist()
Returns the worklist for this workset.
Defined in: data-manager.js.
Returns:
{Object} The worklist

{Object} getWorkset()
Returns the current workset, including all the relevant properties. Currently some properties are being adapted for use with Nora services: e.g. chunk user ratings are returned as the trainingListArray/trainingListRatingArray
Defined in: data-manager.js.
Returns:
{Object} The workset object

{String} getWorksetId()
Returns the workset ID for this workset.
Defined in: data-manager.js.
Returns:
{String} The workset ID

{String} getWorksetLabel()
Returns the workset label (longer form) for this workset.
Defined in: data-manager.js.
Returns:
{String} The workset label

{String} getWorksetName()
Returns the name of this workset.
Defined in: data-manager.js.
Returns:
{String} The workset name

growl(title, msg, target)

Defined in: messenger.js.
Parameters:
title
msg
target

{Function} handle()
Overwrite to handle Monk events.

handleResponse(response)

Defined in: data.js.
Parameters:
response

init(paging)

Defined in: paging_toolbar_improvements.js.
Parameters:
paging

initComponent()

Defined in: paging_toolbar_improvements.js.

initializeProgressDialog(cachedData)
Methods for running analyses
Defined in: data-manager.js.
Parameters:
cachedData

{Function} isVisible()
Is this component's panel is currently being displayed? Typically used to determine if the component should handle certain events.
Returns:
Boolean

{Boolean} isWorksetUnsaved()
Returns true if there is unsaved workset data.
Defined in: data-manager.js.
Returns:
{Boolean} Is there unsaved workset data.

{Boolean} isWorksetValid()
Checks for a minimum of 2 ratings in the workset, (before running an analysis).
Defined in: data-manager.js.
Returns:
{Boolean} True if the workset is valid.

load(params, reader, callback, scope, arg)

Defined in: paging_memory_proxy.js.
Parameters:
params
reader
callback
scope
arg

loadOrSet(num)

Defined in: paging_toolbar_improvements.js.
Parameters:
num

loadWorkset(worksetId)

Defined in: WorksetSelector.js.
Parameters:
worksetId

moveFirst()

Defined in: paging_toolbar_improvements.js.

moveLast()

Defined in: paging_toolbar_improvements.js.

moveNext()

Defined in: paging_toolbar_improvements.js.

movePrevious()

Defined in: paging_toolbar_improvements.js.

notify(workbenchEvent, resultsData)
Notify the component manager of this event.
Parameters:
{Workbench.event.Event} workbenchEvent
The Workbench event that has occured
{Workbench.data.DataStore} resultsData Optional
Data attached to this event

onInitView(paging)

Defined in: paging_toolbar_improvements.js.
Parameters:
paging

onLoad(store, r, o)

Defined in: paging_toolbar_improvements.js.
Parameters:
store
r
o

onLoadError()

Defined in: paging_toolbar_improvements.js.

onPageSizeChanged(combo)

Defined in: paging_toolbar_improvements.js.
Parameters:
combo

onPagingKeydown(e)

Defined in: paging_toolbar_improvements.js.
Parameters:
e

onRender(ct, position)

Defined in: paging_toolbar_improvements.js.
Parameters:
ct
position

processChunk(chunk)
Called when a user checks a chunk. Adds/removes the chunk to the worklist based on the checked attribute.
Defined in: data-manager.js.
Parameters:
{Object} chunk
The chunk to be processed

{Object} processResults(instanceId, resultsArray)
Processes results data and sets it in this DataManager.
Defined in: data-manager.js.
Parameters:
{String} instanceId
The instance ID for the analysis which produced these results.
{Array} resultsArray
The array of results to process.
{Array} arguments.tempResults
An array of processed temp results (for saving later).
{String} arguments.resultsProcessed
A string describing the types of results processed.
Returns:
{Object}

processStatus(data)

Defined in: data-manager.js.
Parameters:
data

progress(title, msg, progressTxt, target)

Defined in: messenger.js.
Parameters:
title
msg
progressTxt
target

prompt(title, msg, target)

Defined in: messenger.js.
Parameters:
title
msg
target

readPage()

Defined in: paging_toolbar_improvements.js.

refresh()

Defined in: paging_toolbar_improvements.js.

remove(data)

Defined in: paging_memory_proxy.js.
Parameters:
data

renderResults(numColumns, columnHeight)

Defined in: WorksetSelector.js.
Parameters:
numColumns
columnHeight

renderWorksets(numColumns, columnHeight)

Defined in: WorksetSelector.js.
Parameters:
numColumns
columnHeight

request(o)

Defined in: data.js.
Parameters:
o

reset(resetProject)
Resets everything back to the initial values.
Defined in: data-manager.js.
Parameters:
{Boolean} resetProject
True to reset the project as well.

resetChunkSimilar()
Reset the chunkList
Defined in: data-manager.js.

resetQueryParam()

Defined in: data-manager.js.

resetResults()
Returns the results to their initial state
Defined in: data-manager.js.

resetWorkset()
Returns the workset to its initial state
Defined in: data-manager.js.

runAnalysis()

Defined in: data-manager.js.

selectResult(key)

Defined in: WorksetSelector.js.
Parameters:
key

selectWorkset(worksetId)

Defined in: WorksetSelector.js.
Parameters:
worksetId

setActivePage(page)

Defined in: paging_toolbar_improvements.js.
Parameters:
page

setChunkSimilar()
Store the list of chunks retrieved as a result of a search/browse or Similarity search
Defined in: data-manager.js.
Parameters:
{String array}

setCurrentChunk(chunk)
Sets the chunk currently being viewed.
Defined in: data-manager.js.
Parameters:
chunk

setDecisionTree(decisionTree)
Set the decision tree.
Defined in: data-manager.js.
Parameters:
{String} decisionTree
A decision tree string

setDecisionTreeImage(decisionTree)
Set the decision tree summary.
Defined in: data-manager.js.
Parameters:
{String} decisionTree
A decision tree string

setDecisionTreeSummary(decisionTree)
Set the decision tree summary.
Defined in: data-manager.js.
Parameters:
{String} decisionTree
A decision tree string

setFeature(feature)
Sets the feature for this workset. Possible values are: 'contents', 'twogram_contents' and 'threegram_contents'.
Defined in: data-manager.js.
Parameters:
{String} feature
The feature

setFeatureList(featureList)
Set the feature list for this workset.
Defined in: data-manager.js.
Parameters:
{Array} featureList
An array of features

setInstanceId(instanceId)
Sets the instance ID for the most recent analysis result.
Defined in: data-manager.js.
Parameters:
{String} instanceId
The instance ID

setItinerary(itinerary)
Sets the itinerary for this workset. Possible values are: 'MonkNaiveBayes', and 'MonkDTree'.
Defined in: data-manager.js.
Parameters:
{String} itinerary
The itinerary

setPageSize(size)

Defined in: paging_toolbar_improvements.js.
Parameters:
size

setProjectData(projectData)
Set the project data for this session
Defined in: data-manager.js.
Parameters:
{Object} projectData
{String} projectData.created
{String} projectData.label
{Integer} projectData.projectId
{Object} projectData.toolsets
{Object} projectData.worksets

setProjectId(projectId)
Sets the project ID for this workset.
Defined in: data-manager.js.
Parameters:
{String} projectId
The project ID

setResultSummary(A)
Set the result summary.
Defined in: data-manager.js.
Parameters:
{String} A
string describing the result.

setSearchQueryParam(queryParams)
Set query param
Defined in: data-manager.js.
Parameters:
queryParams

setSimilarQueryParam(queryParam, append)
Set similar search query param
Defined in: data-manager.js.
Parameters:
queryParam
append

setTimer(token)

Defined in: data-manager.js.
Parameters:
token

setToolsetId(toolsetId)
Sets the toolset ID for this toolset.
Defined in: data-manager.js.
Parameters:
{String} toolsetId
The toolset ID

setupTextBox()

Defined in: paging_toolbar_improvements.js.

setUserRatings(trainingList, trainingListRating)
Sets the training list for this workset. It accepts 2 comma-separated strings (chunk IDs and user ratings) whose items should have a 1 to 1 relation and be in the same order. Currently we're storing trainingList values in the worklist as userRating property
Defined in: data-manager.js.
Parameters:
{String} trainingList
The chunk IDs
{String} trainingListRating
The ratings for each chunk

setWorklist(worklist, worklistRating, confidence)
Sets the worklist for this workset. It accepts 3 arrays (chunk IDs, system ratings, and rating confidence) whose items should have a 1 to 1 relation and be in the same order.
Defined in: data-manager.js.
Parameters:
{Array} worklist
The chunk IDs
{Array} worklistRating Optional
The ratings for each chunk
{Array} confidence Optional
The confidence for each predicted rating

setWorkset(workset)
Loads a workset into the data manager. Then gets the labels from the server.
Defined in: data-manager.js.
Parameters:
{Object} workset
{String} workset.label
{Integer} workset.id
{Integer} workset.projectId
{String} workset.trainingList
{String} workset.trainingListRating
{String} workset.workList
{String} workset.workListRating
{String} workset.itinerary

setWorksetId(worksetId)
Sets the workset ID for this workset.
Defined in: data-manager.js.
Parameters:
{String} worksetId
The workset ID

setWorksetName(worksetName)
Sets the name of this workset.
Defined in: data-manager.js.
Parameters:
{String} worksetName
The name of the workset

setWorksetQueryParam(id, append)
This query will retrieve the workset information from the middleware and update the common work store that is used by the result summary tool
Defined in: data-manager.js.
Parameters:
id
append

show(config, target)

Defined in: messenger.js.
Parameters:
config
target

showJobsWindow()

Defined in: WorksetSelector.js.

unbind(store)

Defined in: paging_toolbar_improvements.js.
Parameters:
store

update(newData, append)

Defined in: paging_memory_proxy.js.
Parameters:
newData
append

updateInfo()

Defined in: paging_toolbar_improvements.js.

updateProgress(data)

Defined in: data-manager.js.
Parameters:
data

updateProjectDataWorkset()
Update the workset in projectData with the values from the currently loaded workset.
Defined in: data-manager.js.

updateRecord(recordId, attributeObject)

Defined in: paging_memory_proxy.js.
Parameters:
recordId
attributeObject

useJs()

Defined in: messenger.js.

wait(title, msg, target)

Defined in: messenger.js.
Parameters:
title
msg
target

©2009
Documentation generated by JsDoc Toolkit 2.0.2 on Wed May 06 2009 08:41:32 GMT-0500 (CDT)