Mantid
Loading...
Searching...
No Matches
Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
Mantid::API::WorkspaceProperty< TYPE > Class Template Reference

A property class for workspaces. More...

#include <WorkspaceProperty.h>

Inheritance diagram for Mantid::API::WorkspaceProperty< TYPE >:
Mantid::Kernel::PropertyWithValue< TYPE > Mantid::API::IWorkspaceProperty Mantid::Kernel::Property

Public Member Functions

std::vector< std::string > allowedValues () const override
 Returns the current contents of the AnalysisDataService for input workspaces.
 
WorkspaceProperty< TYPE > * clone () const override
 'Virtual copy constructor'
 
const Kernel::PropertyHistory createHistory () const override
 Create a history record.
 
std::string getDefault () const override
 Get the value the property was initialised with -its default value.
 
Workspace_sptr getWorkspace () const override
 Get a pointer to the workspace.
 
bool isDefault () const override
 Indicates if the object is still pointing to the same workspace.
 
bool isLocking () const override
 Does the workspace need to be locked before starting an algorithm?
 
bool isOptional () const override
 Is the workspace property optional.
 
std::string isValid () const override
 Checks whether the entered workspace is valid.
 
bool isValueSerializable () const override
 Returns true if the workspace is in the ADS or there is none.
 
WorkspacePropertyoperator+= (Kernel::Property const *) override
 Add the value of another property.
 
WorkspacePropertyoperator= (const std::shared_ptr< TYPE > &value) override
 Bring in the PropertyWithValue assignment operator explicitly (avoids VSC++ warning)
 
WorkspacePropertyoperator= (const WorkspaceProperty &right)
 Copy assignment operator.
 
std::string setDataItem (const std::shared_ptr< Kernel::DataItem > &value) override
 Set a value from a data item.
 
void setPropertyMode (const PropertyMode::Type &optional) override
 Set the property mode of the property e.g.
 
std::string setValue (const std::string &value) override
 Set the name of the workspace.
 
std::string setValueFromJson (const Json::Value &value) override
 Set the name of the workspace from a Json::Value object Also tries to retrieve it from the AnalysisDataService.
 
bool store () override
 If this is an output workspace, store it into the AnalysisDataService.
 
std::string value () const override
 Get the name of the workspace.
 
Json::Value valueAsJson () const override
 
 WorkspaceProperty (const std::string &name, const std::string &wsName, const unsigned int direction, const Kernel::IValidator_sptr &validator=Kernel::IValidator_sptr(new Kernel::NullValidator))
 Constructor.
 
 WorkspaceProperty (const std::string &name, const std::string &wsName, const unsigned int direction, const PropertyMode::Type optional, const Kernel::IValidator_sptr &validator=Kernel::IValidator_sptr(new Kernel::NullValidator))
 Constructor.
 
 WorkspaceProperty (const std::string &name, const std::string &wsName, const unsigned int direction, const PropertyMode::Type optional, const LockMode::Type locking, const Kernel::IValidator_sptr &validator=Kernel::IValidator_sptr(new Kernel::NullValidator))
 Constructor.
 
 WorkspaceProperty (const WorkspaceProperty &right)
 Copy constructor, the default name stored in the new object is the same as the default name from the original object.
 
- Public Member Functions inherited from Mantid::Kernel::PropertyWithValue< TYPE >
std::vector< std::string > allowedValues () const override
 Returns the set of valid values for this property, if such a set exists.
 
PropertyWithValue< TYPE > * clone () const override
 'Virtual copy constructor'
 
std::string getDefault () const override
 Get the value the property was initialised with -its default value.
 
IValidator_sptr getValidator () const
 Returns the validator as a constant variable so it cannot be changed.
 
bool isDefault () const override
 Indicates if the property's value is the same as it was when it was set N.B.
 
bool isMultipleSelectionAllowed () override
 Returns the set of valid values for this property, if such a set exists.
 
