A container for all resources associated with an analytic project. More...
#include <Study.h>
Public Types | |
enum | Type { CLASS, RANK, NUMBER, CHANCE } |
Indicates the quality of the predictands associated with subjects in the study. More... | |
enum | Status { RUNNING, STANDBY, STOPPED } |
Describes the state of the study, whether it is running, on standby, or stopped. More... | |
enum | Visibility { PRIVATE, PUBLIC } |
Tells whether unidentified users can get estimated predictands from the model of the study. More... | |
Public Member Functions | |
Study () | |
Initializes a newly created Study object with default attributes. | |
Study (const std::string &studyName, Type type, Status status, Visibility visibility) | |
Initializes a newly created Study object with attributes specified by the input parameters. | |
Study (const Study &rhs) | |
Copy constructor - initializes a newly created Study object with a copy of another Study object. | |
virtual | ~Study () |
Destructor - destroy a Study object. | |
Study & | operator= (const Study &rhs) |
Assignment operator - assign one Study to another. | |
bool | operator== (const Study &rhs) const |
Equality operator - compare two Study for equality. | |
bool | operator!= (const Study &rhs) const |
Inequality operator - compare two Study for inequality. | |
void | initStudy () |
Initialize the data members of a study. | |
void | setStudyIdentifier (const std::string &id) |
Set the study identifier. | |
std::string | getStudyIdentifier () const |
Return the study identifier. | |
void | setStudyName (const std::string &name) |
Set the study name. | |
std::string | getStudyName () const |
Return the study name. | |
void | setStudyLocation (const std::string &loc) |
Set the study location. | |
std::string | getStudyLocation () const |
Return the study location. | |
void | setType (Type t) |
Set the study type. | |
Type | getType () const |
Return the study type. | |
void | setStatus (Status s) |
Set the study status. | |
Status | getStatus () const |
Return the study status. | |
void | setVisibility (Visibility v) |
Set the study visibility. | |
Visibility | getVisibility () const |
Return the study visibility. | |
void | setOwnerIdentifier (const std::string &id) |
Set the owner identifier. | |
std::string | getOwnerIdentifier () const |
Return the owner identifier. | |
void | setOwnerName (const std::string &name) |
Set the owner name. | |
std::string | getOwnerName () const |
Return the owner name. | |
void | setTableLocation (const std::string &loc) |
Set the table location. | |
std::string | getTableLocation () const |
Return the table location. | |
void | setModelLocation (const std::string &loc) |
Set the model location. | |
std::string | getModelLocation () const |
Return the model location. | |
void | setPanelLocation (const std::string &loc) |
Set the panel location. | |
std::string | getPanelLocation () const |
Return the panel location. | |
void | setRosterLocation (const std::string &loc) |
Set the roster location. | |
std::string | getRosterLocation () const |
Return the roster location. | |
void | setNameControlLocation (const std::string &nameControlLocation) |
Set the name control location. | |
std::string | getNameControlLocation () const |
Return the name control location. | |
void | setStatusControlLocation (const std::string &statusControlLocation) |
Set the status control location. | |
std::string | getStatusControlLocation () const |
Return the status control location. | |
void | setVisibilityControlLocation (const std::string &visibilityControlLocation) |
Set the visibility control location. | |
std::string | getVisibilityControlLocation () const |
Return the visibility control location. | |
void | setBlockCount (uint64_t blockCount) |
Set the block count. | |
uint64_t | getBlockCount () const |
Return the block count. | |
void | setCellCount (uint64_t cellCount) |
Set the cell count. | |
uint64_t | getCellCount () const |
Return the cell count. | |
void | setProspectCount (uint64_t prospectCount) |
Set the prospect count. | |
uint64_t | getProspectCount () const |
Return the prospect count. | |
void | setCreationTime (const std::string &creationTime) |
Set the creation time. | |
std::string | getCreationTime () const |
Return the creation time. | |
void | setLatestBlockTime (const std::string &latestBlockTime) |
Set the latest block time. | |
std::string | getLatestBlockTime () const |
Return the latest block time. | |
void | setLatestProspectTime (const std::string &latestProspectTime) |
Set the latest prospect time. | |
std::string | getLatestProspectTime () const |
Return the latest prospect time. | |
std::string | toString () |
Return a string representation of this Study . | |
Static Public Member Functions | |
static void | copyStudy (Study &t, const Study &s) |
Make a copy of a study. | |
Private Attributes | |
std::string | studyIdentifier |
std::string | studyName |
std::string | studyLocation |
Type | type |
Status | status |
Visibility | visibility |
std::string | ownerIdentifier |
std::string | ownerName |
std::string | tableLocation |
std::string | modelLocation |
std::string | panelLocation |
std::string | rosterLocation |
std::string | nameControlLocation |
std::string | statusControlLocation |
std::string | visibilityControlLocation |
uint64_t | blockCount |
uint64_t | cellCount |
uint64_t | prospectCount |
std::string | creationTime |
std::string | latestBlockTime |
std::string | latestProspectTime |
A container for all resources associated with an analytic project.
A study has these attributes:
Definition at line 25 of file Study.h.
Describes the state of the study, whether it is running, on standby, or stopped.
The Status
can be changed at any time. If the status attribute is not included in the posted study document, the default status is RUNNING
.
Indicates the quality of the predictands associated with subjects in the study.
The Type
determines the type of the predictive model that will be built for the study. The type attribute may not be changed after it has been set at study creation. If the type attribute is not included in the posted study document, the default value is NUMBER
.
Tells whether unidentified users can get estimated predictands from the model of the study.
The visibility of a study can be changed at any time. If the visibility is not included in the posted study document, the default visibility is PRIVATE
.
Study::Study | ( | ) |
Initializes a newly created Study
object with default attributes.
The type of a Study cannot be changed after construction.
Definition at line 11 of file Study.cpp.
References initStudy().
Study::Study | ( | const std::string & | studyName, | |
Type | type, | |||
Status | status, | |||
Visibility | visibility | |||
) |
Study::Study | ( | const Study & | rhs | ) |
Study::~Study | ( | ) | [virtual] |
Make a copy of a study.
t | the study to copy to (destination). | |
s | the study to copy from (source). |
Definition at line 122 of file Study.cpp.
References getBlockCount(), getCellCount(), getCreationTime(), getLatestBlockTime(), getLatestProspectTime(), getModelLocation(), getNameControlLocation(), getOwnerIdentifier(), getOwnerName(), getPanelLocation(), getProspectCount(), getRosterLocation(), getStatus(), getStatusControlLocation(), getStudyIdentifier(), getStudyLocation(), getStudyName(), getTableLocation(), getType(), getVisibility(), getVisibilityControlLocation(), setBlockCount(), setCellCount(), setCreationTime(), setLatestBlockTime(), setLatestProspectTime(), setModelLocation(), setNameControlLocation(), setOwnerIdentifier(), setOwnerName(), setPanelLocation(), setProspectCount(), setRosterLocation(), setStatus(), setStatusControlLocation(), setStudyIdentifier(), setStudyLocation(), setStudyName(), setTableLocation(), setType(), setVisibility(), and setVisibilityControlLocation().
Referenced by operator=().
uint64_t Study::getBlockCount | ( | ) | const |
Return the block count.
Definition at line 310 of file Study.cpp.
References blockCount.
Referenced by copyStudy(), and toString().
uint64_t Study::getCellCount | ( | ) | const |
Return the cell count.
Definition at line 320 of file Study.cpp.
References cellCount.
Referenced by copyStudy(), and toString().
std::string Study::getCreationTime | ( | ) | const |
Return the creation time.
Definition at line 340 of file Study.cpp.
References creationTime.
Referenced by copyStudy(), and toString().
std::string Study::getLatestBlockTime | ( | ) | const |
Return the latest block time.
Definition at line 350 of file Study.cpp.
References latestBlockTime.
Referenced by copyStudy(), and toString().
std::string Study::getLatestProspectTime | ( | ) | const |
Return the latest prospect time.
Definition at line 360 of file Study.cpp.
References latestProspectTime.
Referenced by copyStudy(), and toString().
std::string Study::getModelLocation | ( | ) | const |
Return the model location.
Definition at line 248 of file Study.cpp.
References modelLocation.
Referenced by copyStudy(), and toString().
std::string Study::getNameControlLocation | ( | ) | const |
Return the name control location.
Definition at line 280 of file Study.cpp.
References nameControlLocation.
Referenced by copyStudy(), and toString().
std::string Study::getOwnerIdentifier | ( | ) | const |
Return the owner identifier.
Definition at line 218 of file Study.cpp.
References ownerIdentifier.
Referenced by copyStudy(), and toString().
std::string Study::getOwnerName | ( | ) | const |
Return the owner name.
Definition at line 228 of file Study.cpp.
References ownerName.
Referenced by copyStudy(), and toString().
std::string Study::getPanelLocation | ( | ) | const |
Return the panel location.
Definition at line 258 of file Study.cpp.
References panelLocation.
Referenced by copyStudy(), and toString().
uint64_t Study::getProspectCount | ( | ) | const |
Return the prospect count.
Definition at line 330 of file Study.cpp.
References prospectCount.
Referenced by copyStudy(), and toString().
std::string Study::getRosterLocation | ( | ) | const |
Return the roster location.
Definition at line 268 of file Study.cpp.
References rosterLocation.
Referenced by copyStudy(), and toString().
Study::Status Study::getStatus | ( | ) | const |
Return the study status.
Definition at line 198 of file Study.cpp.
Referenced by copyStudy(), Yosokumo::YosokumoProtobuf::makeProtobufStudyFromStudy(), and toString().
std::string Study::getStatusControlLocation | ( | ) | const |
Return the status control location.
Definition at line 290 of file Study.cpp.
References statusControlLocation.
Referenced by copyStudy(), and toString().
std::string Study::getStudyIdentifier | ( | ) | const |
Return the study identifier.
Definition at line 158 of file Study.cpp.
References studyIdentifier.
Referenced by Yosokumo::Catalog::addStudy(), copyStudy(), Yosokumo::YosokumoProtobuf::makeProtobufStudyFromStudy(), Yosokumo::Catalog::operator==(), toString(), and Yosokumo::Catalog::toStringInternal().
std::string Study::getStudyLocation | ( | ) | const |
Return the study location.
Definition at line 178 of file Study.cpp.
References studyLocation.
Referenced by copyStudy(), and toString().
std::string Study::getStudyName | ( | ) | const |
Return the study name.
Definition at line 168 of file Study.cpp.
Referenced by copyStudy(), Yosokumo::YosokumoProtobuf::makeProtobufStudyFromStudy(), toString(), and Yosokumo::Catalog::toStringInternal().
std::string Study::getTableLocation | ( | ) | const |
Return the table location.
Definition at line 238 of file Study.cpp.
References tableLocation.
Referenced by copyStudy(), and toString().
Study::Type Study::getType | ( | ) | const |
Return the study type.
Definition at line 188 of file Study.cpp.
Referenced by copyStudy(), Yosokumo::YosokumoProtobuf::makeProtobufStudyFromStudy(), and toString().
Study::Visibility Study::getVisibility | ( | ) | const |
Return the study visibility.
Definition at line 208 of file Study.cpp.
Referenced by copyStudy(), Yosokumo::YosokumoProtobuf::makeProtobufStudyFromStudy(), and toString().
std::string Study::getVisibilityControlLocation | ( | ) | const |
Return the visibility control location.
Definition at line 300 of file Study.cpp.
References visibilityControlLocation.
Referenced by copyStudy(), and toString().
void Study::initStudy | ( | ) |
Initialize the data members of a study.
Definition at line 95 of file Study.cpp.
References blockCount, cellCount, creationTime, latestBlockTime, latestProspectTime, modelLocation, nameControlLocation, NUMBER, ownerIdentifier, ownerName, panelLocation, PRIVATE, prospectCount, rosterLocation, RUNNING, statusControlLocation, studyIdentifier, studyLocation, tableLocation, and visibilityControlLocation.
Referenced by Study().
bool Study::operator!= | ( | const Study & | rhs | ) | const |
bool Study::operator== | ( | const Study & | rhs | ) | const |
Equality operator - compare two Study
for equality.
rhs | the righthand side of the equality. |
Definition at line 53 of file Study.cpp.
References blockCount, cellCount, creationTime, latestBlockTime, latestProspectTime, modelLocation, nameControlLocation, ownerIdentifier, ownerName, panelLocation, prospectCount, rosterLocation, status, statusControlLocation, studyIdentifier, studyLocation, studyName, tableLocation, type, visibility, and visibilityControlLocation.
void Study::setBlockCount | ( | uint64_t | blockCount | ) |
Set the block count.
blockCount | the number of posted blocks that have been accepted into the study table. |
Definition at line 305 of file Study.cpp.
Referenced by copyStudy().
void Study::setCellCount | ( | uint64_t | cellCount | ) |
Set the cell count.
cellCount | the total number of cells contained in the blocks reported in the block count. |
Definition at line 315 of file Study.cpp.
Referenced by copyStudy().
void Study::setCreationTime | ( | const std::string & | creationTime | ) |
Set the creation time.
creationTime | the UTC time the study was created. |
Definition at line 335 of file Study.cpp.
Referenced by copyStudy().
void Study::setLatestBlockTime | ( | const std::string & | latestBlockTime | ) |
Set the latest block time.
latestBlockTime | the UTC time that the service accepted the most recent block into the study table. |
Definition at line 345 of file Study.cpp.
Referenced by copyStudy().
void Study::setLatestProspectTime | ( | const std::string & | latestProspectTime | ) |
Set the latest prospect time.
latestProspectTime | the UTC time of the most recent Post Model or Get Model request. |
Definition at line 355 of file Study.cpp.
Referenced by copyStudy().
void Study::setModelLocation | ( | const std::string & | loc | ) |
Set the model location.
loc | the location of the model for this study. May be null. |
Definition at line 243 of file Study.cpp.
References modelLocation.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setNameControlLocation | ( | const std::string & | nameControlLocation | ) |
Set the name control location.
nameControlLocation | the URI to use to change the name of the study. |
Definition at line 275 of file Study.cpp.
Referenced by copyStudy().
void Study::setOwnerIdentifier | ( | const std::string & | id | ) |
Set the owner identifier.
id | the identifier of the owner of this study. May be null. |
Definition at line 213 of file Study.cpp.
References ownerIdentifier.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setOwnerName | ( | const std::string & | name | ) |
Set the owner name.
name | the name to assign to the owner of this study. May be null. |
Definition at line 223 of file Study.cpp.
References ownerName.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setPanelLocation | ( | const std::string & | loc | ) |
Set the panel location.
loc | the location of the panel for this study. May be null. |
Definition at line 253 of file Study.cpp.
References panelLocation.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setProspectCount | ( | uint64_t | prospectCount | ) |
Set the prospect count.
prospectCount | the total number of specimens contained in all Post Model and Get Model requests for the study. |
Definition at line 325 of file Study.cpp.
Referenced by copyStudy().
void Study::setRosterLocation | ( | const std::string & | loc | ) |
Set the roster location.
loc | the location of the roster for this study. May be null. |
Definition at line 263 of file Study.cpp.
References rosterLocation.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setStatus | ( | Status | s | ) |
Set the study status.
s | the status to assign to this study. |
Definition at line 193 of file Study.cpp.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setStatusControlLocation | ( | const std::string & | statusControlLocation | ) |
Set the status control location.
statusControlLocation | the URI to use to change the status of the study. |
Definition at line 285 of file Study.cpp.
Referenced by copyStudy().
void Study::setStudyIdentifier | ( | const std::string & | id | ) |
Set the study identifier.
id | the identifier to assign to this study. This is the unique identification of the study. May be null. |
Definition at line 153 of file Study.cpp.
References studyIdentifier.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setStudyLocation | ( | const std::string & | loc | ) |
Set the study location.
loc | the location to assign to this study. May be null. |
Definition at line 173 of file Study.cpp.
References studyLocation.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setStudyName | ( | const std::string & | name | ) |
Set the study name.
name | the name to assign to this study. May be null. |
Definition at line 163 of file Study.cpp.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setTableLocation | ( | const std::string & | loc | ) |
Set the table location.
loc | the location of the table for this study. May be null. |
Definition at line 233 of file Study.cpp.
References tableLocation.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setType | ( | Type | t | ) |
Set the study type.
t | the type to assign to this study. |
Definition at line 183 of file Study.cpp.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setVisibility | ( | Visibility | v | ) |
Set the study visibility.
v | the type to assign to this study. |
Definition at line 203 of file Study.cpp.
Referenced by copyStudy(), and Yosokumo::YosokumoProtobuf::makeStudyFromProtobufStudy().
void Study::setVisibilityControlLocation | ( | const std::string & | visibilityControlLocation | ) |
Set the visibility control location.
visibilityControlLocation | the URI to use to change the visibility of the study. |
Definition at line 295 of file Study.cpp.
Referenced by copyStudy().
std::string Study::toString | ( | ) |
Return a string representation of this Study
.
Study
. Definition at line 367 of file Study.cpp.
References getBlockCount(), getCellCount(), getCreationTime(), getLatestBlockTime(), getLatestProspectTime(), getModelLocation(), getNameControlLocation(), getOwnerIdentifier(), getOwnerName(), getPanelLocation(), getProspectCount(), getRosterLocation(), getStatus(), getStatusControlLocation(), getStudyIdentifier(), getStudyLocation(), getStudyName(), getTableLocation(), getType(), getVisibility(), and getVisibilityControlLocation().
uint64_t Yosokumo::Study::blockCount [private] |
Definition at line 127 of file Study.h.
Referenced by getBlockCount(), initStudy(), and operator==().
uint64_t Yosokumo::Study::cellCount [private] |
Definition at line 128 of file Study.h.
Referenced by getCellCount(), initStudy(), and operator==().
std::string Yosokumo::Study::creationTime [private] |
Definition at line 131 of file Study.h.
Referenced by getCreationTime(), initStudy(), and operator==().
std::string Yosokumo::Study::latestBlockTime [private] |
Definition at line 132 of file Study.h.
Referenced by getLatestBlockTime(), initStudy(), and operator==().
std::string Yosokumo::Study::latestProspectTime [private] |
Definition at line 133 of file Study.h.
Referenced by getLatestProspectTime(), initStudy(), and operator==().
std::string Yosokumo::Study::modelLocation [private] |
Definition at line 117 of file Study.h.
Referenced by getModelLocation(), initStudy(), operator==(), and setModelLocation().
std::string Yosokumo::Study::nameControlLocation [private] |
Definition at line 123 of file Study.h.
Referenced by getNameControlLocation(), initStudy(), and operator==().
std::string Yosokumo::Study::ownerIdentifier [private] |
Definition at line 113 of file Study.h.
Referenced by getOwnerIdentifier(), initStudy(), operator==(), and setOwnerIdentifier().
std::string Yosokumo::Study::ownerName [private] |
Definition at line 114 of file Study.h.
Referenced by getOwnerName(), initStudy(), operator==(), and setOwnerName().
std::string Yosokumo::Study::panelLocation [private] |
Definition at line 118 of file Study.h.
Referenced by getPanelLocation(), initStudy(), operator==(), and setPanelLocation().
uint64_t Yosokumo::Study::prospectCount [private] |
Definition at line 129 of file Study.h.
Referenced by getProspectCount(), initStudy(), and operator==().
std::string Yosokumo::Study::rosterLocation [private] |
Definition at line 119 of file Study.h.
Referenced by getRosterLocation(), initStudy(), operator==(), and setRosterLocation().
Status Yosokumo::Study::status [private] |
Definition at line 110 of file Study.h.
Referenced by operator==().
std::string Yosokumo::Study::statusControlLocation [private] |
Definition at line 124 of file Study.h.
Referenced by getStatusControlLocation(), initStudy(), and operator==().
std::string Yosokumo::Study::studyIdentifier [private] |
Definition at line 105 of file Study.h.
Referenced by getStudyIdentifier(), initStudy(), operator==(), and setStudyIdentifier().
std::string Yosokumo::Study::studyLocation [private] |
Definition at line 107 of file Study.h.
Referenced by getStudyLocation(), initStudy(), operator==(), and setStudyLocation().
std::string Yosokumo::Study::studyName [private] |
Definition at line 106 of file Study.h.
Referenced by operator==().
std::string Yosokumo::Study::tableLocation [private] |
Definition at line 116 of file Study.h.
Referenced by getTableLocation(), initStudy(), operator==(), and setTableLocation().
Type Yosokumo::Study::type [private] |
Definition at line 109 of file Study.h.
Referenced by operator==().
Visibility Yosokumo::Study::visibility [private] |
Definition at line 111 of file Study.h.
Referenced by operator==().
std::string Yosokumo::Study::visibilityControlLocation [private] |
Definition at line 125 of file Study.h.
Referenced by getVisibilityControlLocation(), initStudy(), and operator==().