std::string isValid () const override
 Check the value chosen for the property is OK, unless overidden it just calls the validator's isValid() N.B.
 
virtual operator const TYPE & () const
 Allows you to get the value of the property simply by typing its name.
 
bool operator!= (const PropertyWithValue< TYPE > &rhs) const
 Deep comparison (not equal).
 
virtual const TYPEoperator() () const
 Allows you to get the value of the property via an expression like myProperty()
 
PropertyWithValueoperator+= (Property const *right) override
 Add the value of another property.
 
PropertyWithValueoperator= (const PropertyWithValue &right)
 Copy assignment operator assigns only the value and the validator not the name, default (initial) value, etc.
 
virtual PropertyWithValueoperator= (const TYPE &value)
 Assignment operator.
 
bool operator== (const PropertyWithValue< TYPE > &rhs) const
 Deep comparison.
 
 PropertyWithValue ()=delete
 
 PropertyWithValue (const PropertyWithValue< TYPE > &right)
 Copy constructor Note the default value of the copied object is the initial value of original.
 
 PropertyWithValue (const std::string &name, const TYPE &defaultValue, const std::string &defaultValueStr, IValidator_sptr validator, const unsigned int direction)
 Constructor.
 
 PropertyWithValue (std::string name, TYPE defaultValue, const unsigned int direction)
 Constructor.
 
 PropertyWithValue (std::string name, TYPE defaultValue, IValidator_sptr validator=IValidator_sptr(new NullValidator), const unsigned int direction=Direction::Input)
 Constructor.
 
virtual void replaceValidator (IValidator_sptr newValidator)
 Replace the current validator with the given one.
 
MANTID_KERNEL_DLL void saveProperty (Nexus::File *file)
 
MANTID_KERNEL_DLL void saveProperty (Nexus::File *file)
 
MANTID_KERNEL_DLL void saveProperty (Nexus::File *file)
 
MANTID_KERNEL_DLL void saveProperty (Nexus::File *file)
 
MANTID_KERNEL_DLL void saveProperty (Nexus::File *file)
 
MANTID_KERNEL_DLL void saveProperty (Nexus::File *file)
 
MANTID_KERNEL_DLL void saveProperty (Nexus::File *file)
 
MANTID_KERNEL_DLL void saveProperty (Nexus::File *file)
 
MANTID_KERNEL_DLL void saveProperty (Nexus::File *file)
 
void saveProperty (Nexus::File *file) override
 
std::string setDataItem (const std::shared_ptr< DataItem > &data) override
 Set a property value via a DataItem.
 
std::string setValue (const std::string &value) override
 Set the value of the property from a string representation.
 
std::string setValueFromJson (const Json::Value &value) override
 Set the value of the property from a Json representation.
 
int size () const override
 Get the size of the property.
 
std::string value () const override
 Get the value of the property as a string.
 
Json::Value valueAsJson () const override
 Attempt to construct a Json::Value object from the plain value.
 
std::string valueAsPrettyStr (const size_t maxLength=0, const bool collapseLists=true) const override
 Get the value of the property as a string.
 
- Public Member Functions inherited from Mantid::Kernel::Property
bool autoTrim () const
 Returns if the property is set to automatically trim string unput values of whitespace.
 
void clearSettings ()
 Deletes the PropertySettings object contained.
 
void createTemporaryValue ()
 Create a temporary value for this property.
 
unsigned int direction () const
 returns the direction of the property
 
bool disableReplaceWSButton () const
 Returns if the property is set to disable the creation of the "Replace Workspace" button.
 
const std::string & documentation () const
 Get the property's documentation string.
 
const std::string & getGroup ()
 
virtual size_t getMemorySize () const
 
IPropertySettingsgetSettings ()
 
const IPropertySettingsgetSettings () const
 
bool hasTemporaryValue () const
 Property is using a temporary value for this property.
 
bool isDynamicDefault () const
 Returns a flag indicating that the property's value has been set programmatically, for example, if the property has a default value which depends on the value of an upstream property.
 
virtual Propertymerge (Property *)
 Just returns the property (*this) unless overridden.
 
const std::string & name () const
 Get the property's name.
 
bool remember () const
 Whether to save input values.
 
void setAutoTrim (const bool &setting)
 Sets if the property is set to automatically trim string unput values of whitespace.
 
void setDisableReplaceWSButton (const bool &disable)
 Sets the property to disable the creation of the "Replace Workspace" button.
 
void setDocumentation (const std::string &documentation)
 Sets the user level description of the property.
 
void setGroup (const std::string &group)
 Set the group this property belongs to.
 
void setIsDynamicDefault (const bool &flag)
 Set or clear the flag indicating whether or not the property's value has been set programmatically.
 
void setName (const std::string &name)
 Set the property's name.
 
void setRemember (bool)
 Set wheter to remeber this property input.
 
void setSettings (std::unique_ptr< IPropertySettings > settings)
 Set the PropertySettings object.
 
virtual void setUnits (const std::string &unit)
 Sets the units of the property, as a string.
 
const std::string type () const
 Returns the type of the property as a string.
 
const std::type_info * type_info () const
 Get the property type_info.
 
virtual const std::string & units () const
 Returns the units of the property, if any, as a string.
 
virtual ~Property ()
 Virtual destructor.
 
- Public Member Functions inherited from Mantid::API::IWorkspaceProperty
virtual ~IWorkspaceProperty ()=default
 Virtual destructor.
 

Private Member Functions

void clear () override
 Reset the pointer to the workspace.
 
std::string isOptionalWs () const
 Checks whether the entered workspace (that by this point we've found is not in the ADS) is actually an optional workspace and so still valid.
 
std::string isValidGroup (const std::shared_ptr< WorkspaceGroup > &wsGroup) const
 Checks whether the entered workspace group is valid.
 
std::string isValidOutputWs () const
 Checks whether the entered output workspace is valid.
 
void retrieveWorkspaceFromADS ()
 Attempts to retreive the data from the ADS if the data is not foung the internal pointer is set to null.
 

Private Attributes

std::string m_initialWSName
 The name of the workspace that the this this object was created for.
 
LockMode::Type m_locking
 A flag indicating whether the workspace should be read or write-locked when an algorithm begins.
 
PropertyMode::Type m_optional
 A flag indicating whether the property should be considered optional.
 
std::string m_workspaceName
 The name of the workspace (as used by the AnalysisDataService)
 

Static Private Attributes

static Kernel::Logger g_log
 for access to logging streams
 

Additional Inherited Members

- Protected Member Functions inherited from Mantid::Kernel::Property
 Property (const Property &right)
 Copy constructor.
 
 Property (std::string name, const std::type_info &type, const unsigned int &direction=Direction::Input)
 Constructor.
 
- Protected Attributes inherited from Mantid::Kernel::PropertyWithValue< TYPE >
TYPE m_initialValue
 the property's default value which is also its initial value
 
TYPE m_value
 The value of the property.
 
- Protected Attributes inherited from Mantid::Kernel::Property
std::string m_name
 The name of the property.
 

Detailed Description

template<typename TYPE = MatrixWorkspace>
class Mantid::API::WorkspaceProperty< TYPE >

A property class for workspaces.

Inherits from PropertyWithValue, with the value being a pointer to the workspace type given to the WorkspaceProperty constructor. This kind of property also holds the name of the workspace (as used by the AnalysisDataService) and an indication of whether it is an input or output to an algorithm (or both).

The pointers to the workspaces are fetched from the ADS when the properties are validated (i.e. when the PropertyManager::validateProperties() method calls isValid() ). Pointers to output workspaces are also fetched, if they exist, and can then be used within an algorithm. (An example of when this might be useful is if the user wants to write the output into the same workspace as is used for input - this avoids creating a new workspace and the overwriting the old one at the end.)

Author
Russell Taylor, Tessella Support Services plc
Date
10/12/2007

Definition at line 51 of file WorkspaceProperty.h.

Constructor & Destructor Documentation

◆ WorkspaceProperty() [1/4]

template<typename TYPE >
Mantid::API::WorkspaceProperty< TYPE >::WorkspaceProperty ( const std::string &  name,
const std::string &  wsName,
const unsigned int  direction,
const Kernel::IValidator_sptr validator = Kernel::IValidator_sptr(new Kernel::NullValidator) 
)
explicit

Constructor.

Sets the property and workspace names but initializes the workspace pointer to null.

Parameters
name:: The name to assign to the property
wsName:: The name of the workspace
direction:: Whether this is a Direction::Input, Direction::Output or Direction::InOut (Input & Output) workspace
validator:: The (optional) validator to use for this property
Exceptions
std::out_of_rangeif the direction argument is not a member of the Direction enum (i.e. 0-2)

Definition at line 34 of file WorkspaceProperty.hxx.

◆ WorkspaceProperty() [2/4]

template<typename TYPE >
Mantid::API::WorkspaceProperty< TYPE >::WorkspaceProperty ( const std::string &  name,
const std::string &  wsName,
const unsigned int  direction,
const PropertyMode::Type  optional,
const Kernel::IValidator_sptr validator = Kernel::IValidator_sptr(new Kernel::NullValidator) 
)
explicit

Constructor.

Sets the property and workspace names but initializes the workspace pointer to null.

Parameters
name:: The name to assign to the property
wsName:: The name of the workspace
direction:: Whether this is a Direction::Input, Direction::Output or Direction::InOut (Input & Output) workspace
optional:: If true then the property is optional
validator:: The (optional) validator to use for this property
Exceptions
std::out_of_rangeif the direction argument is not a member of the Direction enum (i.e. 0-2)

Definition at line 53 of file WorkspaceProperty.hxx.

◆ WorkspaceProperty() [3/4]

template<typename TYPE >
Mantid::API::WorkspaceProperty< TYPE >::WorkspaceProperty ( const std::string &  name,
const std::string &  wsName,
const unsigned int  direction,
const PropertyMode::Type  optional,
const LockMode::Type  locking,
const Kernel::IValidator_sptr validator = Kernel::IValidator_sptr(new Kernel::NullValidator) 
)
explicit

Constructor.

Sets the property and workspace names but initializes the workspace pointer to null.

Parameters
name:: The name to assign to the property
wsName:: The name of the workspace
direction:: Whether this is a Direction::Input, Direction::Output or Direction::InOut (Input & Output) workspace
optional:: A boolean indicating whether the property is mandatory or not. Only matters for input properties
locking:: A boolean indicating whether the workspace should read or write-locked when an algorithm begins. Default=true.
validator:: The (optional) validator to use for this property
Exceptions
std::out_of_rangeif the direction argument is not a member of the Direction enum (i.e. 0-2)

Definition at line 76 of file WorkspaceProperty.hxx.

◆ WorkspaceProperty() [4/4]

template<typename TYPE >
Mantid::API::WorkspaceProperty< TYPE >::WorkspaceProperty ( const WorkspaceProperty< TYPE > &  right)

Copy constructor, the default name stored in the new object is the same as the default name from the original object.

Definition at line 85 of file WorkspaceProperty.hxx.

Member Function Documentation

◆ allowedValues()

template<typename TYPE >
std::vector< std::string > Mantid::API::WorkspaceProperty< TYPE >::allowedValues ( ) const
overridevirtual

Returns the current contents of the AnalysisDataService for input workspaces.

For output workspaces, an empty set is returned

Returns
set of objects in AnalysisDataService

Reimplemented from Mantid::Kernel::Property.

Definition at line 278 of file WorkspaceProperty.hxx.

References Mantid::Kernel::Direction::InOut, Mantid::Kernel::Direction::Input, and Mantid::Kernel::Sorted.

◆ clear()

template<typename TYPE >
void Mantid::API::WorkspaceProperty< TYPE >::clear ( )
overrideprivatevirtual

Reset the pointer to the workspace.

Implements Mantid::API::IWorkspaceProperty.

Definition at line 443 of file WorkspaceProperty.hxx.

References m_value.

◆ clone()

template<typename TYPE >
WorkspaceProperty< TYPE > * Mantid::API::WorkspaceProperty< TYPE >::clone ( ) const
overridevirtual

'Virtual copy constructor'

Implements Mantid::Kernel::Property.

Definition at line 120 of file WorkspaceProperty.hxx.

◆ createHistory()

template<typename TYPE >
const Kernel::PropertyHistory Mantid::API::WorkspaceProperty< TYPE >::createHistory ( ) const
overridevirtual

Create a history record.

Returns
A populated PropertyHistory for this class

Reimplemented from Mantid::Kernel::Property.

Definition at line 304 of file WorkspaceProperty.hxx.

References m_value, and name.

◆ getDefault()

template<typename TYPE >
std::string Mantid::API::WorkspaceProperty< TYPE >::getDefault ( ) const
overridevirtual

Get the value the property was initialised with -its default value.

Returns
The default value

Implements Mantid::Kernel::Property.

Definition at line 144 of file WorkspaceProperty.hxx.

◆ getWorkspace()

template<typename TYPE >
Workspace_sptr Mantid::API::WorkspaceProperty< TYPE >::getWorkspace ( ) const
overridevirtual

Get a pointer to the workspace.

Implements Mantid::API::IWorkspaceProperty.

Definition at line 350 of file WorkspaceProperty.hxx.

Referenced by Mantid::API::Algorithm::checkGroups().

◆ isDefault()

template<typename TYPE >
bool Mantid::API::WorkspaceProperty< TYPE >::isDefault ( ) const
overridevirtual

Indicates if the object is still pointing to the same workspace.

Returns
true if the value is the same as the initial value or false otherwise

Implements Mantid::Kernel::Property.

Definition at line 257 of file WorkspaceProperty.hxx.

References m_value.

◆ isLocking()

template<typename TYPE >
bool Mantid::API::WorkspaceProperty< TYPE >::isLocking ( ) const
overridevirtual

Does the workspace need to be locked before starting an algorithm?

Returns
true (default) if the workspace will be locked

Implements Mantid::API::IWorkspaceProperty.

Definition at line 271 of file WorkspaceProperty.hxx.

References Mantid::API::LockMode::Lock.

◆ isOptional()

template<typename TYPE >
bool Mantid::API::WorkspaceProperty< TYPE >::isOptional ( ) const
overridevirtual

Is the workspace property optional.

Returns
true if the workspace can be blank

Implements Mantid::API::IWorkspaceProperty.

Definition at line 266 of file WorkspaceProperty.hxx.

References Mantid::API::PropertyMode::Optional.

◆ isOptionalWs()

template<typename TYPE >
std::string Mantid::API::WorkspaceProperty< TYPE >::isOptionalWs ( ) const
private

Checks whether the entered workspace (that by this point we've found is not in the ADS) is actually an optional workspace and so still valid.

Returns
A user level description of the problem or "" if it is valid.

Definition at line 426 of file WorkspaceProperty.hxx.

References error, and value.

◆ isValid()

template<typename TYPE >
std::string Mantid::API::WorkspaceProperty< TYPE >::isValid ( ) const
overridevirtual

Checks whether the entered workspace is valid.

To be valid, in addition to satisfying the conditions of any validators, an output property must not have an empty name and an input one must point to a workspace of the correct type.

Returns
A user level description of the problem or "" if it is valid.

Reimplemented from Mantid::Kernel::Property.

Definition at line 212 of file WorkspaceProperty.hxx.

References error, Mantid::Kernel::Direction::InOut, Mantid::Kernel::Direction::Input, m_value, Mantid::Kernel::Direction::Output, and value.

◆ isValidGroup()

template<typename TYPE >
std::string Mantid::API::WorkspaceProperty< TYPE >::isValidGroup ( const std::shared_ptr< WorkspaceGroup > &  wsGroup) const
private

Checks whether the entered workspace group is valid.

To be valid all members of the group have to be valid.

Parameters
wsGroup:: the WorkspaceGroup of which to check the validity
Returns
A user level description of the problem or "" if it is valid.

Definition at line 358 of file WorkspaceProperty.hxx.

References Mantid::Kernel::Logger::debug(), error, Mantid::API::g_log, and Mantid::API::WorkspaceProperty< TYPE >::setValue().

◆ isValidOutputWs()

template<typename TYPE >
std::string Mantid::API::WorkspaceProperty< TYPE >::isValidOutputWs ( ) const
private

Checks whether the entered output workspace is valid.

To be valid the only thing it needs is a name that is allowed by the ADS,

See also
AnalysisDataServiceImpl
Returns
A user level description of the problem or "" if it is valid.

Definition at line 406 of file WorkspaceProperty.hxx.

References error, and value.

◆ isValueSerializable()

template<typename TYPE >
bool Mantid::API::WorkspaceProperty< TYPE >::isValueSerializable ( ) const
overridevirtual

Returns true if the workspace is in the ADS or there is none.

Returns
true if the string returned by value() is valid

Reimplemented from Mantid::Kernel::Property.

Definition at line 137 of file WorkspaceProperty.hxx.

References m_value.

◆ operator+=()

template<typename TYPE >
WorkspaceProperty< TYPE > & Mantid::API::WorkspaceProperty< TYPE >::operator+= ( Kernel::Property const *  )
overridevirtual

Add the value of another property.

Implements Mantid::Kernel::Property.

Definition at line 115 of file WorkspaceProperty.hxx.

◆ operator=() [1/2]

template<typename TYPE >
WorkspaceProperty< TYPE > & Mantid::API::WorkspaceProperty< TYPE >::operator= ( const std::shared_ptr< TYPE > &  value)
override

Bring in the PropertyWithValue assignment operator explicitly (avoids VSC++ warning)

Parameters
value:: The value to set to
Returns
assigned PropertyWithValue

Definition at line 104 of file WorkspaceProperty.hxx.

References Mantid::Kernel::Direction::Input, and value.

◆ operator=() [2/2]

template<typename TYPE >
WorkspaceProperty< TYPE > & Mantid::API::WorkspaceProperty< TYPE >::operator= ( const WorkspaceProperty< TYPE > &  right)

Copy assignment operator.

Only copies the value (i.e. the pointer to the workspace)

Definition at line 91 of file WorkspaceProperty.hxx.

References right.

◆ retrieveWorkspaceFromADS()

template<typename TYPE >
void Mantid::API::WorkspaceProperty< TYPE >::retrieveWorkspaceFromADS ( )
private

Attempts to retreive the data from the ADS if the data is not foung the internal pointer is set to null.

Definition at line 450 of file WorkspaceProperty.hxx.

References m_value.

◆ setDataItem()

template<typename TYPE >
std::string Mantid::API::WorkspaceProperty< TYPE >::setDataItem ( const std::shared_ptr< Kernel::DataItem > &  value)
overridevirtual

Set a value from a data item.

Parameters
value:: A shared pointer to a DataItem. If it is of the correct type it will set validated, if not the property's value will be cleared.
Returns

Implements Mantid::Kernel::Property.

Definition at line 182 of file WorkspaceProperty.hxx.

References Mantid::Kernel::Direction::Input, m_value, Mantid::Kernel::Direction::Output, and value.

◆ setPropertyMode()

template<typename TYPE >
void Mantid::API::WorkspaceProperty< TYPE >::setPropertyMode ( const PropertyMode::Type optional)
overridevirtual

Set the property mode of the property e.g.

Mandatory or Optional

Parameters
optional:: Property mode Mandatory or Optional

Implements Mantid::API::IWorkspaceProperty.

Definition at line 201 of file WorkspaceProperty.hxx.

◆ setValue()

template<typename TYPE >
std::string Mantid::API::WorkspaceProperty< TYPE >::setValue ( const std::string &  value)
overridevirtual

Set the name of the workspace.

Also tries to retrieve it from the AnalysisDataService.

Parameters
value:: The new name for the workspace
Returns
An empty string indicating success otherwise a string containing the error

Implements Mantid::Kernel::Property.

Definition at line 152 of file WorkspaceProperty.hxx.

References value.

Referenced by Mantid::API::WorkspaceProperty< TYPE >::isValidGroup().

◆ setValueFromJson()

template<typename TYPE >
std::string Mantid::API::WorkspaceProperty< TYPE >::setValueFromJson ( const Json::Value &  value)
overridevirtual

Set the name of the workspace from a Json::Value object Also tries to retrieve it from the AnalysisDataService.

Parameters
value:: The new name for the workspace
Returns
An empty string indicating success otherwise a string containing the error

Implements Mantid::Kernel::Property.

Definition at line 168 of file WorkspaceProperty.hxx.

References value.

◆ store()

template<typename TYPE >
bool Mantid::API::WorkspaceProperty< TYPE >::store ( )
overridevirtual

If this is an output workspace, store it into the AnalysisDataService.

Returns
True if the workspace is an output workspace and has been stored
Exceptions
std::runtime_errorif unable to store the workspace successfully

Implements Mantid::API::IWorkspaceProperty.

Definition at line 329 of file WorkspaceProperty.hxx.

◆ value()

template<typename TYPE >
std::string Mantid::API::WorkspaceProperty< TYPE >::value ( ) const
overridevirtual

Get the name of the workspace.

Returns
The workspace's name

Implements Mantid::Kernel::Property.

Definition at line 127 of file WorkspaceProperty.hxx.

Referenced by Mantid::CurveFitting::Algorithms::PlotPeakByLogValue::getMinimizerString().

◆ valueAsJson()

template<typename TYPE >
Json::Value Mantid::API::WorkspaceProperty< TYPE >::valueAsJson ( ) const
overridevirtual
Returns
The name of the workspace encode as a Json::Value

Implements Mantid::Kernel::Property.

Definition at line 132 of file WorkspaceProperty.hxx.

References value.

Member Data Documentation

◆ g_log

template<typename TYPE >
Kernel::Logger Mantid::API::WorkspaceProperty< TYPE >::g_log
staticprivate

for access to logging streams

Definition at line 131 of file WorkspaceProperty.h.

◆ m_initialWSName

template<typename TYPE = MatrixWorkspace>
std::string Mantid::API::WorkspaceProperty< TYPE >::m_initialWSName
private

The name of the workspace that the this this object was created for.

Definition at line 122 of file WorkspaceProperty.h.

◆ m_locking

template<typename TYPE = MatrixWorkspace>
LockMode::Type Mantid::API::WorkspaceProperty< TYPE >::m_locking
private

A flag indicating whether the workspace should be read or write-locked when an algorithm begins.

Default=true.

Definition at line 128 of file WorkspaceProperty.h.

◆ m_optional

template<typename TYPE = MatrixWorkspace>
PropertyMode::Type Mantid::API::WorkspaceProperty< TYPE >::m_optional
private

A flag indicating whether the property should be considered optional.

Only matters for input workspaces

Definition at line 125 of file WorkspaceProperty.h.

◆ m_workspaceName

template<typename TYPE = MatrixWorkspace>
std::string Mantid::API::WorkspaceProperty< TYPE >::m_workspaceName
private

The name of the workspace (as used by the AnalysisDataService)

Definition at line 120 of file WorkspaceProperty.h.


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