NCBI C++ ToolKit
|
Classes | |
class | ncbi::CNcbiToolkit_LogMessage |
Logging message. More... | |
class | ncbi::INcbiToolkit_LogHandler |
Logging interface. More... | |
class | CAppException |
CAppException –. More... | |
class | CNcbiApplicationGuard |
class | CNcbiApplicationAPI |
CNcbiApplicationAPI –. More... | |
class | INcbiIdler |
Interface for application idler. More... | |
class | CDefaultIdler |
Default idler. More... | |
class | pair_base_member< Base, Member > |
Template used for empty base class optimization. More... | |
class | CBoolEnum< TEnum > |
Template used to replace bool type arguments with some strict equivalent. More... | |
struct | Creater< X > |
Functor template for allocating object. More... | |
struct | Deleter< X > |
Functor template for deleting object. More... | |
struct | ArrayDeleter< X > |
Functor template for deleting array of objects. More... | |
struct | CDeleter< X > |
Functor template for the C language deallocation function, free(). More... | |
class | AutoPtr< X, Del > |
AutoPtr –. More... | |
struct | AutoPtr< X, Del >::SSafeBoolTag |
Bool operator for use in if() clause. More... | |
class | AutoArray< X, Del > |
AutoArray –. More... | |
struct | AutoArray< X, Del >::SSafeBoolTag |
Bool operator for use in if() clause. More... | |
struct | SThrowOnNull< TValue > |
class | CNullable< TValue, TNullToValue > |
Template class allowing to store a value or null (unassigned) state. More... | |
class | CStrictId< TKey, TStorage > |
Template class for strict ID types. More... | |
struct | SStrictId_Gi |
Key structs must always be defined - they are used in aliasinfo.cpp. More... | |
struct | SStrictId_Entrez |
struct | SStrictId_Tax |
class | CConstIdChecker< TId, id > |
a helper template to enforce constness of argument to GI_CONST macro More... | |
class | CRawPointer |
Helper address class. More... | |
class | CFastBuffer< KEmbeddedSize, TType > |
class | CSafeFlags< Enum > |
Support for safe enum flags. More... | |
struct | CSafeFlags< Enum >::SSafeBoolTag |
class | CNcbiActionGuard |
CNcbiActionGuard class Executes registered callbacks on request or on destruction. More... | |
class | CNcbiActionGuard::CAction_Base |
class | CNcbiActionGuard::CAction< TFunc > |
struct | hash< ncbi::CStrictId< TKey, TStorage > > |
class | IPhoneHomePolicy |
Interface class for Phone Home Policy. More... | |
Macros | |
#define | NCBI_TOOLKIT_EXPORT |
#define | CNcbiApplication CNcbiApplicationAPI |
#define | NCBI_ESWITCH_DEFINED |
#define | NCBI_EOWNERSHIP_DEFINED |
NCBI_ESWITCH_DEFINED. More... | |
#define | DECLARE_SAFE_BOOL_METHOD(Expr) |
Support for safe bool operators. More... | |
#define | DECLARE_OPERATOR_BOOL(Expr) DECLARE_SAFE_BOOL_METHOD(Expr) |
Declaration of safe bool operator from boolean expression. More... | |
#define | DECLARE_OPERATOR_BOOL_PTR(Ptr) DECLARE_OPERATOR_BOOL((Ptr) != 0) |
Declaration of safe bool operator from pointer expression. More... | |
#define | DECLARE_OPERATOR_BOOL_REF(Ref) DECLARE_OPERATOR_BOOL((Ref).NotNull()) |
Declaration of safe bool operator from CRef<>/CConstRef<> expression. More... | |
#define | OVERRIDE_OPERATOR_BOOL(TAncestorClass, NewBoolExpr) |
Override the DECLARE_OPERATOR_BOOL, etc. More... | |
#define | ITERATE_CONST(Cont) NCBI_NS_NCBI::s_ITERATE_ConstRef(Cont) |
#define | ITERATE_BEGIN(Cont, Begin) |
#define | ITERATE_VAR(Type) Type |
#define | ITERATE(Type, Var, Cont) |
ITERATE macro to sequence through container elements. More... | |
#define | NON_CONST_ITERATE(Type, Var, Cont) |
Non constant version of ITERATE macro. More... | |
#define | REVERSE_ITERATE(Type, Var, Cont) |
ITERATE macro to reverse sequence through container elements. More... | |
#define | NON_CONST_REVERSE_ITERATE(Type, Var, Cont) |
Non constant version of REVERSE_ITERATE macro. More... | |
#define | ERASE_ITERATE(Type, Var, Cont) |
Non-constant version with ability to erase current element, if container permits. More... | |
#define | VECTOR_ERASE(Var, Cont) (NCBI_NAME2(Var,_next) = (Cont).erase(Var)) |
Use this macro inside body of ERASE_ITERATE cycle to erase from vector-like container. More... | |
#define | ITERATE_BOTH_BOOL_VALUES(BoolVar) for( bool BoolVar##BOTH_BOOL_VALUES_DONE##__LINE__ = false, BoolVar = false; ! BoolVar##BOTH_BOOL_VALUES_DONE##__LINE__ ; BoolVar##BOTH_BOOL_VALUES_DONE##__LINE__ = BoolVar, BoolVar = true ) |
The body of the loop will be run with Var equal to false and then true. More... | |
#define | ITERATE_0_IDX(idx, up_to) for( TSeqPos idx = 0; idx < up_to; ++idx ) |
idx loops from 0 (inclusive) to up_to (exclusive) More... | |
#define | ITERATE_SIMPLE(num_iters) ITERATE_0_IDX( _dummy_idx_94768308_##__LINE__, num_iters ) |
Just repeat the body of the loop num_iters times. More... | |
#define | NCBI_INT8_GI |
Type for sequence GI. More... | |
#define | STRICT_ID_TO(TId, TInt, id) (static_cast<TInt>((id).Get())) |
Macros to convert TGi to other types (int, unsigned etc.). More... | |
#define | STRICT_ID_FROM(TIdType, TIntType, id) (TIdType(static_cast<TIdType::TId>(id))) |
#define | STRICT_ID_CONST(type, id) (type(static_cast<type::TId>(ncbi::CConstIdChecker<type::TId, id>::value))) |
#define | STRICT_ID_ZERO(type) STRICT_ID_CONST(type, 0) |
#define | STRICT_ID_INVALID(type) STRICT_ID_CONST(type, -1) |
#define | GI_TO(T, gi) STRICT_ID_TO(ncbi::TGi, T, gi) |
#define | GI_FROM(T, value) STRICT_ID_FROM(ncbi::TGi, T, value) |
#define | GI_CONST(gi) STRICT_ID_CONST(ncbi::TGi, gi) |
#define | ZERO_GI STRICT_ID_ZERO(ncbi::TGi) |
#define | INVALID_GI STRICT_ID_INVALID(ncbi::TGi) |
#define | ENTREZ_ID_TO(T, entrez_id) (static_cast<T>(entrez_id)) |
#define | ENTREZ_ID_FROM(T, value) (static_cast<ncbi::TEntrezId>(value)) |
#define | ENTREZ_ID_CONST(id) id |
#define | ZERO_ENTREZ_ID ENTREZ_ID_CONST(0) |
#define | INVALID_ENTREZ_ID ENTREZ_ID_CONST(-1) |
#define | TAX_ID_TO(T, tax_id) (static_cast<T>(tax_id)) |
#define | TAX_ID_FROM(T, value) (static_cast<ncbi::TTaxId>(value)) |
#define | TAX_ID_CONST(id) id |
#define | ZERO_TAX_ID TAX_ID_CONST(0) |
#define | INVALID_TAX_ID TAX_ID_CONST(-1) |
#define | INT_ID_TO(T, id) (static_cast<T>(id)) |
Convert gi-compatible int to/from other types. More... | |
#define | INT_ID_FROM(T, value) (static_cast<ncbi::TIntId>(value)) |
#define | NCBI_DEPRECATED_CTOR(decl) decl NCBI_DEPRECATED |
Macro used to mark a constructor as deprecated. More... | |
#define | NCBI_DEPRECATED_CLASS NCBI_DEPRECATED_CTOR(class) |
Macro used to mark a class as deprecated. More... | |
#define | DECLARE_SAFE_FLAGS_TYPE(E, T) typedef NCBI_NS_NCBI::CSafeFlags<E> T |
Macro DECLARE_SAFE_FLAGS_TYPE defines a typedef for safe-flags. More... | |
#define | DECLARE_SAFE_FLAGS(E) |
Macro DECLARE_SAFE_FLAGS marks a enum as safe-flags enum. More... | |
Friends | |
class | CNcbiApplicationGuard::CNcbiApplicationAPI |
class | CNcbiApplicationAPI::CNcbiApplicationGuard |
struct | AutoPtr< X, Del >::SSafeBoolTag |
struct | AutoArray< X, Del >::SSafeBoolTag |
struct | CSafeFlags< Enum >::SSafeBoolTag |
template<class T > | |
using | c_unique_ptr = unique_ptr< T, void(*)(T *)> |
Template helpers for unique_ptr to work with resource allocating/deallocating C functions. More... | |
template<class T , typename TDeleter > | |
unique_ptr< T, TDeleter > | make_c_unique (T *p, TDeleter d) |
Eliminates the necessity for specifying types of both allocated resource and deallocating C function. More... | |
template<class T > | |
unique_ptr< T, void(*)(void *)> | make_c_unique (T *p) |
Overload for the above for all types of allocated memory that are to be deallocated by free() More... | |
#define | NCBI_EXPORT_FUNC_DECLARE(lib, func) |
#define | NCBI_EXPORT_FUNC_DEFINE(lib, func) |
#define CNcbiApplication CNcbiApplicationAPI |
Definition at line 831 of file ncbiapp_api.hpp.
#define DECLARE_OPERATOR_BOOL | ( | Expr | ) | DECLARE_SAFE_BOOL_METHOD(Expr) |
Declaration of safe bool operator from boolean expression.
Actual operator declaration will be: operator TBoolType(void) const; where TBoolType is a typedef convertible to bool (member pointer).
Definition at line 199 of file ncbimisc.hpp.
#define DECLARE_OPERATOR_BOOL_PTR | ( | Ptr | ) | DECLARE_OPERATOR_BOOL((Ptr) != 0) |
Declaration of safe bool operator from pointer expression.
Actual operator declaration will be: operator bool(void) const;
Definition at line 206 of file ncbimisc.hpp.
#define DECLARE_OPERATOR_BOOL_REF | ( | Ref | ) | DECLARE_OPERATOR_BOOL((Ref).NotNull()) |
Declaration of safe bool operator from CRef<>/CConstRef<> expression.
Actual operator declaration will be: operator bool(void) const;
Definition at line 213 of file ncbimisc.hpp.
#define DECLARE_SAFE_BOOL_METHOD | ( | Expr | ) |
Support for safe bool operators.
Low level macro for declaring safe bool operator.
Definition at line 180 of file ncbimisc.hpp.
#define DECLARE_SAFE_FLAGS | ( | E | ) |
Macro DECLARE_SAFE_FLAGS marks a enum as safe-flags enum.
The argument is the enum name. If the enum is defined inside a class then DECLARE_SAFE_FLAGS() must be placed outside the class definition: DECLARE_SAFE_FLAGS(CMyClass::EFlags);
Definition at line 1346 of file ncbimisc.hpp.
Macro DECLARE_SAFE_FLAGS_TYPE defines a typedef for safe-flags.
First argument is enum name, second argument is the new typedef name. In place of old typedef: typedef int TFlags; put new macro: DECLARE_SAFE_FLAGS_TYPE(EFlags, TFlags);
Definition at line 1338 of file ncbimisc.hpp.
#define ENTREZ_ID_CONST | ( | id | ) | id |
Definition at line 1099 of file ncbimisc.hpp.
#define ENTREZ_ID_FROM | ( | T, | |
value | |||
) | (static_cast<ncbi::TEntrezId>(value)) |
Definition at line 1098 of file ncbimisc.hpp.
Definition at line 1097 of file ncbimisc.hpp.
#define ERASE_ITERATE | ( | Type, | |
Var, | |||
Cont | |||
) |
Non-constant version with ability to erase current element, if container permits.
Use only on containers, for which erase do not ruin other iterators into the container, e.g. map, list, but NOT vector. See also VECTOR_ERASE
Definition at line 843 of file ncbimisc.hpp.
#define GI_CONST | ( | gi | ) | STRICT_ID_CONST(ncbi::TGi, gi) |
Definition at line 1087 of file ncbimisc.hpp.
Definition at line 1086 of file ncbimisc.hpp.
#define GI_TO | ( | T, | |
gi | |||
) | STRICT_ID_TO(ncbi::TGi, T, gi) |
Definition at line 1085 of file ncbimisc.hpp.
#define INT_ID_FROM | ( | T, | |
value | |||
) | (static_cast<ncbi::TIntId>(value)) |
Definition at line 1121 of file ncbimisc.hpp.
Convert gi-compatible int to/from other types.
Definition at line 1120 of file ncbimisc.hpp.
#define INVALID_ENTREZ_ID ENTREZ_ID_CONST(-1) |
Definition at line 1103 of file ncbimisc.hpp.
#define INVALID_GI STRICT_ID_INVALID(ncbi::TGi) |
Definition at line 1089 of file ncbimisc.hpp.
#define INVALID_TAX_ID TAX_ID_CONST(-1) |
Definition at line 1116 of file ncbimisc.hpp.
#define ITERATE | ( | Type, | |
Var, | |||
Cont | |||
) |
ITERATE macro to sequence through container elements.
Definition at line 815 of file ncbimisc.hpp.
idx loops from 0 (inclusive) to up_to (exclusive)
Definition at line 865 of file ncbimisc.hpp.
#define ITERATE_BEGIN | ( | Cont, | |
Begin | |||
) |
Definition at line 800 of file ncbimisc.hpp.
#define ITERATE_BOTH_BOOL_VALUES | ( | BoolVar | ) | for( bool BoolVar##BOTH_BOOL_VALUES_DONE##__LINE__ = false, BoolVar = false; ! BoolVar##BOTH_BOOL_VALUES_DONE##__LINE__ ; BoolVar##BOTH_BOOL_VALUES_DONE##__LINE__ = BoolVar, BoolVar = true ) |
The body of the loop will be run with Var equal to false and then true.
The seemlingly excessive complexity of this macro is to get around a couple of limitations: * A bool only has two states, so it's not possible to represent the complete state space of (first iteration, second iteration, done) without another variable. * The variables declared in a for-loop's first part must be of the same type, so the other variable has to be a bool instead of something more convenient such as as a loop-counter.
Definition at line 861 of file ncbimisc.hpp.
#define ITERATE_CONST | ( | Cont | ) | NCBI_NS_NCBI::s_ITERATE_ConstRef(Cont) |
Definition at line 791 of file ncbimisc.hpp.
#define ITERATE_SIMPLE | ( | num_iters | ) | ITERATE_0_IDX( _dummy_idx_94768308_##__LINE__, num_iters ) |
Just repeat the body of the loop num_iters times.
Definition at line 869 of file ncbimisc.hpp.
Definition at line 811 of file ncbimisc.hpp.
#define NCBI_DEPRECATED_CLASS NCBI_DEPRECATED_CTOR(class) |
Macro used to mark a class as deprecated.
Definition at line 1215 of file ncbimisc.hpp.
#define NCBI_DEPRECATED_CTOR | ( | decl | ) | decl NCBI_DEPRECATED |
Macro used to mark a constructor as deprecated.
The correct syntax for this varies from compiler to compiler: older versions of GCC (prior to 3.4) require NCBI_DEPRECATED to follow any relevant constructor declarations, but some other compilers (Microsoft Visual Studio 2005, IBM Visual Age / XL) require it to precede any relevant declarations, whether or not they are for constructors.
Definition at line 1209 of file ncbimisc.hpp.
#define NCBI_EOWNERSHIP_DEFINED |
NCBI_ESWITCH_DEFINED.
Definition at line 82 of file ncbimisc.hpp.
#define NCBI_ESWITCH_DEFINED |
Definition at line 56 of file ncbimisc.hpp.
#define NCBI_EXPORT_FUNC_DECLARE | ( | lib, | |
func | |||
) |
Definition at line 1469 of file ncbimisc.hpp.
#define NCBI_EXPORT_FUNC_DEFINE | ( | lib, | |
func | |||
) |
Definition at line 1491 of file ncbimisc.hpp.
#define NCBI_INT8_GI |
Type for sequence GI.
Use this typedef rather than its expansion, which may change.
Definition at line 978 of file ncbimisc.hpp.
#define NCBI_TOOLKIT_EXPORT |
Definition at line 66 of file ncbi_toolkit_impl.hpp.
#define NON_CONST_ITERATE | ( | Type, | |
Var, | |||
Cont | |||
) |
Non constant version of ITERATE macro.
Definition at line 822 of file ncbimisc.hpp.
#define NON_CONST_REVERSE_ITERATE | ( | Type, | |
Var, | |||
Cont | |||
) |
Non constant version of REVERSE_ITERATE macro.
Definition at line 834 of file ncbimisc.hpp.
#define OVERRIDE_OPERATOR_BOOL | ( | TAncestorClass, | |
NewBoolExpr | |||
) |
Override the DECLARE_OPERATOR_BOOL, etc.
from an ancestor class. This is needed because sometimes you can't just use DECLARE_OPERATOR_BOOL due to cases such as the ancestor class being privately inherited from.
Definition at line 220 of file ncbimisc.hpp.
#define REVERSE_ITERATE | ( | Type, | |
Var, | |||
Cont | |||
) |
ITERATE macro to reverse sequence through container elements.
Definition at line 827 of file ncbimisc.hpp.
#define STRICT_ID_CONST | ( | type, | |
id | |||
) | (type(static_cast<type::TId>(ncbi::CConstIdChecker<type::TId, id>::value))) |
Definition at line 1070 of file ncbimisc.hpp.
#define STRICT_ID_FROM | ( | TIdType, | |
TIntType, | |||
id | |||
) | (TIdType(static_cast<TIdType::TId>(id))) |
Definition at line 1069 of file ncbimisc.hpp.
#define STRICT_ID_INVALID | ( | type | ) | STRICT_ID_CONST(type, -1) |
Definition at line 1073 of file ncbimisc.hpp.
#define STRICT_ID_TO | ( | TId, | |
TInt, | |||
id | |||
) | (static_cast<TInt>((id).Get())) |
Macros to convert TGi to other types (int, unsigned etc.).
Definition at line 1068 of file ncbimisc.hpp.
#define STRICT_ID_ZERO | ( | type | ) | STRICT_ID_CONST(type, 0) |
Definition at line 1072 of file ncbimisc.hpp.
#define TAX_ID_CONST | ( | id | ) | id |
Definition at line 1112 of file ncbimisc.hpp.
#define TAX_ID_FROM | ( | T, | |
value | |||
) | (static_cast<ncbi::TTaxId>(value)) |
Definition at line 1111 of file ncbimisc.hpp.
Definition at line 1110 of file ncbimisc.hpp.
#define VECTOR_ERASE | ( | Var, | |
Cont | |||
) | (NCBI_NAME2(Var,_next) = (Cont).erase(Var)) |
Use this macro inside body of ERASE_ITERATE cycle to erase from vector-like container.
Plain erase() call would invalidate Var_next iterator and would make the cycle controlling code to fail.
Definition at line 852 of file ncbimisc.hpp.
#define ZERO_ENTREZ_ID ENTREZ_ID_CONST(0) |
Definition at line 1102 of file ncbimisc.hpp.
#define ZERO_GI STRICT_ID_ZERO(ncbi::TGi) |
Definition at line 1088 of file ncbimisc.hpp.
#define ZERO_TAX_ID TAX_ID_CONST(0) |
Definition at line 1115 of file ncbimisc.hpp.
typedef Base pair_base_member< Base, Member >::base_type |
Definition at line 248 of file ncbimisc.hpp.
using c_unique_ptr = unique_ptr<T, void(*)(T*)> |
Template helpers for unique_ptr to work with resource allocating/deallocating C functions.
Eliminates the necessity for specifying type of deallocating C function.
Definition at line 1444 of file ncbimisc.hpp.
Definition at line 1028 of file ncbimisc.hpp.
typedef Del AutoPtr< X, Del >::deleter_type |
Alias for template argument.
Definition at line 404 of file ncbimisc.hpp.
typedef Del AutoArray< X, Del >::deleter_type |
Alias for template argument.
Definition at line 530 of file ncbimisc.hpp.
typedef X AutoPtr< X, Del >::element_type |
Define element type.
Definition at line 403 of file ncbimisc.hpp.
typedef X AutoArray< X, Del >::element_type |
Define element type.
Definition at line 529 of file ncbimisc.hpp.
typedef Enum CSafeFlags< Enum >::enum_type |
Definition at line 1252 of file ncbimisc.hpp.
typedef enum ENcbiOwnership EOwnership |
Ownership relations between objects.
Can be used to define or transfer ownership of objects. For example, specify if a CSocket object owns its underlying SOCK object.
typedef enum ENcbiSwitch ESwitch |
Aux.
enum to set/unset/default various features.
typedef Base pair_base_member< Base, Member >::first_type |
Definition at line 249 of file ncbimisc.hpp.
typedef CNcbiApplication*(* ncbi::FNcbiApplicationFactory) (void) |
Provide means of creating custom CNcbiApplication object – to use the latter instead of "dummy" NCBI application.
Definition at line 77 of file ncbi_toolkit_impl.hpp.
typedef Member pair_base_member< Base, Member >::member_type |
Definition at line 250 of file ncbimisc.hpp.
typedef Member pair_base_member< Base, Member >::second_type |
Definition at line 251 of file ncbimisc.hpp.
typedef underlying_type<enum_type>::type CSafeFlags< Enum >::storage_type |
Definition at line 1253 of file ncbimisc.hpp.
|
private |
Definition at line 1435 of file ncbimisc.hpp.
|
protected |
Definition at line 619 of file ncbiapp_api.hpp.
typedef void(SSafeBoolTag::* AutoPtr< X, Del >::TBoolType) (SSafeBoolTag *) |
Definition at line 458 of file ncbimisc.hpp.
typedef void(SSafeBoolTag::* AutoArray< X, Del >::TBoolType) (SSafeBoolTag *) |
Definition at line 578 of file ncbimisc.hpp.
typedef void(SSafeBoolTag::* CSafeFlags< Enum >::TBoolType) (SSafeBoolTag *) |
Definition at line 1274 of file ncbimisc.hpp.
|
protected |
Binary OR of "EDisableArgDesc".
Definition at line 428 of file ncbiapp_api.hpp.
typedef SStrictId_Entrez::TId TEntrezId |
TEntrezId type for entrez ids which require the same strictness as TGi.
Definition at line 1041 of file ncbimisc.hpp.
typedef CStrictId<SStrictId_Gi, SStrictId_Gi::TId> TGi |
Definition at line 1025 of file ncbimisc.hpp.
|
protected |
Binary OR of "EHideStdArgs".
Definition at line 449 of file ncbiapp_api.hpp.
Definition at line 895 of file ncbimisc.hpp.
typedef TIntId SStrictId_Gi::TId |
Definition at line 1013 of file ncbimisc.hpp.
typedef TIntId SStrictId_Entrez::TId |
Definition at line 1016 of file ncbimisc.hpp.
typedef int SStrictId_Tax::TId |
Definition at line 1019 of file ncbimisc.hpp.
Definition at line 999 of file ncbimisc.hpp.
typedef char ncbi::TNcbiToolkit_XChar |
Definition at line 55 of file ncbi_toolkit_impl.hpp.
Type for sequence locations and lengths.
Use this typedef rather than its expansion, which may change.
Definition at line 875 of file ncbimisc.hpp.
typedef int TSignedSeqPos |
Type for signed sequence position.
Use this type when and only when negative values are a possibility for reporting differences between positions, or for error reporting – though exceptions are generally better for error reporting. Use this typedef rather than its expansion, which may change.
Definition at line 887 of file ncbimisc.hpp.
|
protected |
Binary OR of "EStdioSetup".
Definition at line 467 of file ncbiapp_api.hpp.
typedef SStrictId_Tax::TId TTaxId |
Taxon id type.
Definition at line 1048 of file ncbimisc.hpp.
typedef CStrictId<TKey, TStorage> CStrictId< TKey, TStorage >::TThis |
Definition at line 896 of file ncbimisc.hpp.
Definition at line 1000 of file ncbimisc.hpp.
anonymous enum : TId |
Enumerator | |
---|---|
value |
Definition at line 1057 of file ncbimisc.hpp.
|
protected |
Enumerator | |
---|---|
fSkipSafeStaticDestroy |
Definition at line 616 of file ncbiapp_api.hpp.
Enumerator | |
---|---|
eBaseName | per GetProgramDisplayName |
eFullName | per GetProgramExecutablePath(eIgnoreLinks) |
eRealName | per GetProgramExecutablePath(eFollowLinks) |
Definition at line 366 of file ncbiapp_api.hpp.
|
protected |
Disable argument descriptions.
Call with a bit flag set if you do not want std AND user cmd.line args to be parsed. Note that by default the parsing of cmd.line args are enabled.
Enumerator | |
---|---|
fDisableStdArgs | (-logfile, -conffile, -version etc) |
Definition at line 425 of file ncbiapp_api.hpp.
Error types that an application can generate.
These error conditions are checked for and caught inside AppMain().
Enumerator | |
---|---|
eUnsetArgs | Command-line argument description not found. |
eSetupDiag | Application diagnostic stream setup failed. |
eLoadConfig | Registry data failed to load from config file. |
eSecond | Second instance of CNcbiApplicationAPI is prohibited. |
eNoRegistry | Registry file cannot be opened. |
Definition at line 82 of file ncbiapp_api.hpp.
|
protected |
When to return a user-set exit code.
Enumerator | |
---|---|
eNoExits | never (stick to existing logic) |
eExceptionalExits | when an (uncaught) exception occurs |
eAllExits | always (ignoring Run's return value) |
Definition at line 606 of file ncbiapp_api.hpp.
enum EFollowLinks |
Whether to follow symbolic links (also known as shortcuts or aliases)
Enumerator | |
---|---|
eIgnoreLinks | Do not follow symbolic links. |
eFollowLinks | Follow symbolic links. |
Definition at line 143 of file ncbimisc.hpp.
|
protected |
Which standard flag's descriptions should not be displayed in the usage message.
Do not display descriptions of the standard flags such as the -h, -logfile, -conffile, -version flags in the usage message. Note that you still can pass them in the command line.
Definition at line 438 of file ncbiapp_api.hpp.
enum EInterruptOnSignal |
Interrupt on signal mode.
On UNIX some functions can be interrupted by a signal and EINTR errno value. We can restart or cancel its execution.
Enumerator | |
---|---|
eInterruptOnSignal | Cancel operation if interrupted by a signal. |
eRestartOnSignal | Restart operation if interrupted by a signal. |
Definition at line 160 of file ncbimisc.hpp.
enum ENcbiOwnership |
Ownership relations between objects.
Can be used to define or transfer ownership of objects. For example, specify if a CSocket object owns its underlying SOCK object.
Enumerator | |
---|---|
eNoOwnership | No ownership is assumed. |
eTakeOwnership | An object can take ownership of another. |
eNoOwnership | |
eTakeOwnership | No ownership assumed. An object can take ownership of another |
Definition at line 99 of file ncbimisc.hpp.
enum ENcbiSwitch |
Aux.
enum to set/unset/default various features.
Enumerator | |
---|---|
eOff | |
eOn | |
eDefault | |
eOff | |
eOn | |
eDefault |
Definition at line 70 of file ncbimisc.hpp.
enum ENormalizePath |
Whether to normalize a path.
Enumerator | |
---|---|
eNormalizePath | Normalize a path. |
eNotNormalizePath | Do not normalize a path. |
Definition at line 150 of file ncbimisc.hpp.
enum ENull |
CNullable –.
A value whith 'unassigned' state. Define "null" pointer value.
Enumerator | |
---|---|
null |
Definition at line 645 of file ncbimisc.hpp.
enum ENullable |
Whether a value is nullable.
Enumerator | |
---|---|
eNullable | Value can be null. |
eNotNullable | Value cannot be null. |
Definition at line 113 of file ncbimisc.hpp.
|
protected |
Result of PreparseArgs()
Enumerator | |
---|---|
ePreparse_Continue | Continue application execution. |
ePreparse_Exit | Exit the application with zero exit code. |
Definition at line 410 of file ncbiapp_api.hpp.
enum ERetriable |
Can the action be retried?
Enumerator | |
---|---|
eRetriable_No | It makes no sense to retry the action. |
eRetriable_Unknown | It is unknown if the action can succeed if retried. |
eRetriable_Yes | It makes sense to try again. |
Definition at line 167 of file ncbimisc.hpp.
enum ERound |
Whether to truncate/round a value.
Enumerator | |
---|---|
eTrunc | Value must be truncated. |
eRound | Value must be rounded. |
Definition at line 136 of file ncbimisc.hpp.
Log message severity.
Enumerator | |
---|---|
eInfo | Informational message. |
eWarning | Warning message. |
eError | Error message. |
eCritical | Critical error message. |
eFatal | Fatal error. |
eTrace | Trace message. |
Definition at line 102 of file ncbi_toolkit.hpp.
enum ESign |
Signedness of a value.
Enumerator | |
---|---|
eNegative | Value is negative. |
eZero | Value is zero. |
ePositive | Value is positive. |
Definition at line 120 of file ncbimisc.hpp.
|
protected |
Flags to adjust standard I/O streams' behaviour.
Enumerator | |
---|---|
fNoSyncWithStdio | Turn off synchronizing of "C++" cin/cout/cerr streams with their "C" counterparts, possibly making the former not thread-safe. |
fDefault_CinBufferSize | Use compiler-specific default of Cin buffer size. |
fBinaryCin | treat standard input as binary |
fBinaryCout | treat standard output as binary |
fDefault_SyncWithStdio |
|
Definition at line 455 of file ncbiapp_api.hpp.
enum ETriState |
Enumeration to represent a tristate value.
Enumerator | |
---|---|
eTriState_Unknown | The value is indeterminate. |
eTriState_False | The value is equivalent to false/no. |
eTriState_True | The value is equivalent to true/yes. |
Definition at line 128 of file ncbimisc.hpp.
Definition at line 1143 of file ncbimisc.hpp.
References offset.
|
inlinestatic |
add offset to object reference (to get object's member)
Definition at line 1137 of file ncbimisc.hpp.
References offset.
Referenced by CSequenceOfTypeInfo::Data(), EndOf(), CSequenceOfTypeInfo::NextNode(), and CChoiceTypeInfo::Which().
|
inline |
Definition at line 1392 of file ncbimisc.hpp.
References CNcbiActionGuard::m_Actions.
Referenced by CNcbiApplicationAPI::AddOnExitAction().
|
inline |
Add callback to be executed from CNcbiApplicationAPI destructor.
Definition at line 400 of file ncbiapp_api.hpp.
References CNcbiActionGuard::AddAction(), and CNcbiApplicationAPI::m_OnExitActions.
Referenced by CBDB_Cache_OnAppExit::AddOnExitCallback(), and CBDB_Env_OnAppExit::AddOnExitCallback().
|
pure virtual |
Apply policy for an application.
For example, iIt can get and check program arguments, and call any other methods depending on it. Automatically called from CNcbiApplication::SetPhoneHomePolicy().
app | Pointer to the CNcbiApplicationAPI instance. |
Implemented in CSamplePhoneHomePolicy.
Referenced by CNcbiApplicationAPI::SetPhoneHomePolicy().
int CNcbiApplicationAPI::AppMain | ( | int | argc, |
const char *const * | argv, | ||
const char *const * | envp = 0 , |
||
EAppDiagStream | diag = eDS_Default , |
||
const char * | conf = NcbiEmptyCStr , |
||
const string & | name = NcbiEmptyString |
||
) |
Main function (entry point) for the NCBI application.
You can specify where to write the diagnostics to (EAppDiagStream), and where to get the configuration file (LoadConfig()) to load to the application registry (accessible via GetConfig()).
Throw exception if:
If application name is not specified a default of "ncbi" is used. Certain flags such as -logfile, -conffile and -version are special so AppMain() processes them separately.
argc | Argument count [argc in a regular main(argc, argv)]. |
argv | Argument vector [argv in a regular main(argc, argv)]. |
envp | Environment pointer [envp in a regular main(argc, argv, envp)]; a null pointer (the default) corresponds to the standard system array (environ on most Unix platforms). |
diag | Specify diagnostic stream. |
conf | Specify registry to load, as per LoadConfig(). The default is an empty string, requesting automatic detection; it is also possible to pass a specific name (optionally qualified) or a NULL pointer (disabling application-specific registry lookup altogether). |
name | Specify application name, used in diagnostics and automatic registry searching. |
Definition at line 831 of file ncbiapp.cpp.
References _TRACE, a, Abort(), ABORT_ON_THROW, CNcbiApplicationAPI::AppStop(), IRWRegistry::Clear(), Critical(), CSafeStaticGuard::Destroy(), DIAG_POST_LEVEL, DIAG_TRACE, CDiagContext::DiscardMessages(), CNcbiApplicationAPI::eAllExits, eDCM_NoChange, eDPF_Severity, eDS_User, eDT_Enable, CNcbiApplicationAPI::eExceptionalExits, CSafeStaticLifeSpan::eLifeLevel_AppMain, CArgException::eNoValue, CNcbiApplicationAPI::ePreparse_Exit, ERR_POST_X, CArgDescriptions::fDupErrToCerr, CNcbiApplicationAPI::FindProgramExecutablePath(), CArgDescriptions::fNoUsage, CVersionAPI::fPackageShort, CNcbiApplicationAPI::fSkipSafeStaticDestroy, fSuppress_Exception, CVersionAPI::fVersionInfo, GetDiagContext(), GetDiagHandler(), CException::GetErrCode(), CNcbiApplicationAPI::GetFullVersion(), CStreamDiagHandler::GetStream(), i, CDiagContext::IsSetExitCode(), CNcbiApplicationAPI::m_AppFlags, CNcbiApplicationAPI::m_ArgDesc, CNcbiApplicationAPI::m_Arguments, CNcbiApplicationAPI::m_Config, CNcbiApplicationAPI::m_DefaultConfig, CNcbiApplicationAPI::m_DisableArgDesc, CNcbiApplicationAPI::m_DryRun, CNcbiApplicationAPI::m_Environ, CNcbiApplicationAPI::m_ExePath, CNcbiApplicationAPI::m_ExitCode, CNcbiApplicationAPI::m_ExitCodeCond, CNcbiApplicationAPI::m_LogFile, CNcbiApplicationAPI::m_ProgramDisplayName, CNcbiApplicationAPI::m_RealExePath, NCBI_REPORT_EXCEPTION_X, NCBI_RETHROW, NCBI_THROW, NULL, CNcbiApplicationAPI::PreparseArgs(), CVersionAPI::Print(), CVersionAPI::PrintJson(), CVersionAPI::PrintXml(), s_ArgCfgFile, s_ArgDelimiter, s_ArgDryRun, s_ArgFullVersion, s_ArgFullVersionJson, s_ArgFullVersionXml, s_ArgLogFile, s_ArgVersion, s_HandleExceptions(), s_IsApplicationStarted, SetDiagFixedPostLevel(), SetDiagPostAllFlags(), SetDiagTrace(), CDiagContext::SetExitCode(), CNcbiApplicationAPI::SetProgramDisplayName(), SetThrowTraceAbort(), CDiagContext::SetupDiag(), CDirEntry::SplitPath(), NStr::StartsWith(), str(), NStr::strcmp(), string, CNcbiDiag::StrToSeverityLevel(), SuppressSystemMessageBox(), Warning(), CException::what(), CNcbiApplicationAPI::x_AddDefaultArgs(), CNcbiApplicationAPI::x_SetupStdio(), and CNcbiApplicationAPI::x_TryMain().
Referenced by CNcbiTestApplication::InitTestFramework(), main(), Main(), and NcbiSys_main().
|
protectedvirtual |
Method to be called before application start.
Can be used to set DiagContext properties to be printed in the application start message (e.g. host|host_ip_addr, client_ip and session_id for CGI applications).
Reimplemented in CCgiApplication.
Definition at line 1751 of file ncbiapp.cpp.
References GetDiagContext(), CNcbiApplicationAPI::GetProgramExecutablePath(), CDiagContext::IsSetOldPostFormat(), CNcbiApplicationAPI::m_Arguments, CDiagContext::PrintStart(), and NStr::ShellEncode().
Referenced by CNcbiApplicationAPI::x_TryInit().
|
protectedvirtual |
Method to be called before application exit.
Can be used to set DiagContext properties to be printed in the application stop message (exit_status, exit_signal, exit_code).
Reimplemented in CCgiApplication.
Definition at line 1771 of file ncbiapp.cpp.
References ctx, and GetDiagContext().
Referenced by CNcbiApplicationAPI::AppMain().
|
inlineconstexpr |
Definition at line 1532 of file ncbimisc.hpp.
Referenced by AdjustSpecificHostForTaxServer(), BOOST_AUTO_TEST_CASE(), CGb_qual::CleanupAndRepairInference(), CommentHasSuspiciousHtml(), CSequenceAmbigTrimmer::CSequenceAmbigTrimmer(), CCleanup::DecodeXMLMarkChanged(), CField_type::FeatureFieldFromCDSGeneProtField(), CValidError_imp::FindEmbeddedScript(), CSubSource::FixDateFormat(), CSubSource::FixSexQualifierValue(), CAsnBinCompressed::GetJobStreamProperties(), CRna_qual::GetLegalQual(), CInferencePrefixList::GetPrefixAndRemainder(), CSeqFeatData::GetRegulatoryClass(), CRna_feat_type::GetRnaRefType(), CSNPDbFeatIterator::GetSeq_feat(), CCommentItem::GetStringForRefSeqGenome(), HasBadWord(), CGb_qual::IsIllegalQualName(), CAsnBinCompressed::IsLZOStream(), impl::CDriverContext::NofConnections(), OrderQual(), CGb_qual::ParseExperiment(), CBioSource::RemoveLineageSourceNotes(), s_AaName(), s_IsAllowedPrefix(), s_SetTrnaProduct(), CRegexp::Set(), CBioSource::ShouldIgnoreConflict(), CFormatGuess::TestFormatXml(), CSeq_id::WhichFastaTag(), CTL_Connection::x_LoadTextPtrProcs(), CSearch_func::x_PrecededByOkPrefix(), CSearch_func::x_SkipBracketOrParen(), and x_ValidAminoAcid().
|
inline |
Definition at line 548 of file ncbimisc.hpp.
|
inline |
Definition at line 544 of file ncbimisc.hpp.
|
inlineexplicit |
Definition at line 540 of file ncbimisc.hpp.
|
inlineexplicit |
Construct the array using C++ new[] operator.
Definition at line 536 of file ncbimisc.hpp.
|
inline |
Copy constructor.
Definition at line 427 of file ncbimisc.hpp.
|
inline |
Constructor.
Definition at line 412 of file ncbimisc.hpp.
|
inline |
Constructor, own the pointed object if ownership == eTakeOwnership.
Definition at line 422 of file ncbimisc.hpp.
|
inline |
Constructor, own the pointed object if ownership == eTakeOwnership.
Definition at line 417 of file ncbimisc.hpp.
|
inline |
Constructor.
Definition at line 407 of file ncbimisc.hpp.
|
inline |
Definition at line 1182 of file ncbimisc.hpp.
References CFastBuffer< KEmbeddedSize, TType >::m_Buffer.
|
inline |
Definition at line 1183 of file ncbimisc.hpp.
References CFastBuffer< KEmbeddedSize, TType >::m_Buffer.
|
inline |
Definition at line 1429 of file ncbimisc.hpp.
|
private |
|
inline |
Definition at line 1418 of file ncbimisc.hpp.
Definition at line 313 of file ncbimisc.hpp.
Definition at line 314 of file ncbimisc.hpp.
|
inline |
Definition at line 727 of file ncbiapp_api.hpp.
|
inline |
Definition at line 1168 of file ncbimisc.hpp.
|
private |
|
inline |
Definition at line 1389 of file ncbimisc.hpp.
|
explicit |
Constructor.
Register the application instance, and reset important application-specific settings to empty values that will be set later.
Definition at line 139 of file ncbiapp.cpp.
References CVersionAPI::AddComponentVersion(), Critical(), eDiagAppState_AppBegin, CNcbiApplicationAPI::eNoExits, eNoOwnership, ERR_POST_X, eSecond, GetDiagContext(), CNcbiApplicationAPI::GetInstanceLock(), CVersionAPI::GetPackageVersion(), CDiagContext::GetUID(), CVersionAPI::GetVersionInfo(), CThread::InitializeMainThreadId(), CDiagContext::InitMessages(), CVersionInfo::IsAny(), CNcbiApplicationAPI::m_Arguments, CNcbiApplicationAPI::m_CinBuffer, CNcbiApplicationAPI::m_Config, CNcbiApplicationAPI::m_DisableArgDesc, CNcbiApplicationAPI::m_DryRun, CNcbiApplicationAPI::m_Environ, CNcbiApplicationAPI::m_ExitCodeCond, CNcbiApplicationAPI::m_HideArgs, CNcbiApplicationAPI::m_Instance, CNcbiApplicationAPI::m_PhoneHomePolicy, CNcbiApplicationAPI::m_PhoneHomePolicy_Ownership, CNcbiApplicationAPI::m_StdioFlags, CNcbiApplicationAPI::m_Version, NCBI_APP_SBUILDINFO_DEFAULT, NCBI_SC_VERSION_PROXY, NCBI_SUBVERSION_REVISION_PROXY, NCBI_TEAMCITY_PROJECT_NAME_PROXY, NCBI_THROW, CRef< C, Locker >::Reset(), CDiagContext::SetGlobalAppState(), CVersionAPI::SetVersionInfo(), and VerifyCpuCompatibility().
|
private |
Definition at line 96 of file ncbiapp.cpp.
References CNcbiApplicationAPI::GetInstanceLock(), CNcbiApplicationGuard::m_App, and CNcbiApplicationGuard::m_AppLock.
|
private |
|
protected |
Definition at line 64 of file ncbi_toolkit.cpp.
|
inline |
Create an empty nullable.
Definition at line 679 of file ncbimisc.hpp.
|
inline |
Initialize nullable with a specific value.
Definition at line 682 of file ncbimisc.hpp.
Default create function.
Definition at line 342 of file ncbimisc.hpp.
|
inline |
Definition at line 1255 of file ncbimisc.hpp.
Referenced by CSafeFlags< Enum >::operator&(), CSafeFlags< Enum >::operator^(), CSafeFlags< Enum >::operator|(), and CSafeFlags< Enum >::operator~().
|
inline |
Definition at line 1264 of file ncbimisc.hpp.
|
inlineexplicit |
Definition at line 1260 of file ncbimisc.hpp.
|
inline |
Definition at line 899 of file ncbimisc.hpp.
|
inlineexplicit |
Definition at line 927 of file ncbimisc.hpp.
Definition at line 898 of file ncbimisc.hpp.
Default delete function.
Definition at line 351 of file ncbimisc.hpp.
|
inlinestatic |
Array delete function.
Definition at line 360 of file ncbimisc.hpp.
|
protected |
Definition at line 1319 of file ncbiapp.cpp.
References CNcbiApplicationAPI::m_DisableArgDesc.
Referenced by CCgiApplication::CCgiApplication(), CCpGDemoApp::CCpGDemoApp(), CEntrez2ClientApp::CEntrez2ClientApp(), CGeneModelDemoApp::CGeneModelDemoApp(), CGridCommandLineInterfaceApp::CGridCommandLineInterfaceApp(), CRegexpLocApp::CRegexpLocApp(), CRemoteCgiApp::CRemoteCgiApp(), and CNcbiApplogApp::Init().
|
virtual |
Test run the application.
It is only supposed to test if the Run() is possible, or makes sense: that is, test all preconditions etc.
Reimplemented in CNcbiTestApplication, and CTbl2AsnApp.
Definition at line 292 of file ncbiapp.cpp.
References ERR_POST_X, and Info().
Referenced by CNcbiApplicationAPI::x_TryMain().
|
inline |
Definition at line 1185 of file ncbimisc.hpp.
References CFastBuffer< KEmbeddedSize, TType >::m_Buffer, and CFastBuffer< KEmbeddedSize, TType >::m_Size.
|
inline |
Definition at line 1186 of file ncbimisc.hpp.
References CFastBuffer< KEmbeddedSize, TType >::m_Buffer, and CFastBuffer< KEmbeddedSize, TType >::m_Size.
int CNcbiToolkit_LogMessage::ErrCode | ( | void | ) | const |
Get error code.
Definition at line 101 of file ncbi_toolkit.cpp.
References SDiagMessage::m_ErrCode, and ncbi::CNcbiToolkit_LogMessage::m_Msg.
int CNcbiToolkit_LogMessage::ErrSubCode | ( | void | ) | const |
Get error subcode.
Definition at line 106 of file ncbi_toolkit.cpp.
References SDiagMessage::m_ErrSubCode, and ncbi::CNcbiToolkit_LogMessage::m_Msg.
|
pure virtual |
Implemented in CNcbiActionGuard::CAction< TFunc >.
|
inlineoverridevirtual |
Implements CNcbiActionGuard::CAction_Base.
Definition at line 1431 of file ncbimisc.hpp.
References CNcbiActionGuard::CAction< TFunc >::m_Func.
|
inline |
Definition at line 1397 of file ncbimisc.hpp.
References ERR_POST, ITERATE, and CNcbiActionGuard::m_Actions.
Referenced by CNcbiApplicationAPI::ExecuteOnExitActions(), and CNcbiActionGuard::~CNcbiActionGuard().
|
protected |
Should only be called from the destructors of classes derived from CNcbiApplicationAPI - if it is necessary to access their data members and virtual methods; or to dynamic_cast<> from the base app class.
Definition at line 206 of file ncbiapp.cpp.
References CNcbiActionGuard::ExecuteActions(), and CNcbiApplicationAPI::m_OnExitActions.
Referenced by CNcbiApplication::~CNcbiApplication(), and CNcbiApplicationAPI::~CNcbiApplicationAPI().
|
virtual |
Cleanup on application exit.
Perform cleanup before exiting. The default behavior of this is "do nothing". If you have special cleanup logic that needs to be performed, then you must override this method with your own logic.
Reimplemented in CSubImageApp, CImageDemoApp, CConvImageApp, CBam2GraphApp, CFeatTreeSampleApp, CEUtilsApp, CDbapiSimpleApp, VSRunSampleApplication, CBlastDemoApplication, CBlastSampleApplication, CBlastDemoApplication, CSampleBasicApplication, CAnalyzeShiftApp, CColumnarVCFReaderApp, CTestDispatchApp, CAppJobTestApplication, CObjConvProfile, CProjBulderApp, CStreamTestApp, CMytestApplication, SegMaskerApplication, CDemoApp, CObjExtractApp, CNmer_repeatsApplication, CIdfetchApplication, CId2FetchApp, CId1FetchApp, CId1FetchApp, CFormatGuessApp, CFeatImportApp, Cn3DNoWin, CVDBTblastnApp, CVDBBlastnApp, CGuideTreeApplication, CConvert2BlastMaskApplication, BlastdbCopyApplication, CBlastDbCheckApplication, CWalkAsnCacheApplication, CAsnSubCacheCreateApplication, CReadIndexSpeedApp, CPrimeCacheApplication, CAsnCacheDumpSeqIdsApplication, CConcatSeqEntriesApplication, CCacheIndexCopyApp, CAsnCacheTestApplication, CAgpconvertApplication, CAgpValidateApplication, CAdapterSearchApplication, COmssa2pepxmlApplication, CMultiApplication, CMultiApplication, CClustererApplication, CBlastKmerBuildIndexApplication, CBlastKmerApplication, CCkblastindexApplication, CGumbelParamsApplication, CBlastInputDemoApplication, CDemoScoreBuilderApp, CTestCompartApplication, CAlignCleanupApplication, CNCBIwxApplication, CCgiApplication, CSdbapiTest, CDbapiTest, CUsageReportPhoneHomeSampleApp, CDbapiSampleApp, CAppNWA, CAppHitFilter, and CCompartApp.
Definition at line 299 of file ncbiapp.cpp.
Referenced by CCgiApplication::Exit(), and CNcbiApplicationAPI::x_TryMain().
string CNcbiToolkit_LogMessage::File | ( | void | ) | const |
Get file name in which message was originated.
Definition at line 119 of file ncbi_toolkit.cpp.
References SDiagMessage::m_File, and ncbi::CNcbiToolkit_LogMessage::m_Msg.
|
staticprotected |
Find the application's executable file.
Find the path and name of the executable file that this application is running from. Will be accessible by GetArguments().GetProgramName().
argc | Standard argument count "argc". |
argv | Standard argument vector "argv". |
real_path | If non-NULL, will get the fully resolved path to the executable. |
Definition at line 1426 of file ncbiapp.cpp.
References _ASSERT, _T_STDSTRING, _TX, BOOL, buf, CDll::eAutoUnload, eFollowLinks, CDll::eLoadNow, eUnknown, FAR, NStr::fSplit_MergeDelimiters, NStr::fSplit_Truncate, CNcbiEnvironment::Get(), CNcbiApplicationAPI::GetArguments(), CDirEntry::GetBase(), CDir::GetCwd(), CDll::GetEntryPoint_Func(), CNcbiApplicationAPI::GetEnvironment(), CDirEntry::GetPathSeparator(), CNcbiArguments::GetProgramName(), HANDLE, CNcbiApplicationAPI::InstanceGuard(), int, NStr::IntToString(), CDirEntry::IsAbsolutePath(), ITERATE, kEmptyStr, CDirEntry::MakePath(), NCBI_THROW, NcbiSys_getenv, CDirEntry::NormalizePath(), NULL, PATH_MAX, s_Init(), s_Path, NStr::Split(), and CDirEntry::SplitPath().
Referenced by CNcbiApplicationAPI::AppMain(), and CNcbiApplicationAPI::GetAppName().
|
inlinevirtual |
Deinitialize policy/reporting API.
Redefine if you want to gracefully terminate reporting API. Automatically called from the destructor.
Reimplemented in CSamplePhoneHomePolicy.
Definition at line 95 of file phone_home_policy.hpp.
Referenced by CNcbiApplicationAPI::SetPhoneHomePolicy(), and IPhoneHomePolicy::~IPhoneHomePolicy().
|
inline |
Check if the application has finished loading config file (successfully or not).
Definition at line 796 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_ConfigLoaded.
Referenced by g_GetConfigDouble(), g_GetConfigFlag(), g_GetConfigInt(), g_GetConfigString(), and CParam< TDescription >::sx_GetDefault().
|
inline |
Definition at line 273 of file ncbimisc.hpp.
|
inline |
Definition at line 269 of file ncbimisc.hpp.
Referenced by CConstRef< CSeq_loc >::AtomicReleaseTo(), CRef< CAlnMixSegment >::AtomicReleaseTo(), CConstRef< CSeq_loc >::AtomicResetFrom(), CRef< CAlnMixSegment >::AtomicResetFrom(), CGuard< IRegistry, SSimpleReadLock< IRegistry > >::GetLock(), CRef< CAlnMixSegment >::GetLocker(), CConstRef< CSeq_loc >::GetLocker(), CGuard< IRegistry, SSimpleReadLock< IRegistry > >::GetUnlock(), CRef< CAlnMixSegment >::Release(), CConstRef< CSeq_loc >::Release(), CRef< CAlnMixSegment >::ReleaseOrNull(), CConstRef< CSeq_loc >::ReleaseOrNull(), AutoArray< CS_INT >::reset(), AutoPtr< CNcbistrstream_Base >::reset(), CRef< CAlnMixSegment >::Reset(), CConstRef< CSeq_loc >::Reset(), pair_base_member< TKeyGetter, CTreeNode * >::Swap(), CRef< CAlnMixSegment >::Swap(), CConstRef< CSeq_loc >::Swap(), CBlobIdFor< Value, Converter >::ToString(), CStaticArraySearchBase< NStaticArray::PKeyValuePair< SStaticPair< KeyType, ValueType > >, less< KeyType > >::value_comp(), CRef< CAlnMixSegment >::x_AssignFromRef(), CConstRef< CSeq_loc >::x_AssignFromRef(), CRef< CAlnMixSegment >::x_LockFromMoveConstructor(), CConstRef< CSeq_loc >::x_LockFromMoveConstructor(), CRef< CAlnMixSegment >::x_LockFromPtr(), CConstRef< CSeq_loc >::x_LockFromPtr(), CRef< CAlnMixSegment >::x_LockFromRef(), CConstRef< CSeq_loc >::x_LockFromRef(), CRef< CAlnMixSegment >::x_MoveAssign(), and CConstRef< CSeq_loc >::x_MoveAssign().
SIZE_TYPE CNcbiApplicationAPI::FlushDiag | ( | CNcbiOstream * | os, |
bool | close_diag = false |
||
) |
Flush the in-memory diagnostic stream (for "eDS_ToMemory" case only).
In case of "eDS_ToMemory", the diagnostics is stored in the internal application memory buffer ("m_DiagStream"). Call this function to dump all the diagnostics to stream "os" and purge the buffer.
os | Output stream to dump diagnostics to. If it is NULL, then nothing will be written to it (but the buffer will still be purged). |
close_diag | If "close_diag" is TRUE, then also destroy "m_DiagStream". |
Definition at line 315 of file ncbiapp.cpp.
References CDiagContext::DiscardMessages(), CDiagContext::FlushMessages(), GetDiagContext(), GetDiagHandler(), and SetDiagStream().
Referenced by CNcbiApplicationAPI::~CNcbiApplicationAPI().
NCBI_XNCBI_EXPORT void g_ThrowOnNull | ( | void | ) |
Definition at line 861 of file ncbiexpt.cpp.
References NCBI_THROW.
Referenced by SThrowOnNull< TValue >::operator()().
|
inline |
Definition at line 1269 of file ncbimisc.hpp.
References CSafeFlags< Enum >::m_Flags.
Referenced by CSafeFlags< Enum >::operator!=(), CSafeFlags< Enum >::operator&(), operator<<(), CSafeFlags< Enum >::operator==(), CSafeFlags< Enum >::operator^(), CSafeFlags< Enum >::operator|(), and CSafeFlags< Enum >::operator~().
|
inline |
Definition at line 110 of file ncbiapp_api.hpp.
References CNcbiApplicationGuard::m_App.
Referenced by CNcbiApplicationGuard::operator*(), CNcbiApplicationGuard::operator->(), and s_CreateISynRegistry().
|
inline |
Definition at line 111 of file ncbiapp_api.hpp.
References CNcbiApplicationGuard::m_App.
|
inline |
Get pointer.
Definition at line 469 of file ncbimisc.hpp.
Referenced by CSeqMaskerUsetHash::add_ht_info(), CSeqMaskerUsetHash::add_vt_info(), CAutomaticGenCodeSingleton::AddGeneticCode(), CFileModules::AddModule(), CPSGL_Blob_Processor::AssignChunks(), CRPCClient< TRequest, TReply >::AsyncConnect(), CBDB_BlobSplitStore< TBV, TObjDeMux, TL >::BlobSize(), BOOST_AUTO_TEST_CASE(), CAlignCompare::SAlignment::BreakOnBoundaries(), BuildAln(), CSeqMap::CanResolveRange(), CAutomaticGenCodeSingleton::CAutomaticGenCodeSingleton(), CCgiWatchFile::CCgiWatchFile(), CConnTest::CheckFWConnections(), CVDBBlastUtil::CheckVDBs(), CLadder::CLadder(), CSearch< LEGACY, NHITS >::ClearLadderCalc(), CompressNcbi2na(), CReaderServiceConnector::Connect(), CPssmCddInputTest::CreatePssmInput(), CBDB_BlobSplitStore< TBV, TObjDeMux, TL >::CreateReader(), CTeeDiagHandler::CTeeDiagHandler(), CConnTest::DispatcherOkay(), CSeqMaskerOstatOpt::doFinalize(), CGffObjectLoader::Execute(), CConnTest::ExtraCheckOnFailure(), CBDB_BlobSplitStore< TBV, TObjDeMux, TL >::Fetch(), CAliasTypeStrings::GenerateCode(), CAliasTypeStrings::GenerateUserHPPCode(), CDataType::GetAnyTypeInfo(), CTemplate1TypeStrings::GetArg1Type(), CTemplate2TypeStrings::GetArg2Type(), CNcbiTestApplication::GetArgDescrs(), CBlastSeqVectorFromCSeq_data::GetCompressedPlusStrand(), CBlastSeqVectorOM::GetCompressedPlusStrand(), CReaderServiceConnector::GetConnDescription(), CAutoPtrTypeInfo< Data >::GetData(), CPointerTypeStrings::GetDataTypeStr(), CBDB_BlobSplitStore< TBV, TObjDeMux, TL >::GetDb(), CStringPairs< TExtraValuesMap >::GetDecoder(), CDataMember::GetDefault(), CUniSequenceDataType::GetElementType(), CStringPairs< TExtraValuesMap >::GetEncoder(), CConnTest::GetFWConnections(), CIdlerWrapper::GetIdler(), CBamDb::GetIdMapper(), CNcbiTestApplication::GetIniParser(), CTL_RowResult::GetItemInternal(), CSearch< LEGACY, NHITS >::GetLadderCalc(), CBAMDataLoader::GetLoaderNameFromArgs(), CTeeDiagHandler::GetLogName(), CMSHit::GetModInfo(), CMSPeakList::GetMZI(), CDataTypeModule::GetNamespace(), CTeeDiagHandler::GetOriginalHandler(), CFileCode::GetPrimaryClass(), CDataType::GetRealTypeInfo(), CDataMember::GetType(), CCgiWatchFile::HasChanged(), CConnTest::HttpOkay(), CBDB_BlobSplitStore< TBV, TObjDeMux, TL >::InitDbMutex(), CDiagMatcher::IsErrCodeMatcher(), CPubseqReader::LoadGiHash(), CPubseqReader::LoadGiSeq_ids(), CPubseqReader::LoadSeq_idAccVer(), CPubseqReader::LoadSeq_idInfo(), main(), CStringPairs< TExtraValuesMap >::Merge(), MergeExternal(), NcbiOpenURL(), CPipeHandle::Open(), CLadder::operator[](), CRWStreambuf::overflow(), CStringPairs< TExtraValuesMap >::Parse(), CTeeDiagHandler::Post(), CSplitCacheApp::ProcessBlob(), CSplitCacheApp::ProcessEntry(), CPSGL_CDDAnnot_Processor::ProcessReplySlow(), PsiBlastComputePssmFromAlignment(), CBDB_File::ReadCursor(), CBDB_BlobSplitStore< TBV, TObjDeMux, TL >::ReadRealloc(), CTeeDiagHandler::Reopen(), CMergeVolumes::Run(), CIdlerWrapper::RunIdler(), s_HttpConnectorBuilder(), s_IdLabel(), s_ServiceConnectorBuilder(), s_SocketConnectorBuilder(), s_TestCreatePssmFromFreqs(), CBamDb::SAADBImpl::SAADBImpl(), SERV_GetServers(), CConnTest::ServiceOkay(), CSearch< LEGACY, NHITS >::SetLadderCalc(), CMSHit::SetModInfo(), LinkHspTestFixture::setupLinkHspInputBlastn(), SetupQueries_OMF(), NuclWordFinderTextFixture::setupSequences(), SetupSubjects_OMF(), CFastaOstream::SetWidth(), CRWStreambuf::showmanyc(), CAlignCompare::SAlignment::Slice(), CConnTest::StatefulOkay(), CPSGL_Blob_Processor::TSE_ToOM(), CRWStreambuf::underflow(), CSDBAPI::UpdateMirror(), CSQLITE_Blob::Write(), CStreamLineReader::x_AdvanceEOLSimple(), CStreamLineReader::x_AdvanceEOLUnknown(), CRPCClient< TRequest, TReply >::x_Connect(), CRPCClient< TRequest, TReply >::x_ConnectURL(), CPsiBlastInputClustalW::x_CopyQueryToMsa(), CBDB_RawFile::x_DB_CPut(), CBDB_RawFile::x_DB_Fetch(), CBDB_RawFile::x_DB_Put(), CBDB_RawFile::x_DBC_Fetch(), CSDB_Decryptor::x_Decrypt(), CPsiBlastInputClustalW::x_ExtractAlignmentData(), CPsiBlastInputClustalW::x_ExtractQueryForPssm(), CPsiBlastInputClustalW::x_ExtractQueryFromMsa(), CBlastFastaInputSource::x_FastaToSeqLoc(), x_FormatError(), CId1Reader::x_GetConnection(), CId2Reader::x_GetConnection(), CPubseqReader::x_GetConnection(), CPubseq2Reader::x_GetConnection(), CGen_code_table::x_GetImplementation(), CSeqVector::x_GetIterator(), CLDS2_Database::x_GetStatement(), CLoadLockSetter::x_Init(), CGen_code_table::x_InitImplementation(), CId2FetchApp::x_InitPubSeqConnection(), CTSE_Split_Info::x_LoadChunks(), CPdfObject::x_PrintTo(), CId2FetchApp::x_ProcessData(), CPagedFile::x_ReadPage(), CPubseqReader::x_ReceiveData(), CSeqVector::x_ResetIterator(), CDBLBClientApp::x_RunWhatIs(), CDBLBClientApp::x_RunWhereIs(), CPubseq2Reader::x_SendPacket(), CId2FetchApp::x_SendRequestPacket(), CPsiBlastInputClustalW::x_ValidateQueryInMsa(), CFastaOstream::x_WriteSequence(), CRWStreambuf::xsgetn(), and CRWStreambuf::xsputn().
|
inline |
Get pointer.
Definition at line 581 of file ncbimisc.hpp.
Referenced by CCompressionStreambuf::CCompressionStreambuf(), CBamString::clear(), CLZOCompression::CompressBlock(), CTL_RowResult::CTL_RowResult(), CBamString::data(), CMySQL_LangCmd::EscapeString(), CDB_Object::GetLogString(), CBufferedLineReader::GetPosition(), CWigBufferedLineReader::GetPosition(), CArchiveMemory::Load(), CQueue::LoadFromDump(), CSeqVector_CI::operator--(), CSeqVector_CI::operator=(), CSparseKmerCounts::Reset(), CLZOBuffer::ResetBuffer(), CSeqVector_CI::SetPos(), CSeqVector_CI::x_BackupSize(), CSeqVector_CI::x_CacheOffset(), CSeqVector_CI::x_CacheSize(), CStatementBase::x_GetData(), CSeqVector_CI::x_InitializeCache(), CSeqVector_CI::x_NextCacheSeg(), CSeqVector_CI::x_PrevCacheSeg(), CBGZFFile::x_ReadBlock(), CBufferedLineReader::x_ReadBuffer(), CWigBufferedLineReader::x_ReadBuffer(), CSeqVector_CI::x_ResetBackup(), CSeqVector_CI::x_ResetCache(), CSeqVector_CI::x_ResizeCache(), CSeqVector_CI::x_SetPos(), CSeqVector_CI::x_SwapCache(), CSeqVector_CI::x_UpdateCacheDown(), and CSeqVector_CI::x_UpdateCacheUp().
Definition at line 921 of file ncbimisc.hpp.
Referenced by CObjectOStream::WriteGi().
|
static |
Definition at line 1390 of file ncbiapp.cpp.
References CNcbiApplicationAPI::eBaseName, eFollowLinks, CNcbiApplicationAPI::eFullName, eIgnoreLinks, CNcbiApplicationAPI::eRealName, CNcbiApplicationAPI::FindProgramExecutablePath(), CNcbiApplicationAPI::GetProgramDisplayName(), CNcbiApplicationAPI::GetProgramExecutablePath(), CNcbiApplicationAPI::InstanceGuard(), NULL, and CDirEntry::SplitPath().
Referenced by CDirEntry::CreateAbsolutePath(), FtaErrInit(), CDiagContext::GetAppName(), CDbapiSimpleApp::ParseArgs(), CCgiRequestProcessor::ProcessVersionRequest(), CFlat2AsnApp::Run(), s_GetProgramPath(), s_InitAllKNS(), s_ReportError(), and CNcbiApplicationAPI::SetProgramDisplayName().
|
inlineprotected |
Get argument descriptions (set by SetupArgDescriptions)
Definition at line 818 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_ArgDesc.
Referenced by CCgiApplication::GetArgs(), CCgiApplication::InitArgs(), CCgiRequestProcessor::OnException(), CCgiRequestProcessor::ProcessHelpRequest(), and CMakeScoreMethodApp::Run().
Get parsed command line arguments.
Get command line arguments parsed according to the arg descriptions set by SetupArgDescriptions(). Throw exception if no descriptions have been set.
Reimplemented in CCgiApplication.
Definition at line 305 of file ncbiapp.cpp.
References CNcbiApplicationAPI::m_Args, and NCBI_THROW.
Referenced by CReadBlastApp::AnalyzeSeqs(), CSamplePhoneHomePolicy::Apply(), CFileModules::BeginXMLSchema(), BOOST_AUTO_TEST_CASE(), CAlignCollapser::CAlignCollapser(), CNcbiApplogApp::Cmd_Generate(), CNcbiApplogApp::Cmd_Health(), CReadBlastApp::CollectFrameshiftedSeqs(), CPsgPerfApplication::ColorMe(), CBlastDBAliasApp::ConvertGiFile(), CBlastDBAliasApp::CreateAliasFile(), CNcbiEncryptApp::Decrypt(), CDbapiSimpleApp::DemoDynamicSql(), CSdbapiSimpleApp::DemoDynamicSql(), CDbapiSimpleApp::DemoParamerizedSql(), CSdbapiSimpleApp::DemoParamerizedSql(), CDbapiSimpleApp::DemoSqlInjection(), CSdbapiSimpleApp::DemoSqlInjection(), CSampleNetCacheClient::DemoStream(), CPsiBlastApp::DoIterations(), CReadBlastApp::dump_fasta_for_pretty_blast(), DumpExpected(), CNcbiEncryptApp::Encrypt(), CAlignCollapser::FilterAlignments(), CDataTool::GenerateCode(), CNcbiEncryptApp::GenerateKey(), SGridWorkerNodeImpl::GetArgs(), CCgiApplication::GetArgs(), CJniUtil::GetArgsFromNcbiApp(), CAlignCollapser::GetCollapsedAlgnments(), pub_report::CPubReportApp::GetEutilsOnly(), CDemoApp::GetIds(), pub_report::CPubReportApp::GetInputStream(), CIdMapperApp::GetMapper(), pub_report::CPubReportApp::GetMaxDateCheck(), CCodeGenerator::GetOpt(), pub_report::CPubReportApp::GetOutputStream(), subfuse::CSubfuseApp::GetOutputStream(), CMytestApplication::GetSeqEntry(), pub_report::CPubReportApp::GetSerialDataFormat(), CIdMapperApp::GetSourceIds(), CCleanupApp::HandleSeqEntry(), CFeatTreeSampleApp::Init(), CIgBlastnApp::Init_Worker_Threads(), CCgiApplication::InitArgs(), pub_report::CPubReportApp::IsJournalReport(), pub_report::CPubReportApp::IsUnpublishedReport(), CAlnVwrApp::LoadDenseg(), CAlnMrgApp::LoadInputAlns(), CId1FetchApp::LookUpGI(), NCBITEST_AUTO_INIT(), NCBITEST_INIT_VARIABLES(), SGridWorkerNodeImpl::OfflineRun(), CAsn2FastaApp::OpenFastaOstream(), CDbapiSimpleApp::ParseArgs(), CSdbapiSimpleApp::ParseArgs(), CProjBulderApp::ParseArguments(), CBlastFormatterApp::PrintFormattedOutput(), CBlastFormatterVdbApp::PrintFormattedOutput(), CAlnMrgApp::PrintMergedAln(), CAsn2FastaApp::PrintQualityScores(), CPsgPerfApplication::PrintResult(), CSplitCacheApp::Process(), CBlastDemoApplication::ProcessCommandLineArgs(), CDataTool::ProcessData(), CBam2GraphApp::ProcessFile(), CDataTool::ProcessModules(), CBiosampleChkApp::ProcessOneFile(), CBam2GraphApp::ProcessSrz(), CNcbiApplogApp::Redirect(), CDemoContigAssemblyApp::Run(), CMergeyApp::Run(), CNgAlignApp::Run(), CProSplignApp::Run(), CSRSearchApplication::Run(), CReadresult::Run(), COMSSA::Run(), COMSSAMerge::Run(), CDemoSeqQaApp::Run(), CBlastFormatterApp::Run(), CBlastnApp::Run(), CBlastpApp::Run(), CBlastxApp::Run(), CDeltaBlastApp::Run(), CPsiBlastApp::Run(), CRPSBlastApp::Run(), CRPSTBlastnApp::Run(), CSeedTopApp::Run(), CTblastnApp::Run(), CTblastxApp::Run(), CBlastDBAliasApp::Run(), CBlastdbConvertApp::Run(), CBlastDBCmdApp::Run(), CBlastFormatterVdbApp::Run(), CBlastVdbCmdApp::Run(), CCompartApp::Run(), CCompactSAMApplication::Run(), CExonSelectorApplication::Run(), CAppHitFilter::Run(), CIgBlastnApp::Run(), CIgBlastpApp::Run(), CMagicBlastApp::Run(), CPsgClientApp::Run(), CRMBlastnApp::Run(), CSplignApp::Run(), CSrcChkApp::Run(), seqsubmit_split::CSeqSubSplitter::Run(), CVecScreenApp::Run(), CDbapiDriverSampleApp::Run(), CDbapiSampleApp::Run(), CTestGuiRegistryApp::Run(), CGBProjectTool::Run(), CNcbiApplogApp::Run(), CTax4BlastDemo::Run(), CHugeFileDemoApp::Run(), CDbapiTest::Run(), CPsgClientSampleApp::Run(), CSdbapiTest::Run(), CAnnotWriterApp::Run(), CAsn2FastaApp::Run(), CAsn2FlatApp::Run(), CCleanupApp::Run(), CDiscRepApp::Run(), CMultiReaderApp::Run(), pub_report::CPubReportApp::Run(), CPubmedFetchApplication::Run(), CTestRemoteUpdaterApplication::Run(), SGridWorkerNodeImpl::Run(), CGridWorkerApp::Run(), CThreadedApp::Run(), CAVApp::Run(), CAlignCleanupApplication::Run(), CTestCompartApplication::Run(), CDemoScoreBuilderApp::Run(), CBlastInputDemoApplication::Run(), CGumbelParamsApplication::Run(), CCkblastindexApplication::Run(), CBlastKmerApplication::Run(), CBlastKmerBuildIndexApplication::Run(), CClustererApplication::Run(), CMultiApplication::Run(), CLocalFinderApp::Run(), COmssa2pepxmlApplication::Run(), CAdapterSearchApplication::Run(), CCpGDemoApp::Run(), CGeneModelDemoApp::Run(), CRegexpLocApp::Run(), CXcompareAnnotsApplication::Run(), CWinMaskDemoApplication::Run(), CAgpValidateApplication::Run(), CAgpconvertApplication::Run(), CAsnCacheTestApplication::Run(), CCacheIndexCopyApp::Run(), CConcatSeqEntriesApplication::Run(), CAsnCacheDumpSeqIdsApplication::Run(), CPrimeCacheApplication::Run(), CReadIndexSpeedApp::Run(), CAsnSubCacheCreateApplication::Run(), CWalkAsnCacheApplication::Run(), CBiosampleChkApp::Run(), BlastdbCopyApplication::Run(), CGuideTreeApplication::Run(), CVDBBlastnApp::Run(), CVDBTblastnApp::Run(), Cn3DNoWin::Run(), CCompartApplication::Run(), CConversionApp::Run(), CDBLBClientApp::Run(), CDustMaskApplication::Run(), CFeatImportApp::Run(), CFormatGuessApp::Run(), CGapStatsApplication::Run(), CGffDeconcatApp::Run(), CGi2TaxIdApp::Run(), CHgvsToSeqfeatConverter::Run(), CId1FetchApp::Run(), CId2FetchApp::Run(), CIdfetchApplication::Run(), CMultipatternApp::Run(), CNcbiEncryptApp::Run(), CNetScheduleDApp::Run(), CNetStorageDApp::Run(), CNetStorageGCApp::Run(), CNmer_repeatsApplication::Run(), CObjExtractApp::Run(), CDemoApp::Run(), CReadBlastApp::Run(), SegMaskerApplication::Run(), CMytestApplication::Run(), CSplitCacheApp::Run(), CStreamTestApp::Run(), subfuse::CSubfuseApp::Run(), CWig2tableApplication::Run(), CWinMaskApplication::Run(), CPsgPerfApplication::Run(), CBDB_CacheVerifyApp::Run(), CBDB_FileDumperApp::Run(), CRunTestApplication::Run(), CMysqlDemoApp::Run(), CTestApplication::Run(), CTestBMApp::Run(), CTestDispatchApp::Run(), CMakeScoreMethodApp::Run(), CColumnarVCFReaderApp::Run(), CEntrez2ClientApp::Run(), CAlnMrgApp::Run(), CAlnVwrApp::Run(), CFetchGBProjectApp::Run(), CSampleAlnmgrApplication::Run(), CSampleAsnApplication::Run(), CSampleBasicApplication::Run(), CBlastDemoApplication::Run(), CBlastSampleApplication::Run(), VSRunSampleApplication::Run(), CEUtilsApp::Run(), CHttpSessionApp::Run(), CSampleLds2Application::Run(), CMultiCommandApplication::Run(), CSampleNetCacheClient::Run(), CGridClientSampleApp::Run(), CSampleNetScheduleClient::Run(), CSampleNetScheduleNode::Run(), CRemoteAppClientSampleApp::Run(), CSampleObjectsApplication::Run(), CEditBioseqSampleApp::Run(), CSampleObjmgrApplication::Run(), CBssInfoApp::Run(), CProcessHighestSeObjs::Run(), CSeqAnnotSplicerApp::Run(), CSampleLibtestApplication::Run(), CBam2GraphApp::Run(), CConvImageApp::Run(), CImageDemoApp::Run(), CSubImageApp::Run(), CGapStatsApplication::RunNoCatch(), CDbapiTestSpeedApp::RunSample(), CLangQueryApp::RunSample(), CAsn2FlatApp::SetFlatfileOstream(), CAlnMrgApp::SetOptions(), CSplitCacheApp::SetupCache(), CHttpSessionApp::SetupParam(), Verbose(), CAlnMrgApp::ViewMergedAln(), CAsn2FlatApp::WrapINSDSet(), CBlastFormatterApp::x_AddCmdOptions(), CBlastDBAliasApp::x_AddCmdOptions(), CBlastDBCmdApp::x_AddCmdOptions(), CConvert2BlastMaskApplication::x_AddCmdOptions(), CMakeBlastDBApp::x_AddCmdOptions(), CMakeClusterDBApp::x_AddCmdOptions(), CBlastFormatterVdbApp::x_AddCmdOptions(), CBlastVdbCmdApp::x_AddCmdOptions(), CMakeProfileDBApp::x_AddCmdOptions(), CNgAlignApp::x_AddFilters(), CNgAlignApp::x_AddScorers(), CMakeBlastDBApp::x_BuildDatabase(), CMakeClusterDBApp::x_BuildDatabase(), CDiscRepApp::x_ConstructOutputName(), CBlastDBAliasApp::x_ConvertSeqIDFile(), CNgAlignApp::x_CreateBlastAligner(), CNgAlignApp::x_CreateSequenceSet(), CBlastSampleApplication::x_CreateSSeqLoc(), CDiscRepApp::x_DefaultHeader(), CAppHitFilter::x_DoMultiple(), CAppHitFilter::x_DoPairwise(), CAppHitFilter::x_DumpOutput(), CWig2tableApplication::x_Error(), CAsnSubCacheCreateApplication::x_FetchMissingBlobs(), CAsn2FlatApp::x_FFGenerate(), CAsn2FlatApp::x_GenerateBatchMode(), CAsnSubCacheCreateApplication::x_GetBioseqHandle(), CBlastDBAliasApp::x_GetDbsToAggregate(), CBlastDBAliasApp::x_GetOperationMode(), CBlastVdbCmdApp::x_GetQueries(), CConvert2BlastMaskApplication::x_GetReader(), CDustMaskApplication::x_GetReader(), SegMaskerApplication::x_GetReader(), CGapStatsApplication::x_GetScope(), CMakeBlastDBApp::x_GetUserInputTypeHint(), CConvert2BlastMaskApplication::x_GetWriter(), CDustMaskApplication::x_GetWriter(), SegMaskerApplication::x_GetWriter(), CAgpconvertApplication::x_HandleTaxArgs(), CBlastVdbCmdApp::x_InitApplicationData(), CBlastDBCmdApp::x_InitBlastDB(), CBlastDBCmdApp::x_InitBlastDB_TaxIdList(), CAsn2FlatApp::x_InitNewContext(), CMakeProfileDBApp::x_InitProgramParameters(), CId2FetchApp::x_InitPubSeqConnection(), CBlastDBCmdApp::x_InitSearchRequest(), CAgpconvertApplication::x_IsAnySimpleSubsourceArgSet(), CAppHitFilter::x_LoadConstraints(), CNgAlignApp::x_LoadExternalSequences(), CColumnarVCFReaderApp::x_LoadSerializedData(), CAgpconvertApplication::x_LoadTemplate(), CColumnarVCFReaderApp::x_LoadVCFFile(), CNcbiApplicationAPI::x_LogOptions(), CAsn2FastaApp::x_OpenIStream(), CCleanupApp::x_OpenOStream(), CDiscRepApp::x_Output(), CDiscRepApp::x_ParseDirectory(), CBlastDBCmdApp::x_PrintBlastDatabaseInformation(), CBlastVdbCmdApp::x_PrintBlastDatabaseInformation(), CBlastDBCmdApp::x_PrintBlastDatabaseTaxInformation(), CBlastVdbCmdApp::x_PrintVDBPaths(), CPrimeCacheApplication::x_Process_Fasta(), CPrimeCacheApplication::x_Process_SeqEntry(), CBlastDBCmdApp::x_ProcessBatchEntry(), CBlastDBCmdApp::x_ProcessBatchEntry_NoDup(), CBlastDBCmdApp::x_ProcessBatchPig(), CBlastDBCmdApp::x_ProcessEntry(), CHugeFileDemoApp::x_ProcessFileTraditionally(), CMakeBlastDBApp::x_ProcessInputData(), CAsn2FastaApp::x_ProcessISubdirectory(), CMakeBlastDBApp::x_ProcessMaskData(), CCleanupApp::x_ProcessOneFile(), CBlastDBCmdApp::x_ProcessSearchRequest(), CBlastVdbCmdApp::x_ProcessSearchRequest(), CBlastDBCmdApp::x_ProcessSearchType(), CAppHitFilter::x_ReadInputHits(), CHugeFileDemoApp::x_RunDemo(), CPsiBlastApp::x_RunLocalPsiBlastIterations(), CDBLBClientApp::x_RunLookup(), CBlastnApp::x_RunMTBySplitDB(), CBlastpApp::x_RunMTBySplitDB(), CBlastxApp::x_RunMTBySplitDB(), CRPSBlastApp::x_RunMTBySplitDB(), CRPSTBlastnApp::x_RunMTBySplitDB(), CTblastnApp::x_RunMTBySplitDB(), CBlastnApp::x_RunMTBySplitQuery(), CBlastpApp::x_RunMTBySplitQuery(), CBlastxApp::x_RunMTBySplitQuery(), CRPSBlastApp::x_RunMTBySplitQuery(), CRPSTBlastnApp::x_RunMTBySplitQuery(), CTblastnApp::x_RunMTBySplitQuery(), CAppNWA::x_RunOnPair(), CDBLBClientApp::x_RunWhatIs(), CDBLBClientApp::x_RunWhereIs(), CBlastDBAliasApp::x_SeqIDFileInfo(), CSplignApp::x_SetupBlastOptions(), CVDBBlastnApp::x_SetupLocalVDBSearch(), CVDBTblastnApp::x_SetupLocalVDBSearch(), CMakeBlastDBApp::x_ShouldParseSeqIds(), CBlastDBCmdApp::x_UseLongSeqIds(), CNetScheduleDApp::x_WritePid(), CNetStorageDApp::x_WritePid(), CAnnotWriterApp::xAssemblyAccession(), CAnnotWriterApp::xAssemblyName(), seqsubmit_split::CSeqSubSplitter::xGetInputObject(), seqsubmit_split::CSeqSubSplitter::xInitInputStream(), CAnnotWriterApp::xProcessInputObject(), and seqsubmit_split::CSeqSubSplitter::xTryProcessSeqEntries().
|
inline |
Get the application's cached unprocessed command-line arguments.
Definition at line 755 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_Arguments.
Referenced by COMSSA::AppInit(), CSamplePhoneHomePolicy::Apply(), CNcbiApplogApp::Cmd_Generate(), CCgiStatistics::Compose_ProgramName(), CNcbiApplicationAPI::FindProgramExecutablePath(), CMetaRegistry::GetDefaultSearchPath(), CDemoContigAssemblyApp::Init(), CNgAlignApp::Init(), CSRSearchApplication::Init(), CDemoSeqQaApp::Init(), CBlastFormatterApp::Init(), CSeedTopApp::Init(), CBlastDBAliasApp::Init(), CBlastdbConvertApp::Init(), CBlastDBCmdApp::Init(), CMakeBlastDBApp::Init(), CMakeClusterDBApp::Init(), CBlastFormatterVdbApp::Init(), CBlastVdbCmdApp::Init(), CCompartApp::Init(), CCompactSAMApplication::Init(), CExonSelectorApplication::Init(), CCgi2RCgiApp::Init(), CAppHitFilter::Init(), CIdMapperApp::Init(), CAppNWA::Init(), CPsgClientApp::Init(), CSplignApp::Init(), CSrcChkApp::Init(), seqsubmit_split::CSeqSubSplitter::Init(), CVecScreenApp::Init(), CDbapiDriverSampleApp::Init(), CDbapiSampleApp::Init(), CGBProjectTool::Init(), CNcbiApplogApp::Init(), CTax4BlastDemo::Init(), CHugeFileDemoApp::Init(), CDbapiTest::Init(), CPsgClientSampleApp::Init(), CSdbapiTest::Init(), pub_report::CPubReportApp::Init(), CGridWorkerApp::Init(), CThreadedApp::Init(), CRemoteCgiApp::Init(), CAVApp::Init(), CAlignCleanupApplication::Init(), CProSplignApp::Init(), CTestCompartApplication::Init(), CBlastInputDemoApplication::Init(), CGumbelParamsApplication::Init(), CCkblastindexApplication::Init(), CClustererApplication::Init(), CMultiApplication::Init(), COmssa2pepxmlApplication::Init(), CAdapterSearchApplication::Init(), CCpGDemoApp::Init(), CRegexpLocApp::Init(), CXcompareAnnotsApplication::Init(), CWinMaskDemoApplication::Init(), CAgpValidateApplication::Init(), CAgpconvertApplication::Init(), CAsnCacheTestApplication::Init(), CCacheIndexCopyApp::Init(), CConcatSeqEntriesApplication::Init(), CAsnCacheDumpSeqIdsApplication::Init(), CPrimeCacheApplication::Init(), CReadIndexSpeedApp::Init(), CAsnSubCacheCreateApplication::Init(), CWalkAsnCacheApplication::Init(), CBDBEnvKeeperApp::Init(), CBiosampleChkApp::Init(), CBlastDbCheckApplication::Init(), BlastdbCopyApplication::Init(), CConvert2BlastMaskApplication::Init(), CGuideTreeApplication::Init(), Cn3DNoWin::Init(), CCompartApplication::Init(), CConversionApp::Init(), CDBLBClientApp::Init(), CDustMaskApplication::Init(), CFeatImportApp::Init(), CFormatGuessApp::Init(), CGapStatsApplication::Init(), CHgvsToSeqfeatConverter::Init(), CId1FetchApp::Init(), CId2FetchApp::Init(), CIdfetchApplication::Init(), CMultipatternApp::Init(), CNcbiEncryptApp::Init(), CNetScheduleDApp::Init(), CNetStorageDApp::Init(), CNetStorageGCApp::Init(), CNmer_repeatsApplication::Init(), CObjExtractApp::Init(), CDemoApp::Init(), CReadBlastApp::Init(), SegMaskerApplication::Init(), CMytestApplication::Init(), CSplitCacheApp::Init(), CStreamTestApp::Init(), subfuse::CSubfuseApp::Init(), CWig2tableApplication::Init(), CWinMaskApplication::Init(), CProjBulderApp::Init(), CPsgPerfApplication::Init(), CNcbiTestApplication::Init(), CBDB_CacheVerifyApp::Init(), CBDB_FileDumperApp::Init(), CRunTestApplication::Init(), CMysqlDemoApp::Init(), CObjConvProfile::Init(), CAppJobTestApplication::Init(), CTestDispatchApp::Init(), CMakeScoreMethodApp::Init(), CColumnarVCFReaderApp::Init(), CEntrez2ClientApp::Init(), CAlnMrgApp::Init(), CAlnVwrApp::Init(), CFetchGBProjectApp::Init(), CSampleAlnmgrApplication::Init(), CSampleAsnApplication::Init(), CSampleBasicApplication::Init(), CBlastDemoApplication::Init(), CBlastSampleApplication::Init(), VSRunSampleApplication::Init(), CDbapiSimpleApp::Init(), CEUtilsApp::Init(), CHttpSessionApp::Init(), CSampleLds2Application::Init(), CMultiCommandApplication::Init(), CSampleNetCacheClient::Init(), CGridClientSampleApp::Init(), CSampleNetScheduleClient::Init(), CSampleNetScheduleNode::Init(), CRemoteAppClientSampleApp::Init(), CSampleObjectsApplication::Init(), CEditBioseqSampleApp::Init(), CFeatTreeSampleApp::Init(), CSampleObjmgrApplication::Init(), CSdbapiSimpleApp::Init(), CBssInfoApp::Init(), CProcessHighestSeObjs::Init(), CSeqAnnotSplicerApp::Init(), CSampleSoapClientApplication::Init(), CSampleLibtestApplication::Init(), CBam2GraphApp::Init(), CConvImageApp::Init(), CImageDemoApp::Init(), CSubImageApp::Init(), CBlastFormatterApp::PrintFormattedOutput(), CBlastFormatterVdbApp::PrintFormattedOutput(), CNcbiApplogApp::PrintTokenInformation(), CCommandArgDescriptions::PrintUsage(), CNcbiApplogApp::Redirect(), CDeltaBlastApp::Run(), CPsiBlastApp::Run(), CTblastxApp::Run(), CMagicBlastApp::Run(), CTest::Run(), CVDBBlastnApp::Run(), CVDBTblastnApp::Run(), Cn3DNoWin::Run(), CTestApplication::Run(), CAdvancedAlignCleanup::SetParams(), CNcbiApplicationAPI::SetupArgDescriptions(), CCgiApplication::ShouldRestart(), CNetScheduleHandler::x_ProcessHealth(), CFastCgiApplicationMT::x_RunFastCGI(), CBlastnApp::x_RunMTBySplitDB(), CBlastpApp::x_RunMTBySplitDB(), CBlastxApp::x_RunMTBySplitDB(), CRPSBlastApp::x_RunMTBySplitDB(), CRPSTBlastnApp::x_RunMTBySplitDB(), CTblastnApp::x_RunMTBySplitDB(), CBlastnApp::x_RunMTBySplitQuery(), CBlastpApp::x_RunMTBySplitQuery(), CBlastxApp::x_RunMTBySplitQuery(), CRPSBlastApp::x_RunMTBySplitQuery(), CRPSTBlastnApp::x_RunMTBySplitQuery(), CTblastnApp::x_RunMTBySplitQuery(), CNCBIwxApplication::x_SetupArgDescriptions(), CTestBMApp::x_SetupArgDescriptions(), CMakeProfileDBApp::x_SetupArgDescriptions(), CCgiSampleApplication::x_SetupArgs(), CFastCgiMTSampleApplication::x_SetupArgs(), CGridCgiSampleApplication::x_SetupArgs(), and CNcbiApplicationAPI::x_TryInit().
|
inline |
Definition at line 776 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_Config.
|
inline |
Get the application's cached configuration parameters (read-only).
Application also can use protected GetRWConfig() to get read-write
Definition at line 770 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_Config.
Referenced by CCgiApplication::AddLBCookie(), NWinHook::CApiHookMgr::CApiHookMgr(), CBlastDBExtractor::CBlastDBExtractor(), CBlastFormat::CBlastFormat(), CConnIniter::CConnIniter(), CDataSourceInitializer::CDataSourceInitializer(), CFastaBioseqSource::CFastaBioseqSource(), CGI2GRID_ComposeHtmlPage(), CGridRPCBaseClient< CAsnBinCompressed >::CGridRPCBaseClient(), CCgiApplication::CheckMemoryLimit(), CCgiStatistics::Compose(), CCgiStatistics::Compose_Entries(), CDBLB_ServiceMapper::ConfigureFromRegistry(), CDBConnectionFactory::ConfigureFromRegistry(), CDBUDRandomMapper::ConfigureFromRegistry(), CDBUDPriorityMapper::ConfigureFromRegistry(), CDBUniversalMapper::ConfigureFromRegistry(), CPluginManager< TClass >::CPluginManager(), CProjectsLstFileFilter::CProjectsLstFileFilter(), CPSGDataLoader_Impl::CPSGDataLoader_Impl(), CCgiApplication::CreateContextWithFlags_Default(), CCgiApplication::CreateFastCGIWatchFile(), CGraphCacheFactory::CreateObject(), CSampleNetCacheClient::DemoIWriterIReader(), CSampleNetCacheClient::DemoStream(), CSeqFormatter::DumpAll(), EnabledDelayBuffers(), CProjBulderApp::EnumOpt(), CIgBlastArgs::ExtractAlgorithmOptions(), CDebugArgs::ExtractAlgorithmOptions(), FindBlastDbPath(), CProjBulderApp::FindDepGraph(), g_GetConfigDouble(), g_GetConfigFlag(), g_GetConfigInt(), g_GetConfigString(), CSeqDBAtlas::GenerateSearchPath(), CRmtScriptTimeout::Get(), CProjBulderApp::GetBuildConfigs(), CCgiContext::GetConfig(), CProjBulderApp::GetConfigureMacro(), CProjBulderApp::GetDatatoolCommandLine(), CProjBulderApp::GetDatatoolId(), CProjBulderApp::GetDatatoolPathForApp(), CProjBulderApp::GetDatatoolPathForLib(), GetDefaultTmsContext(), CWinMaskerFileStorage::GetEnvPath(), CCgiApplication::GetFastCGIChannelErrors(), CCgiApplication::GetFastCGIComplete_Request_On_Sigterm(), CCgiApplication::GetFastCGIDebug(), CCgiApplication::GetFastCGIHonorExitRequest(), CCgiApplication::GetFastCGIIterations(), CCgiApplication::GetFastCGIMTMaxThreads(), CCgiApplication::GetFastCGIStandaloneServer(), CCgiApplication::GetFastCGIStatLog(), CCgiApplication::GetFastCGIStopIfFailed(), CCgiApplication::GetFastCGIWatchFileRestartDelay(), CCgiApplication::GetFastCGIWatchFileTimeout(), CGencollSvc::GetGenCollService(), GetLinksURL(), CCgiApplication::GetLogOpt(), CProjBulderApp::GetMetaDataFiles(), CProjBulderApp::GetProjectTreeInfo(), CProjBulderApp::GetRegSettings(), CCgiSessionSampleApplication::GetSessionStorage(), CSysLog::HonorRegistrySettings(), CSeqTextDemoDlg::Init(), CCgiApplication::Init(), CGridClientApp::Init(), CSDBAPI::Init(), CGlCgiImageApplication::Init(), CCgiRedirectApplication::Init(), CDemoApp::Init(), CCgiApplicationCached::Init(), CGridCgiApplication::InitGridClient(), CProjBulderApp::ParseArguments(), CProjBulderApp::ProcessLocationMacros(), impl::CDriverContext::ReadDBConfParams(), CSrcChkApp::Run(), CAnnotWriterApp::Run(), CAsn2FastaApp::Run(), CAsn2FlatApp::Run(), CCleanupApp::Run(), CCgiApplication::Run(), CNCBIwxApplication::Run(), CAgpValidateApplication::Run(), CBDBEnvKeeperApp::Run(), CId2FetchApp::Run(), CNetScheduleDApp::Run(), CNetStorageDApp::Run(), CNetStorageGCApp::Run(), CDemoApp::Run(), CSampleAlnmgrApplication::Run(), CEditBioseqSampleApp::Run(), CSampleObjmgrApplication::Run(), CTrackMgrClient::s_Ask(), s_CreateISynRegistry(), s_GetConfigString(), s_GetMandatoryFields(), s_init_LookForMultipleIsolates(), s_init_UseGeoLocNameForCountry(), s_InitAllKNS(), CGraphTrack::s_InitICache(), CBrowserUtils::SendToBrowser(), ColumnarVcfCache::SetInfoFields(), CFeaturePanel::SetInputObject(), CBiosampleChkApp::Setup(), CSplitCacheApp::SetupCache(), SEutilsParams::SEutilsParams(), CMakeBlastDBApp::x_BuildDatabase(), CNetStorageGCApp::x_CheckExpiration(), CDebugDumpViewer::x_CheckLocation(), CODBC_Connection::x_Connect(), CGBDataLoader_Native::x_CreateDriver(), CNetStorageHandler::x_CreateObjectStream(), CQueueDataBase::x_GetConfigQueues(), CNetCacheBlobFetchApp::x_GetInitString(), CSDB_Decryptor::x_GetKey(), CNetStorageHandler::x_GetObject(), NSNPWebServices::x_GetSearchHost(), CDBLBClientApp::x_GetServiceMapper(), CGuiObjectInfoVariation::x_GetTooltipService(), CRmtFileStatus::x_Init(), SDataLoaderConfig::x_Init(), CBlastFormat::x_InitAlignTemplates(), CBlastFormat::x_InitDeflineTemplates(), CDataCrawlerCache::x_InitICache(), CEutilsClient::x_InitParams(), CDiagContext::x_LogEnvironment(), CNcbiApplicationAPI::x_LogOptions(), CNetStorageHandler::x_ProcessConfiguration(), CNetScheduleHandler::x_ProcessGetConf(), CCleanupApp::x_ProcessOneFile(), CNetStorageHandler::x_ProcessReconfigure(), CNetScheduleHandler::x_ProcessReloadConfig(), CNcbiTestApplication::x_ReadConfiguration(), CNSTDatabase::x_ReadDbAccessInfo(), CNetStorageGCApp::x_RemoveObjects(), CDataLoadersUtil::x_SetupASNCacheDataLoader(), CDataLoadersUtil::x_SetupVDBDataLoader(), CSequenceSearchForm::x_UpdateFileList(), COrfSearchForm::x_UpdateKozak(), CBlastDBCmdApp::x_UseLongSeqIds(), and CRemoteUpdater::xSetFromConfig().
Get the full path to the configuration file (if any) we ended up using.
Definition at line 786 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_ConfigPath.
Referenced by CProjBulderApp::GetSite(), CProjBulderApp::ParseArguments(), CNcbiApplicationAPI::ReloadConfig(), CNetScheduleDApp::Run(), CNetStorageDApp::Run(), CServiceThread::x_CheckConfigFile(), CNetStorageServiceThread::x_CheckConfigFile(), CNetScheduleHandler::x_ProcessHealth(), CNetStorageHandler::x_ProcessReconfigure(), CNetScheduleHandler::x_ProcessReloadConfig(), and CCgiSessionSampleApplication::x_ShowConfigFile().
|
inline |
Get the application's cached environment.
Definition at line 760 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_Environ.
Referenced by CMsvcConfigure::AnalyzeDefines(), CGRPCServerCallbacks::BeginRequest(), BlastFindMatrixPath(), BOOST_AUTO_TEST_CASE(), CCgiUserAgent::CCgiUserAgent(), CNcbiApplogApp::Cmd_Health(), CreateConfigurableFile(), FindBlastDbPath(), CSampleLibraryObject::FindInPath(), CNcbiApplicationAPI::FindProgramExecutablePath(), CProjBulderApp::GenerateMsvcProjects(), CCgiSampleApplication::GetCdVersion(), CArgDescDefault::GetDefaultValue(), SGridWorkerNodeImpl::GetEnvironment(), CSeqTestApplication::Init(), CTestBMApp::Init(), CQueryParseTree::Parse(), CCgiSampleApplication::ProcessPrintEnvironment(), CNcbiApplogApp::Redirect(), CGridCommandLineInterfaceApp::Run(), CNcbiApplogApp::Run(), CCgiApplication::Run(), ASNIOTestApp::Run(), s_init_LookForMultipleIsolates(), s_init_NewTaxVal(), s_init_UseGeoLocNameForCountry(), CMsvcConfigure::WriteBuildVer(), CMakeBlastDBApp::x_BuildDatabase(), CRequestContext::x_LoadEnvContextProperties(), CDiagContext::x_LogEnvironment(), and CNcbiApplicationAPI::x_LogOptions().
|
overridevirtual |
Translate from the error code value to its string representation.
Reimplemented from CCoreException.
Definition at line 1786 of file ncbiapp.cpp.
References CAppException::eLoadConfig, CAppException::eNoRegistry, CAppException::eSecond, CAppException::eSetupDiag, CAppException::eUnsetArgs, CCoreException::GetErrCode(), and CException::GetErrCodeString().
const CVersionAPI & CNcbiApplicationAPI::GetFullVersion | ( | void | ) | const |
Get the program version information.
Definition at line 1202 of file ncbiapp.cpp.
References CNcbiApplicationAPI::m_Version.
Referenced by CNcbiApplicationAPI::AppMain(), CDataTool::GenerateCode(), CCgiApplication::PreparseArgs(), CDiagContext_Extra::PrintNcbiAppInfoOnRequest(), CDiagContext_Extra::PrintNcbiAppInfoOnStart(), CCgiRequestProcessor::ProcessVersionRequest(), CAsn2FastaApp::Run(), CAsn2FlatApp::Run(), and SGridWorkerNodeImpl::Run().
INcbiIdler* GetIdler | ( | EOwnership | ownership = eNoOwnership | ) |
Return currently installed idler or NULL.
Update idler ownership according to the flag.
Definition at line 1852 of file ncbiapp.cpp.
References s_IdlerWrapper.
|
staticprotected |
Definition at line 119 of file ncbiapp.cpp.
References s_InstanceRWLock.
Referenced by CNcbiApplicationAPI::CNcbiApplicationAPI(), CNcbiApplicationGuard::CNcbiApplicationGuard(), and CNcbiApplicationAPI::~CNcbiApplicationAPI().
|
static |
Mutex for application singleton object.
Lock this mutex when calling Instance()
Definition at line 111 of file ncbiapp.cpp.
const SDiagMessage & CNcbiToolkit_LogMessage::GetNativeToolkitMessage | ( | void | ) | const |
Get all of the message's data – as provided natively by the Toolkit.
Definition at line 80 of file ncbi_toolkit.cpp.
References ncbi::CNcbiToolkit_LogMessage::m_Msg.
|
inlineprotected |
Return pointer to current Phone Home Policy or NULL.
Definition at line 645 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_PhoneHomePolicy.
Get the application's "display" name.
Get name of this application, suitable for displaying or for using as the base name for other files. Will be the 'name' argument of AppMain if given. Otherwise will be taken from the actual name of the application file or argv[0].
Definition at line 806 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_ProgramDisplayName.
Referenced by CCgiRequest::CalcChecksum(), CRemoteAppLauncher::CRemoteAppLauncher(), CWindowsCmdErrorHandler::CWindowsCmdErrorHandler(), CDataTool::GenerateCode(), SGridWorkerNodeImpl::GetAppName(), CNcbiApplicationAPI::GetAppName(), CUsageReportAPI::GetAppName(), SNetServiceImpl::Init(), CThreadInPool_ForServer::Main(), CAsyncDiagThread::Main(), CCgiApplication::PreparseArgs(), CAsn2FastaApp::Run(), CAsn2FlatApp::Run(), s_GetAppName(), impl::s_TransformLoginData(), CArgDescriptions::SetUsageContext(), CNCBIwxApplication::x_Init_wxApplication(), CNCBIwxApplication::x_SetupArgDescriptions(), and CMultiReaderApp::xSetFormat().
|
inline |
Get the application's executable path.
The path to executable file of this application. Return empty string if not possible to determine this path.
Definition at line 812 of file ncbiapp_api.hpp.
References eFollowLinks, CNcbiApplicationAPI::m_ExePath, and CNcbiApplicationAPI::m_RealExePath.
Referenced by CNcbiApplicationAPI::AppStart(), createAnnot(), CNcbiApplicationAPI::GetAppName(), GetDefaultLogLocation(), CCgiApplication::GetDefaultLogPath(), CTestBMApp::Init(), SNetServiceImpl::MakeAuthString(), CDiagContext_Extra::PrintNcbiAppInfoOnStart(), CGetStatisticsProcessor::Process(), CCgiRequestProcessor::ProcessHelpRequest(), COMSSA::Run(), CNcbiApplogApp::Run(), COmssa2pepxmlApplication::Run(), CDiagContext::SetupDiag(), SNetStorageRPC::SNetStorageRPC(), SNetStorage::SConfig::Validate(), CNcbiApplicationAPI::x_LogOptions(), and CNetScheduleHandler::x_ProcessHealth().
|
inlineprotected |
Get the application's cached configuration parameters, accessible for read-write for an application's internal use only.
Definition at line 781 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_Config.
Referenced by CFakeApplication::CFakeApplication(), CNcbiTestApplication::GetTestRWConfig(), CCgi2RCgiApp::Init(), CRemoteCgiApp::Init(), CStreamTestApp::Init(), CHelloApp::LoadResource(), CProjBulderApp::ParseArguments(), CCgiApplication::ProcessHttpReferer(), CGridCgiApplication::ProcessRequest(), CNcbiApplicationAPI::ReloadConfig(), CGridCommandLineInterfaceApp::Run(), CAsnSubCacheCreateApplication::Run(), CDemoApp::Run(), CGridCommandLineInterfaceApp::SetUp_NetCache(), and CSplitCacheApp::SetupCache().
|
inline |
Get a const reference to the current value.
If NULL, the reference is a copy of the default value or throw (depending on TNullToValue implementation). In any case the IsNull state is unchanged.
Definition at line 703 of file ncbimisc.hpp.
Referenced by CGBLoaderParams::GetEnableCDD(), CReaderParams::GetEnableCDD(), CGBLoaderParams::GetEnableSNP(), CReaderParams::GetEnableSNP(), CGBLoaderParams::GetEnableWGS(), CReaderParams::GetEnableWGS(), CPSGL_Blob_Processor::GetWaitDeadline(), operator<<(), ncbi::grid::netcache::search::SBlobInfoImpl::operator[](), CPSG_BlobId::Repr(), CJsonResponse::Set(), CPSG_Request_IpgResolve::x_GetAbsPathRef(), CPSG_Request_IpgResolve::x_GetId(), and CNetStorageObjectLoc::x_Pack().
CVersionInfo CNcbiApplicationAPI::GetVersion | ( | void | ) | const |
Get the program version information.
Definition at line 1197 of file ncbiapp.cpp.
References CVersionAPI::GetVersionInfo(), and CNcbiApplicationAPI::m_Version.
Referenced by CSamplePhoneHomePolicy::Apply(), BlastdbCopyApplication::BlastdbCopyApplication(), CBlastDBAliasApp::CBlastDBAliasApp(), CBlastDbCheckApplication::CBlastDbCheckApplication(), CBlastDBCmdApp::CBlastDBCmdApp(), CBlastdbConvertApp::CBlastdbConvertApp(), CBlastFormatterApp::CBlastFormatterApp(), CBlastFormatterVdbApp::CBlastFormatterVdbApp(), CBlastnApp::CBlastnApp(), CBlastpApp::CBlastpApp(), CBlastVdbCmdApp::CBlastVdbCmdApp(), CBlastxApp::CBlastxApp(), CConvert2BlastMaskApplication::CConvert2BlastMaskApplication(), CDeltaBlastApp::CDeltaBlastApp(), CMagicBlastApp::CMagicBlastApp(), CMakeBlastDBApp::CMakeBlastDBApp(), CMakeClusterDBApp::CMakeClusterDBApp(), CMakeProfileDBApp::CMakeProfileDBApp(), CNcbiApplogApp::Cmd_Health(), CMultiApplication::CMultiApplication(), CPsiBlastApp::CPsiBlastApp(), CRPSBlastApp::CRPSBlastApp(), CRPSTBlastnApp::CRPSTBlastnApp(), CTblastnApp::CTblastnApp(), CTblastxApp::CTblastxApp(), CVDBBlastnApp::CVDBBlastnApp(), CVDBTblastnApp::CVDBTblastnApp(), CProjBulderApp::GenerateUnixProjects(), CUsageReportAPI::GetAppVersion(), CFileModules::GetRefInfo(), CIgBlastnApp::Init(), CIgBlastpApp::Init(), CAgpValidateApplication::Init(), CSampleSoapServerApplication::Init(), CCgiRequestProcessor::ProcessVersionRequest(), CMagicBlastApp::Run(), CNcbiApplogApp::Run(), CProjBulderApp::Run(), s_InitAllKNS(), SCommonDumpHeader::SCommonDumpHeader(), CTable2AsnContext::UpdateSubmitObject(), CQueueDataBase::x_CheckOpenPreconditions(), and CQueueDataBase::x_CreateStorageVersionFile().
|
inline |
Check if the config file has been loaded.
Definition at line 791 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_ConfigPath.
Referenced by s_GetConfigString().
|
protected |
Set the hide mask for the Hide Std Flags.
Definition at line 1325 of file ncbiapp.cpp.
References CNcbiApplicationAPI::m_HideArgs.
Referenced by CEntrez2ClientApp::CEntrez2ClientApp(), CBlastFormatterApp::Init(), CBlastnApp::Init(), CBlastpApp::Init(), CBlastxApp::Init(), CDeltaBlastApp::Init(), CPsiBlastApp::Init(), CRPSBlastApp::Init(), CRPSTBlastnApp::Init(), CSeedTopApp::Init(), CTblastnApp::Init(), CTblastxApp::Init(), CBlastDBAliasApp::Init(), CBlastdbConvertApp::Init(), CBlastDBCmdApp::Init(), CMakeBlastDBApp::Init(), CMakeClusterDBApp::Init(), CBlastFormatterVdbApp::Init(), CBlastVdbCmdApp::Init(), CCompartApp::Init(), CAppHitFilter::Init(), CIgBlastnApp::Init(), CIgBlastpApp::Init(), CMagicBlastApp::Init(), CAppNWA::Init(), CRMBlastnApp::Init(), CSplignApp::Init(), CVecScreenApp::Init(), CTax4BlastDemo::Init(), CBlastInputDemoApplication::Init(), CGumbelParamsApplication::Init(), CBlastKmerApplication::Init(), CBlastKmerBuildIndexApplication::Init(), CClustererApplication::Init(), CMultiApplication::Init(), CAgpconvertApplication::Init(), CBlastDbCheckApplication::Init(), BlastdbCopyApplication::Init(), CConvert2BlastMaskApplication::Init(), CGuideTreeApplication::Init(), CVDBBlastnApp::Init(), CVDBTblastnApp::Init(), CDustMaskApplication::Init(), CNmer_repeatsApplication::Init(), SegMaskerApplication::Init(), CWinMaskApplication::Init(), CBlastSampleApplication::Init(), VSRunSampleApplication::Init(), and CMakeProfileDBApp::x_SetupArgDescriptions().
|
virtual |
Implements INcbiIdler.
Definition at line 1799 of file ncbiapp.cpp.
References DiagHandler_Reopen().
|
pure virtual |
Implemented in CDefaultIdler.
Referenced by CIdlerWrapper::RunIdler().
|
inlinevirtual |
Initialize policy/reporting API.
Reimplemented in CSamplePhoneHomePolicy.
Definition at line 90 of file phone_home_policy.hpp.
|
virtual |
Initialize the application.
The default behavior of this is "do nothing". If you have special initialization logic that needs to be peformed, then you must override this method with your own logic.
Reimplemented in CFastCgiMTSampleApplication, CCgiApplicationCached, CSubImageApp, CImageDemoApp, CConvImageApp, CCacheDemoApp, CBam2GraphApp, CDataTool, CSampleLibtestApplication, CSampleSoapServerApplication, CSampleSoapClientApplication, CSeqAnnotSplicerApp, CProcessHighestSeObjs, CBssInfoApp, CSdbapiSimpleApp, CSampleObjmgrApplication, CFeatTreeSampleApp, CEditBioseqSampleApp, CSampleObjectsApplication, CRemoteAppClientSampleApp, CCgiSampleApplication, CSampleNetScheduleNode, CSampleNetScheduleClient, CGridClientSampleApp, CGridCgiSampleApplication, CSampleNetCacheClient, CCgiSampleApplication, CMultiCommandApplication, CSampleLds2Application, CHttpSessionApp, CEUtilsApp, CCgiSampleApplication, CDbapiSimpleApp, CCgiSampleApplication, VSRunSampleApplication, CBlastDemoApplication, CBlastSampleApplication, CBlastDemoApplication, CSampleBasicApplication, CSampleAsnApplication, CSampleAlnmgrApplication, CAnalyzeShiftApp, CFetchGBProjectApp, CAce2AsnApp, CAlnVwrApp, CAlnMrgApp, CAlnTestApp, CAlnBuildApp, CClientGenomicCollectionsSvcApplication, CEntrez2ClientApp, CApp, CColumnarVCFReaderApp, CMakeScoreMethodApp, CTestDispatchApp, CAppJobTestApplication, CTestBMApp, CObjConvProfile, CTestApplication, CMysqlDemoApp, CRunTestApplication, CRunTestApplication, CBDB_MergeTest, CBDB_SplitTest, CBDB_FileDumperApp, CBDB_BLobDemo1, CBDB_PhoneBookDemo3, CBDB_PhoneBookDemo2, CBDB_PhoneBookDemo1, CBDB_CacheVerifyApp, CNcbiTestApplication, CPsgPerfApplication, CProjBulderApp, CWinMaskApplication, CWig2tableApplication, subfuse::CSubfuseApp, CStreamTestApp, CSplitCacheApp, CMytestApplication, SegMaskerApplication, CReadBlastApp, CDemoApp, CDemoApp, CObjExtractApp, CNmer_repeatsApplication, CNetStorageGCApp, CNetStorageDApp, CNetScheduleDApp, CNcbiEncryptApp, CMultipatternApp, CIdfetchApplication, CId2FetchApp, CId1FetchApp, CId1FetchApp, CHgvsToSeqfeatConverter, CGi2TaxIdApp, CGffDeconcatApp, CGapStatsApplication, CFormatGuessApp, CFeatImportApp, CDustMaskApplication, CDBLBClientApp, CConversionApp, CCompartApplication, Cn3DNoWin, CBsDiffApp, CVDBTblastnApp, CVDBBlastnApp, CGuideTreeApplication, CConvert2BlastMaskApplication, BlastdbCopyApplication, CBlastDbCheckApplication, CBiosampleChkApp, CBDBEnvKeeperApp, CWalkAsnCacheApplication, CAsnSubCacheCreateApplication, CReadIndexSpeedApp, CPrimeCacheApplication, CAsnCacheDumpSeqIdsApplication, CConcatSeqEntriesApplication, CCacheIndexCopyApp, CAsnCacheTestApplication, CAsn2Asn, CAgpconvertApplication, CAgpValidateApplication, CWinMaskDemoApplication, CXcompareAnnotsApplication, CRegexpLocApp, CGeneModelDemoApp, CCpGDemoApp, CAdapterSearchApplication, COmssa2pepxmlApplication, CLocalFinderApp, CMultiApplication, CMultiApplication, CClustererApplication, CBlastKmerBuildIndexApplication, CBlastKmerApplication, CCkblastindexApplication, CGumbelParamsApplication, CBlastInputDemoApplication, CDemoScoreBuilderApp, CTestCompartApplication, CProSplignApp, CMergeyApp, CAlignCleanupApplication, CAVApp, CRemoteCgiApp, CGridCgiApplication, CCgiRedirectApplication, CNCBIwxApplication, CGlCgiImageApplication, CThreadedApp, CGridWorkerApp, CGridClientApp, CCgiApplication, CTestRemoteUpdaterApplication, CPubmedFetchApplication, CPubmedFetchApplication, CTbl2AsnApp, CPsgCgiApp, pub_report::CPubReportApp, CPrt2FsmApp, CMultiReaderApp, CDiscRepApp, CAsnvalApp, CCleanupApp, CAsn2FlatApp, CAsn2FastaApp, CAnnotWriterApp, CSdbapiTest, CPsgClientSampleApp, CDbapiTest, CUsageReportPhoneHomeSampleApp, CUsageReportSampleApp, CHugeFileDemoApp, CTax4BlastDemo, CNcbiApplogApp, CSeqTestApplication, CGBProjectTool, CTestGuiRegistryApp, CDbapiSampleApp, CDbapiDriverSampleApp, CVecScreenApp, seqsubmit_split::CSeqSubSplitter, CSrcChkApp, CSplignApp, CRMBlastnApp, CPsgClientApp, CAppNWA, CMagicBlastApp, CIgBlastpApp, CIgBlastnApp, CIdMapperApp, CAppHitFilter, CCgi2RCgiApp, CExonSelectorApplication, CCompactSAMApplication, CCompartApp, CBlastVdbCmdApp, CBlastFormatterVdbApp, CMakeProfileDBApp, CMakeClusterDBApp, CMakeBlastDBApp, CBlastDBCmdApp, CBlastDBCmdApp, CBlastdbConvertApp, CBlastDBAliasApp, CTblastxApp, CTblastnApp, CSeedTopApp, CRPSTBlastnApp, CRPSBlastApp, CPsiBlastApp, CDeltaBlastApp, CBlastxApp, CBlastpApp, CBlastnApp, CBlastFormatterApp, CDemoSeqQaApp, COMSSAMerge, COMSSABase, CReadresult, CSRSearchApplication, CMkIndexApplication, CNgAlignApp, and CDemoContigAssemblyApp.
Definition at line 286 of file ncbiapp.cpp.
Referenced by CCgiApplication::Init(), CGridClientApp::Init(), CGridWorkerApp::Init(), CHttpSessionApp::Init(), CSampleSoapClientApplication::Init(), and CNcbiApplicationAPI::x_TryInit().
|
static |
Singleton method.
Track the instance of CNcbiApplicationAPI, and throw an exception if an attempt is made to create another instance of the application.
Definition at line 127 of file ncbiapp.cpp.
References CNcbiApplicationAPI::m_Instance.
Referenced by BOOST_AUTO_TEST_CASE(), CBlastDBExtractor::CBlastDBExtractor(), CSeqDBAtlas::GenerateSearchPath(), GetDefaultTmsContext(), CNcbiApplication::Instance(), CArgDescriptions::SetUsageContext(), and CRemoteUpdater::xSetFromConfig().
|
static |
Singleton method.
Get instance of the application and prevent its destruction until the lock is destroyed.
Definition at line 133 of file ncbiapp.cpp.
References CNcbiApplicationAPI::CNcbiApplicationGuard, and CNcbiApplicationAPI::m_Instance.
Referenced by CBDB_Cache_OnAppExit::AddOnExitCallback(), CBDB_Env_OnAppExit::AddOnExitCallback(), CAutoEnvironmentVariable::CAutoEnvironmentVariable(), CConnIniter::CConnIniter(), CGridRPCBaseClient< CAsnBinCompressed >::CGridRPCBaseClient(), CID2SNPProcessor_Impl::CID2SNPProcessor_Impl(), CJaegerTracer::CJaegerTracer(), CEnvironmentCleaner::Clean(), CDBLB_ServiceMapper::ConfigureFromRegistry(), CPluginManager< TClass >::CPluginManager(), CPSGDataLoader_Impl::CPSGDataLoader_Impl(), EnabledDelayBuffers(), CNcbiApplicationAPI::FindProgramExecutablePath(), g_GetConfigDouble(), g_GetConfigFlag(), g_GetConfigInt(), g_GetConfigString(), CNcbiApplicationAPI::GetAppName(), CUsageReportAPI::GetAppName(), CUsageReportAPI::GetAppVersion(), CMetaRegistry::GetDefaultSearchPath(), SNetServiceImpl::Init(), CThreadInPool_ForServer::Main(), CAsyncDiagThread::Main(), SNetScheduleAPIImpl::MakeAuthString(), SNetServiceImpl::MakeAuthString(), CPipeHandle::Open(), CQueryParseTree::Parse(), CGetStatisticsProcessor::Process(), s_CreateISynRegistry(), s_GetAppName(), s_GetConfigString(), s_GetTracer(), s_InitAllKNS(), s_InitProxyConfig(), CDiagContext::SetupDiag(), SNetStorageRPC::SNetStorageRPC(), SUvNgHttp2_UserAgentImpl::SUvNgHttp2_UserAgentImpl(), CParam< TDescription >::sx_GetDefault(), CGBDataLoader_Native::x_CreateDriver(), CEutilsClient::x_InitParams(), CRequestContext::x_LoadEnvContextProperties(), and CDiagContext::x_LogEnvironment().
|
inline |
Constructor.
Definition at line 66 of file phone_home_policy.hpp.
|
inline |
Check if it is a test run.
Definition at line 824 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_DryRun.
|
inlinevirtual |
Return current policy status (enabbed/disabled).
Definition at line 98 of file phone_home_policy.hpp.
References IPhoneHomePolicy::m_IsEnabled.
Referenced by CSamplePhoneHomePolicy::Apply(), and CSamplePhoneHomePolicy::Restore().
|
inline |
Check if the object is unassigned.
Definition at line 686 of file ncbimisc.hpp.
Referenced by CVariant::Char(), SPSG_Nullable< size_t >::Cmp(), CPSG_Request_IpgResolve::CPSG_Request_IpgResolve(), CVariant::Double(), CVariant::Float(), CPSGL_Blob_Processor::GetWaitDeadline(), CGBLoaderParams::IsSetEnableCDD(), CReaderParams::IsSetEnableCDD(), CGBLoaderParams::IsSetEnableSNP(), CReaderParams::IsSetEnableSNP(), CGBLoaderParams::IsSetEnableWGS(), CReaderParams::IsSetEnableWGS(), CVariant::LongChar(), operator<<(), CPSG_BlobId::Repr(), CJsonResponse::Set(), CNetStorageObjectLoc::ToJSON(), CVariant::VarChar(), CVariant::VarCharMax(), CPSG_Request_IpgResolve::x_GetAbsPathRef(), CPSG_Request_IpgResolve::x_GetId(), CHttpRequest::x_InitConnection(), and CNetStorageObjectLoc::x_Pack().
Definition at line 497 of file ncbimisc.hpp.
Referenced by CSocketReaderWriter::Pushback(), and CStreamReader::Pushback().
size_t CNcbiToolkit_LogMessage::Line | ( | void | ) | const |
Get line number in which message was originated.
Definition at line 124 of file ncbi_toolkit.cpp.
References SDiagMessage::m_Line, and ncbi::CNcbiToolkit_LogMessage::m_Msg.
|
protectedvirtual |
Load settings from the configuration file to the registry.
CNcbiApplicationAPI::LoadConfig(reg, conf) just calls LoadConfig(reg, conf, IRegistry::fWithNcbirc).
Definition at line 1304 of file ncbiapp.cpp.
References IRegistry::fWithNcbirc, and CNcbiApplicationAPI::LoadConfig().
|
protectedvirtual |
Load settings from the configuration file to the registry.
This method is called from inside AppMain() to load (add) registry settings from the configuration file specified as the "conf" arg passed to AppMain(). The "conf" argument has the following special meanings:
Regardless, this method normally loads global settings from .ncbirc or ncbi.ini when reg_flags contains fWithNcbirc (as it typically does), even if conf is NULL.
NOTE: If "conf" arg is empty or non-empty, but without path, then the Toolkit will try to look for it in several potentially relevant directories, as described in <corelib/metareg.hpp>.
Throw an exception if "conf" is non-empty, and cannot open file. Throw an exception if file exists, but contains invalid entries.
reg | The loaded registry is returned via the reg parameter. |
conf | The configuration file to loaded the registry entries from. |
reg_flags | Flags for loading the registry |
Definition at line 1239 of file ncbiapp.cpp.
References CMetaRegistry::SEntry::actual_name, basename, eFollowLinks, eIgnoreLinks, IRegistry::Empty(), CMetaRegistry::eName_AsIs, CMetaRegistry::eName_Ini, CMetaRegistry::eName_RcOrIni, ERR_POST_X, CMetaRegistry::FindRegistry(), CDirEntry::GetName(), CRef< C, Locker >::GetPointer(), CNcbiRegistry::IncludeNcbircIfAllowed(), Info(), CMetaRegistry::Load(), CNcbiApplicationAPI::m_Arguments, CNcbiApplicationAPI::m_Config, CNcbiApplicationAPI::m_ConfigLoaded, CNcbiApplicationAPI::m_ConfigPath, CNcbiApplicationAPI::m_DefaultConfig, NCBI_THROW, IRWRegistry::Read(), CMetaRegistry::SEntry::registry, CRef< C, Locker >::Reset(), CDirEntry::SplitPath(), str(), and IRegistry::Write().
Referenced by CFakeApplication::CFakeApplication(), CNcbiApplicationAPI::LoadConfig(), CProjBulderApp::ParseArguments(), and CNcbiApplicationAPI::x_TryInit().
Overload for the above for all types of allocated memory that are to be deallocated by free()
Definition at line 1455 of file ncbimisc.hpp.
References free(), and make_c_unique().
Eliminates the necessity for specifying types of both allocated resource and deallocating C function.
Definition at line 1448 of file ncbimisc.hpp.
Referenced by CServiceDiscovery::DiscoverImpl(), make_c_unique(), NAMEDPIPE_CreateConnector(), NcbiOpenURL(), PIPE_CreateConnector(), and CHttpRequest::sx_Adjust().
string CNcbiToolkit_LogMessage::Message | ( | void | ) | const |
Get text part of the message.
Definition at line 111 of file ncbi_toolkit.cpp.
References kEmptyStr, SDiagMessage::m_Buffer, SDiagMessage::m_BufferLen, ncbi::CNcbiToolkit_LogMessage::m_Msg, and string.
CAppException::NCBI_EXCEPTION_DEFAULT | ( | CAppException | , |
CCoreException | |||
) |
void ncbi::NcbiToolkit_Fini | ( | void | ) |
Release resources allocated for NCBI C++ Toolkit.
void ncbi::NcbiToolkit_Init | ( | int | argc, |
const TNcbiToolkit_XChar *const * | argv, | ||
const TNcbiToolkit_XChar *const * | envp = NULL , |
||
INcbiToolkit_LogHandler * | log_handler = NULL |
||
) |
Initialialize NCBI C++ Toolkit internal infrastructure: arguments, environment, diagnostics, logging.
argc | Argument count [argc in a regular main(argc, argv)]. |
argv | Argument vector [argv in a regular main(argc, argv)]. |
envp | Environment pointer [envp in a regular main(argc, argv, envp)]; a null pointer (the default) corresponds to the standard system array (environ on most Unix platforms). |
log_handler | Handler for diagnostic messages that are emitted by the C++ Toolkit code |
void ncbi::NcbiToolkit_RegisterNcbiApplicationFactory | ( | FNcbiApplicationFactory | f | ) |
|
inline |
Definition at line 114 of file ncbiapp_api.hpp.
References CNcbiApplicationGuard::m_App.
ncbi::CNcbiToolkit_LogMessage::operator std::string | ( | void | ) | const |
Get the message the way it is formatted by the Toolkit.
Definition at line 458 of file ncbimisc.hpp.
|
inline |
Definition at line 578 of file ncbimisc.hpp.
|
inline |
Definition at line 1274 of file ncbimisc.hpp.
|
inline |
|
inline |
Get nullable value.
If NULL, then call TNullToValue and use the value return by the latter.
Definition at line 695 of file ncbimisc.hpp.
|
inline |
Definition at line 115 of file ncbiapp_api.hpp.
References CNcbiApplicationGuard::m_App.
bool operator!= | ( | const CNullable< TValue, TNullToValue > & | l, |
const CNullable< TValue, TNullToValue > & | r | ||
) |
Definition at line 747 of file ncbimisc.hpp.
References l(), operator==(), and r().
|
inline |
Definition at line 1280 of file ncbimisc.hpp.
References b, and CSafeFlags< Enum >::get().
|
inline |
Definition at line 903 of file ncbimisc.hpp.
|
inline |
Definition at line 1289 of file ncbimisc.hpp.
References CSafeFlags< Enum >::get().
|
private |
|
private |
|
private |
|
inline |
Definition at line 1299 of file ncbimisc.hpp.
References b, CSafeFlags< Enum >::CSafeFlags(), and CSafeFlags< Enum >::get().
|
inline |
Definition at line 1363 of file ncbimisc.hpp.
|
inline |
Definition at line 1303 of file ncbimisc.hpp.
References b, and CSafeFlags< Enum >::m_Flags.
|
inline |
Definition at line 1540 of file ncbimisc.hpp.
|
inline |
Definition at line 658 of file ncbimisc.hpp.
References g_ThrowOnNull().
|
inline |
Definition at line 113 of file ncbiapp_api.hpp.
References CNcbiApplicationGuard::Get().
|
inline |
Definition at line 1176 of file ncbimisc.hpp.
References CFastBuffer< KEmbeddedSize, TType >::m_Buffer.
|
inline |
Dereference operator.
Definition at line 463 of file ncbimisc.hpp.
|
inline |
Definition at line 1177 of file ncbimisc.hpp.
References CFastBuffer< KEmbeddedSize, TType >::m_Buffer.
|
inline |
Definition at line 914 of file ncbimisc.hpp.
|
inline |
Definition at line 1179 of file ncbimisc.hpp.
References CFastBuffer< KEmbeddedSize, TType >::m_Buffer, and offset.
|
inline |
Definition at line 1180 of file ncbimisc.hpp.
References CFastBuffer< KEmbeddedSize, TType >::m_Buffer, and offset.
Definition at line 910 of file ncbimisc.hpp.
|
inline |
Definition at line 909 of file ncbimisc.hpp.
|
inline |
Definition at line 915 of file ncbimisc.hpp.
|
inline |
Definition at line 916 of file ncbimisc.hpp.
Definition at line 912 of file ncbimisc.hpp.
|
inline |
Definition at line 911 of file ncbimisc.hpp.
|
inline |
Definition at line 112 of file ncbiapp_api.hpp.
References CNcbiApplicationGuard::Get().
|
inline |
Reference operator.
Definition at line 466 of file ncbimisc.hpp.
|
inline |
Definition at line 904 of file ncbimisc.hpp.
|
inline |
Definition at line 946 of file ncbimisc.hpp.
References out().
|
inline |
Definition at line 1372 of file ncbimisc.hpp.
References CSafeFlags< Enum >::get(), and out().
|
inline |
Definition at line 905 of file ncbimisc.hpp.
|
inline |
Assignment operator.
Definition at line 560 of file ncbimisc.hpp.
|
inline |
Assignment operator.
Definition at line 440 of file ncbimisc.hpp.
|
private |
|
private |
|
private |
|
inline |
Definition at line 900 of file ncbimisc.hpp.
|
inline |
Assignment operator.
Definition at line 451 of file ncbimisc.hpp.
|
inline |
Assignment operator.
Definition at line 571 of file ncbimisc.hpp.
|
inline |
Reset nullable to unassigned state.
Definition at line 729 of file ncbimisc.hpp.
|
inline |
Assign a value to the nullable.
Definition at line 722 of file ncbimisc.hpp.
|
inline |
Definition at line 1276 of file ncbimisc.hpp.
References b, and CSafeFlags< Enum >::get().
|
inline |
Definition at line 902 of file ncbimisc.hpp.
|
inline |
Definition at line 1285 of file ncbimisc.hpp.
References CSafeFlags< Enum >::get().
|
private |
|
private |
|
private |
|
inline |
Definition at line 906 of file ncbimisc.hpp.
|
inline |
Definition at line 907 of file ncbimisc.hpp.
|
inline |
Definition at line 953 of file ncbimisc.hpp.
References in().
|
inline |
Array style dereference (returns reference)
Definition at line 594 of file ncbimisc.hpp.
|
inline |
Array style dereference (returns value)
Definition at line 591 of file ncbimisc.hpp.
|
inline |
Definition at line 1174 of file ncbimisc.hpp.
References CFastBuffer< KEmbeddedSize, TType >::m_Buffer.
|
inline |
Definition at line 1319 of file ncbimisc.hpp.
References b, CSafeFlags< Enum >::CSafeFlags(), and CSafeFlags< Enum >::get().
|
inline |
Definition at line 1367 of file ncbimisc.hpp.
|
inline |
Definition at line 1323 of file ncbimisc.hpp.
References b, and CSafeFlags< Enum >::m_Flags.
|
inline |
Definition at line 1309 of file ncbimisc.hpp.
References b, CSafeFlags< Enum >::CSafeFlags(), and CSafeFlags< Enum >::get().
|
inline |
Helper operators for safe-flags enums.
These operators will be used only for enums marked as safe-flag enums by macro DECLARE_SAFE_FLAGS()
Definition at line 1359 of file ncbimisc.hpp.
|
inline |
Definition at line 1313 of file ncbimisc.hpp.
References b, and CSafeFlags< Enum >::m_Flags.
|
inline |
Definition at line 1294 of file ncbimisc.hpp.
References CSafeFlags< Enum >::CSafeFlags(), and CSafeFlags< Enum >::get().
|
inlineexplicit |
Definition at line 263 of file ncbimisc.hpp.
|
inlineexplicit |
Definition at line 258 of file ncbimisc.hpp.
|
inline |
Definition at line 253 of file ncbimisc.hpp.
|
pure virtual |
|
protectedvirtual |
Check the command line arguments before parsing them.
Reimplemented in CNetStorageDApp, and CCgiApplication.
Definition at line 1312 of file ncbiapp.cpp.
References CNcbiApplicationAPI::ePreparse_Continue.
Referenced by CNcbiApplicationAPI::AppMain(), and CNetStorageDApp::PreparseArgs().
|
pure virtual |
Print a message about collecting data, disablig tracking and privacy policies.
Implemented in CSamplePhoneHomePolicy.
|
inline |
Release will release ownership of pointer to caller.
Definition at line 472 of file ncbimisc.hpp.
Referenced by AascanTestFixture::AascanTestFixture(), CBAMDataLoader_Impl::AddSrzDef(), DTDParser::AttribBlock(), BOOST_AUTO_TEST_CASE(), CSeqTable_multi_data::ChangeToBit_bvector(), CSeqTable_sparse_index::ChangeToBit_set_bvector(), DTDParser::CompositeNode(), CompressedAascanTestFixture::CompressedAascanTestFixture(), CObjectIStream::Create(), CObjectIStream::CreateFromBuffer(), ASNParser::EnumeratedBlock(), CDataType::GenerateCode(), CChoiceDataType::GenerateCode(), CBitStringDataType::GetFullCType(), CIdlerWrapper::GetIdler(), CTL_RowResult::GetItemInternal(), CDataType::GetRefCType(), CSeqFeatData::GetRegulatoryClass(), CompressedAalookupTestFixture::GetSeqBlk(), AalookupTestFixture::GetSeqBlk(), GetSequenceProtein(), GetSequenceSingleNucleotideStrand(), CId2FetchApp::Init(), CNcbiTestApplication::Init(), CWig2tableApplication::MakeTable(), DTDParser::NillableBlock(), AutoPtr< CNcbistrstream_Base >::reset(), NtlookupTestFixture::SetUpQuery(), TestFixture::SetUpQuery(), NuclWordFinderTextFixture::setupSequences(), TestFixture::SetUpSubject(), SetupSubjects_OMF(), ASNParser::TypesBlock(), DTDParser::TypesBlock(), CBVector_data::x_CreateBitVector(), CHistogramBinning::x_IdentifyClusters(), CPssmEngine::x_InitializeScoreBlock(), CPkgManager::x_LoadPackage(), CDiagSyntaxParser::x_PutIntoFilter(), CPubseqReader::x_ReceiveData(), AutoPtr< CNcbistrstream_Base >::x_Release(), CPubseq2Reader::x_SendPacket(), CId2FetchApp::x_SendRequestPacket(), CHistogramBinning::x_TryForEvenBins(), and DTDParser::x_Type().
|
inline |
Release will release ownership of pointer to caller.
Definition at line 584 of file ncbimisc.hpp.
Referenced by CCompressionStreambuf::CCompressionStreambuf(), AutoArray< CS_INT >::reset(), and AutoArray< CS_INT >::x_Release().
|
inline |
Reload the configuration file.
By default, does nothing if the file has the same size and date as before.
Note that this may lose other data stored in the registry!
flags | Controls how aggressively to reload. |
reg_flags | Flags to use when parsing the registry; ignored if the registry was already cached (as it should normally have been). |
Definition at line 801 of file ncbiapp_api.hpp.
References flags, CNcbiApplicationAPI::GetConfigPath(), CNcbiApplicationAPI::GetRWConfig(), and CMetaRegistry::Reload().
Referenced by BOOST_AUTO_TEST_CASE(), CAutoNcbiConfigFile::CAutoNcbiConfigFile(), CNetStorageHandler::x_ProcessReconfigure(), CNetScheduleHandler::x_ProcessReloadConfig(), and CAutoNcbiConfigFile::~CAutoNcbiConfigFile().
|
inline |
Reset will delete the old pointer, set content to the new value, and assume the ownership upon the new pointer.
Definition at line 598 of file ncbimisc.hpp.
Referenced by CArchiveMemory::Create(), CLZOCompression::InitCompression(), AutoArray< CS_INT >::operator=(), CSparseKmerCounts::Reset(), CLZOBuffer::ResetBuffer(), CStatementBase::x_GetData(), CSeqVector_CI::x_InitializeCache(), CBamString::x_reserve(), and AutoArray< CS_INT >::~AutoArray().
|
inline |
Reset will delete the old pointer (if owned), set content to the new value, and assume the ownership upon the new pointer by default.
Definition at line 480 of file ncbimisc.hpp.
Referenced by CSeqMaskerUsetHash::add_ht_info(), CSeqMaskerUsetHash::add_vt_info(), CBamUIDataSource::AddDataLoader(), CBAMDataLoader_Impl::AddSrzDef(), CAgpErrEx::CAgpErrEx(), CAutoEnvironmentVariable::CAutoEnvironmentVariable(), CBAMDataLoader_Impl::CBAMDataLoader_Impl(), CConnTest::CheckFWConnections(), CAsnSizer::CloseDataStream(), CSplitDataMaker::CloseDataStream(), CPagedFile::CPagedFile(), CProjectStorage::CProjectStorage(), CPtbRegistry::CPtbRegistry(), CTeeDiagHandler::CTeeDiagHandler(), CSeqMaskerOstatOpt::doFinalize(), CGffObjectLoader::Execute(), CConnTest::ExtraCheckOnFailure(), CDataType::GetAnyTypeInfo(), CBDB_BlobSplitStore< TBV, TObjDeMux, TL >::GetDb(), CValidator::CCacheImpl::GetFeatStrKeyToFeats(), CIdlerWrapper::GetIdler(), CTL_RowResult::GetItemInternal(), CDataTypeModule::GetNamespace(), CDataType::GetRealTypeInfo(), GetSequenceProtein(), GetSequenceSingleNucleotideStrand(), CBDB_BlobSplitStore< TBV, TObjDeMux, TL >::InitDbMutex(), CAlnVecRow::LoadDefaultTracks(), CGen_code_table::LoadTransTable(), CPipeHandle::Open(), CAsnSizer::OpenDataStream(), CSplitDataMaker::OpenDataStream(), CMSHit::operator=(), AutoPtr< CNcbistrstream_Base >::operator=(), CSeqVector::operator=(), SAnnotSelector::operator=(), CMSHit::RecordMatches(), CNcbiApplogApp::Redirect(), CBVector_data::Reset(), CBVector_data::ResetBitVector(), SAnnotSelector::ResetSourceLoc(), CGapStatsApplication::Run(), CWig2tableApplication::Run(), CSearch< LEGACY, NHITS >::Search(), CSQLITE_Blob::SetAppendStatement(), CBVector_data::SetBitVector(), CBDB_RawFile::SetCompressor(), CStringPairs< TExtraValuesMap >::SetDecoder(), CStringPairs< TExtraValuesMap >::SetEncoder(), CIdlerWrapper::SetIdler(), CBamDb::SetIdMapper(), CLoadLockSetter::SetLoaded(), CMergeVolumes::SetMergeAccumulator(), CMergeVolumes::SetMergeStore(), CMSPeakList::SetMZI(), CDisplaySeqalign::SetSequencePropertyLabel(), SAnnotSelector::SetSourceLoc(), CSplitCacheApp::SetupCache(), CFastaOstream::SetWidth(), CAlignCompare::SAlignment::Slice(), CSplitCacheApp::TestSplit(), CPSGL_Blob_Processor::TSE_ToOM(), CSDBAPI::UpdateMirror(), CSQLITE_Blob::Write(), x_AdjustAnchorDirection(), CBVector_data::x_CreateBitVector(), CSGAlignmentJob::x_CreateFeatGlyph(), CSeqVector::x_CreateIterator(), CAlnVecRow::x_CreateTrackPanel(), CId1Reader::x_DisconnectAtSlot(), CId2Reader::x_DisconnectAtSlot(), CPubseqReader::x_DisconnectAtSlot(), CPubseq2Reader::x_DisconnectAtSlot(), CArchive::x_ExtractEntry(), CPsiBlastInputClustalW::x_ExtractQueryFromMsa(), CPubseq2Reader::x_GetConnection(), CLDS2_Database::x_GetStatement(), CLoadLockSetter::x_Init(), CId2FetchApp::x_InitConnection(), CGen_code_table::x_InitImplementation(), CBlastFastaInputSource::x_InitInputReader(), CId2FetchApp::x_InitPubSeqConnection(), CFileLoader::x_LoadGff(), CHTMLPage::x_LoadTemplateLib(), CRegexpTemplateTester::x_Op_Skip(), CPdfObject::x_PrintTo(), CId2FetchApp::x_ProcessData(), CTar::x_ProcessEntry(), CXcompareAnnotsApplication::x_ProcessSeqAlignSetFromFile(), CPubseqReader::x_ReceiveData(), CSeqVector::x_ResetIterator(), CAlnVecRow::x_ResetTrackPanel(), CDBLBClientApp::x_RunWhatIs(), CId2FetchApp::x_SendRequestPacket(), and AutoPtr< CNcbistrstream_Base >::~AutoPtr().
|
pure virtual |
Restore policy configuration.
Implemented in CSamplePhoneHomePolicy.
|
pure virtual |
Run the application.
It is defined as a pure virtual method – so you must(!) supply the Run() method to implement the application-specific logic.
Implemented in CFakeApplication, CSubImageApp, CImageDemoApp, CConvImageApp, CCacheDemoApp, CBam2GraphApp, CDataTool, CSampleLibtestApplication, CSampleSoapClientApplication, CSeqAnnotSplicerApp, CProcessHighestSeObjs, CBssInfoApp, CDemoApp, CDemoApp, CDemoApp, CSdbapiSimpleApp, CSampleObjmgrApplication, CFeatTreeSampleApp, CEditBioseqSampleApp, CSampleObjectsApplication, CRemoteAppClientSampleApp, CSampleNetScheduleNode, CSampleNetScheduleClient, CGridClientSampleApp, CSampleNetCacheClient, CMultiCommandApplication, CSampleLds2Application, CHttpSessionApp, CEUtilsApp, CDbCopyApp, CDbapiSimpleApp, VSRunSampleApplication, CBlastDemoApplication, CBlastSampleApplication, CBlastDemoApplication, CSampleBasicApplication, CSampleAsnApplication, CSampleAlnmgrApplication, CFetchGBProjectApp, CAce2AsnApp, ASNIOTestApp, CAlnVwrApp, CAlnMrgApp, CAlnTestApp, CAlnBuildApp, CClientGenomicCollectionsSvcApplication, CEntrez2ClientApp, CDemoApplication, CColumnarVCFReaderApp, CMakeScoreMethodApp, CTestDispatchApp, CAppJobTestApplication, CTestBMApp, CObjConvProfile, CTestApplication, COdbcSpwhoDemoApp, COcbdDemoApp, CMysqlDemoApp, CRunTestApplication, CRunTestApplication, CBDB_MergeTest, CBDB_SplitTest, CBDB_FileDumperApp, CBDB_BLobDemo1, CBDB_PhoneBookDemo3, CBDB_PhoneBookDemo2, CBDB_PhoneBookDemo1, CBDB_CacheVerifyApp, CNcbiTestApplication, CNcbiToolkitImpl_Application, CPsgPerfApplication, CProjBulderApp, CWinMaskApplication, CWig2tableApplication, subfuse::CSubfuseApp, CStreamTestApp, CSplitCacheApp, CMytestApplication, SegMaskerApplication, CReadBlastApp, CDemoApp, CDemoApp, CObjExtractApp, CNmer_repeatsApplication, CNetStorageGCApp, CNetStorageDApp, CNetScheduleDApp, CNcbiEncryptApp, CMultipatternApp, CIdfetchApplication, CId2FetchApp, CId1FetchApp, CId1FetchApp, CHgvsToSeqfeatConverter, CGi2TaxIdApp, CGffDeconcatApp, CGapStatsApplication, CFormatGuessApp, CFeatImportApp, CDustMaskApplication, CDBLBClientApp, CConversionApp, CCompartApplication, Cn3DNoWin, CBsDiffApp, CVDBTblastnApp, CVDBBlastnApp, CGuideTreeApplication, CConvert2BlastMaskApplication, BlastdbCopyApplication, CBlastDbCheckApplication, CBiosampleChkApp, CBDBEnvKeeperApp, CWalkAsnCacheApplication, CAsnSubCacheCreateApplication, CReadIndexSpeedApp, CPrimeCacheApplication, CAsnCacheDumpSeqIdsApplication, CConcatSeqEntriesApplication, CCacheIndexCopyApp, CAsnCacheTestApplication, CTest, CAsn2Asn, CAgpconvertApplication, CAgpValidateApplication, CWinMaskDemoApplication, CXcompareAnnotsApplication, CRegexpLocApp, CGeneModelDemoApp, CCpGDemoApp, CAdapterSearchApplication, COmssa2pepxmlApplication, CLocalFinderApp, CMultiApplication, CMultiApplication, CClustererApplication, CBlastKmerBuildIndexApplication, CBlastKmerApplication, CCkblastindexApplication, CGumbelParamsApplication, CBlastInputDemoApplication, CDemoScoreBuilderApp, CTestCompartApplication, CAlignCleanupApplication, CAVApp, CRemoteCgiApp, CNCBIwxApplication, CThreadedApp, CGridWorkerApp, CCgiApplication, COMSSABase, CTestRemoteUpdaterApplication, CPubmedFetchApplication, CPubmedFetchApplication, CTbl2AsnApp, pub_report::CPubReportApp, CPrt2FsmApp, CMultiReaderApp, CDiscRepApp, CAsnvalApp, CCleanupApp, CAsn2FlatApp, CAsn2FastaApp, CAnnotWriterApp, CSdbapiTest, CPsgClientSampleApp, CDbapiTest, CUsageReportPhoneHomeSampleApp, CUsageReportSampleApp, CAnalyzeShiftApp, CHugeFileDemoApp, CTax4BlastDemo, CNcbiApplogApp, CGBProjectTool, CTestGuiRegistryApp, CDbapiSampleApp, CDbapiDriverSampleApp, CVecScreenApp, seqsubmit_split::CSeqSubSplitter, CSrcChkApp, CSplignApp, CRMBlastnApp, CPsgClientApp, CAppNWA, CMagicBlastApp, CIgBlastpApp, CIgBlastnApp, CIdMapperApp, CAppHitFilter, CComponentIDToolApp, CGridCommandLineInterfaceApp, CExonSelectorApplication, CCompactSAMApplication, CCompartApp, CBlastVdbCmdApp, CBlastFormatterVdbApp, CMakeProfileDBApp, CMakeClusterDBApp, CMakeBlastDBApp, CBlastDBCmdApp, CBlastDBCmdApp, CBlastdbConvertApp, CBlastDBAliasApp, CTblastxApp, CTblastnApp, CSeedTopApp, CRPSTBlastnApp, CRPSBlastApp, CPsiBlastApp, CDeltaBlastApp, CBlastxApp, CBlastpApp, CBlastnApp, CBlastFormatterApp, CDemoSeqQaApp, COMSSAMerge, COMSSA, CReadresult, CSRSearchApplication, CMkIndexApplication, CProSplignApp, CNgAlignApp, CMergeyApp, and CDemoContigAssemblyApp.
Referenced by CNcbiApplicationAPI::x_TryMain().
void RunIdler | ( | void | ) |
Execute currently installed idler if any.
Definition at line 1864 of file ncbiapp.cpp.
References s_IdlerWrapper.
Referenced by CFastCgiApplicationMT::x_ProcessThreadedRequest().
Definition at line 787 of file ncbimisc.hpp.
Definition at line 796 of file ncbimisc.hpp.
|
inline |
Definition at line 458 of file ncbimisc.hpp.
|
inline |
Definition at line 578 of file ncbimisc.hpp.
|
inline |
Definition at line 1274 of file ncbimisc.hpp.
|
pure virtual |
Save policy configuration.
Implemented in CSamplePhoneHomePolicy.
|
inline |
Definition at line 282 of file ncbimisc.hpp.
|
inline |
Definition at line 278 of file ncbimisc.hpp.
Referenced by CConstRef< CSeq_loc >::AtomicResetFrom(), CRef< CAlnMixSegment >::AtomicResetFrom(), CRef< CAlnMixSegment >::AtomicSwap(), CConstRef< CSeq_loc >::AtomicSwap(), CStaticArraySearchBase< NStaticArray::PKeyValuePair< SStaticPair< KeyType, ValueType > >, less< KeyType > >::begin(), CRef< CAlnMixSegment >::Empty(), CConstRef< CSeq_loc >::Empty(), CRef< CAlnMixSegment >::GetNCPointerOrNull(), CRef< CAlnMixSegment >::GetNonNullNCPointer(), CRef< CAlnMixSegment >::GetNonNullPointer(), CConstRef< CSeq_loc >::GetNonNullPointer(), CConstRef< CSeq_loc >::GetPointerOrNull(), CRef< CAlnMixSegment >::GetPointerOrNull(), CGuard< IRegistry, SSimpleReadLock< IRegistry > >::GetResource(), CGuard< IRegistry, SSimpleReadLock< IRegistry > >::GetUnlock(), CBlobIdFor< Value, Converter >::GetValue(), CRef< CAlnMixSegment >::IsNull(), CConstRef< CSeq_loc >::IsNull(), AutoPtr< CNcbistrstream_Base >::IsOwned(), CRef< CAlnMixSegment >::NotEmpty(), CConstRef< CSeq_loc >::NotEmpty(), CRef< CAlnMixSegment >::NotNull(), CConstRef< CSeq_loc >::NotNull(), CRef< CAlnMixSegment >::operator!(), CConstRef< CSeq_loc >::operator!(), AutoArray< CS_INT >::operator=(), AutoPtr< CNcbistrstream_Base >::operator=(), CRef< CAlnMixSegment >::operator=(), CConstRef< CSeq_loc >::operator=(), AutoPtr< CNcbistrstream_Base >::release(), AutoArray< CS_INT >::release(), CRef< CAlnMixSegment >::Release(), CConstRef< CSeq_loc >::Release(), CRef< CAlnMixSegment >::ReleaseOrNull(), CConstRef< CSeq_loc >::ReleaseOrNull(), AutoArray< CS_INT >::reset(), AutoPtr< CNcbistrstream_Base >::reset(), CRef< CAlnMixSegment >::Reset(), CConstRef< CSeq_loc >::Reset(), pair_base_member< TKeyGetter, CTreeNode * >::Swap(), CRef< CAlnMixSegment >::Swap(), CConstRef< CSeq_loc >::Swap(), CBlobIdFor< Value, Converter >::ToString(), CRef< CAlnMixSegment >::x_AssignFromRef(), CConstRef< CSeq_loc >::x_AssignFromRef(), CRef< CAlnMixSegment >::x_LockFromMoveConstructor(), CConstRef< CSeq_loc >::x_LockFromMoveConstructor(), CRef< CAlnMixSegment >::x_LockFromPtr(), CConstRef< CSeq_loc >::x_LockFromPtr(), CRef< CAlnMixSegment >::x_LockFromRef(), CConstRef< CSeq_loc >::x_LockFromRef(), CRef< CAlnMixSegment >::x_MoveAssign(), CConstRef< CSeq_loc >::x_MoveAssign(), CStaticArraySearchBase< NStaticArray::PKeyValuePair< SStaticPair< KeyType, ValueType > >, less< KeyType > >::x_Set(), and CStaticArraySearchBase< NStaticArray::PKeyValuePair< SStaticPair< KeyType, ValueType > >, less< KeyType > >::~CStaticArraySearchBase().
Definition at line 922 of file ncbimisc.hpp.
Referenced by CObjectIStream::ReadGi().
Definition at line 923 of file ncbimisc.hpp.
|
inlineprotected |
Definition at line 620 of file ncbiapp_api.hpp.
References flags, and CNcbiApplicationAPI::m_AppFlags.
Referenced by CNcbiTestApplication::InitTestFramework().
Set policy status (enabbed/disabled).
Definition at line 101 of file phone_home_policy.hpp.
References IPhoneHomePolicy::m_IsEnabled.
Referenced by CSamplePhoneHomePolicy::Apply().
Set a specified environment variable by name.
Definition at line 1139 of file ncbiapp.cpp.
References CNcbiEnvironment::Set(), CNcbiApplicationAPI::SetEnvironment(), and rapidjson::value.
|
inline |
Get a non-const copy of the application's cached environment.
Definition at line 765 of file ncbiapp_api.hpp.
References CNcbiApplicationAPI::m_Environ.
Referenced by BOOST_AUTO_TEST_CASE(), CAutoEnvironmentVariable::CAutoEnvironmentVariable(), CEnvironmentCleaner::Clean(), CCgi2RCgiApp::CreateContextWithFlags(), CSeqEditPackage::Init(), CSeqTestApplication::Init(), CVDBBlastnApp::Init(), CVDBTblastnApp::Init(), CNetStorageDApp::Init(), CPipeHandle::Open(), CCgi2RCgiApp::ProcessRequest(), CRunTestApplication::Run(), s_TestReadPDBAsn1(), CNcbiApplicationAPI::SetEnvironment(), CNcbiRegistry::x_Init(), CAlnMultiCGIApplication::x_PreProcess(), and CSeqEditPackage::x_UpdateValAuxFile().
|
protected |
Force the program to return a specific exit code later, either when it exits due to an exception or unconditionally.
In the latter case, Run's return value will be ignored.
Definition at line 1780 of file ncbiapp.cpp.
References CNcbiApplicationAPI::m_ExitCode, and CNcbiApplicationAPI::m_ExitCodeCond.
|
protected |
Set version data for the program.
Definition at line 1187 of file ncbiapp.cpp.
References ERR_POST_X, CNcbiApplicationAPI::m_Version, CRef< C, Locker >::Reset(), s_IsApplicationStarted, and dtl::version.
Referenced by BlastdbCopyApplication::BlastdbCopyApplication(), CBlastDBAliasApp::CBlastDBAliasApp(), CBlastDbCheckApplication::CBlastDbCheckApplication(), CBlastDBCmdApp::CBlastDBCmdApp(), CBlastdbConvertApp::CBlastdbConvertApp(), CBlastFormatterApp::CBlastFormatterApp(), CBlastFormatterVdbApp::CBlastFormatterVdbApp(), CBlastnApp::CBlastnApp(), CBlastpApp::CBlastpApp(), CBlastVdbCmdApp::CBlastVdbCmdApp(), CBlastxApp::CBlastxApp(), CConvert2BlastMaskApplication::CConvert2BlastMaskApplication(), CDeltaBlastApp::CDeltaBlastApp(), CDustMaskApplication::CDustMaskApplication(), CGumbelParamsApplication::CGumbelParamsApplication(), CIgBlastnApp::CIgBlastnApp(), CIgBlastpApp::CIgBlastpApp(), CMagicBlastApp::CMagicBlastApp(), CMakeBlastDBApp::CMakeBlastDBApp(), CMakeClusterDBApp::CMakeClusterDBApp(), CMakeProfileDBApp::CMakeProfileDBApp(), CMultiApplication::CMultiApplication(), CNetScheduleDApp::CNetScheduleDApp(), CNetStorageDApp::CNetStorageDApp(), CNetStorageGCApp::CNetStorageGCApp(), CPsiBlastApp::CPsiBlastApp(), CRMBlastnApp::CRMBlastnApp(), CRPSBlastApp::CRPSBlastApp(), CRPSTBlastnApp::CRPSTBlastnApp(), CSeedTopApp::CSeedTopApp(), CSplignApp::CSplignApp(), CTblastnApp::CTblastnApp(), CTblastxApp::CTblastxApp(), CVDBBlastnApp::CVDBBlastnApp(), CVDBTblastnApp::CVDBTblastnApp(), CVecScreenApp::CVecScreenApp(), CWinMaskApplication::CWinMaskApplication(), and SegMaskerApplication::SegMaskerApplication().
void SetIdler | ( | INcbiIdler * | idler, |
EOwnership | ownership = eTakeOwnership |
||
) |
Set new idler and ownership.
Definition at line 1858 of file ncbiapp.cpp.
References s_IdlerWrapper.
|
protected |
Set Phone Home Policy.
policy | Pointer to new Phone Home policy. NULL - delete current policy without a setting new one. If you have active policy, it automatically calls Finish() for the previously set policy, if any. |
ownership | Phone Home policy ownership. |
Definition at line 212 of file ncbiapp.cpp.
References IPhoneHomePolicy::Apply(), eTakeOwnership, IPhoneHomePolicy::Finish(), CNcbiApplicationAPI::m_PhoneHomePolicy, and CNcbiApplicationAPI::m_PhoneHomePolicy_Ownership.
Set program's display name.
Set up application name suitable for display or as a basename for other files. It can also be set by the user when calling AppMain().
Definition at line 1379 of file ncbiapp.cpp.
References ctll::empty(), CNcbiApplicationAPI::GetAppName(), GetDiagContext(), CNcbiApplicationAPI::m_ProgramDisplayName, and CDiagContext::SetAppName().
Referenced by CNcbiApplicationAPI::AppMain().
|
protected |
Adjust the behavior of standard I/O streams.
Unless this function is called, the behaviour of "C++" Cin/Cout/Cerr streams will be the same regardless of the compiler used.
IMPLEMENTATION NOTE: Do not call this function more than once and from places other than App's constructor.
Definition at line 1331 of file ncbiapp.cpp.
References _ASSERT, and CNcbiApplicationAPI::m_StdioFlags.
Referenced by CCgiApplication::CCgiApplication().
|
protectedvirtual |
Setup the command line argument descriptions.
Call from the Init() method. The passed "arg_desc" will be owned by this class, and it will be deleted by ~CNcbiApplicationAPI(), or if SetupArgDescriptions() is called again.
Reimplemented in CRemoteCgiApp, CGridWorkerApp, and CCgiApplication.
Definition at line 1208 of file ncbiapp.cpp.
References CArgDescriptions::CreateArgs(), CNcbiApplicationAPI::GetArguments(), CNcbiApplicationAPI::m_ArgDesc, CNcbiApplicationAPI::m_Args, CNcbiApplicationAPI::m_DefaultConfig, and CNcbiApplicationAPI::m_DisableArgDesc.
Referenced by CDemoContigAssemblyApp::Init(), CNgAlignApp::Init(), CSRSearchApplication::Init(), CReadresult::Init(), COMSSABase::Init(), COMSSAMerge::Init(), CDemoSeqQaApp::Init(), CBlastFormatterApp::Init(), CBlastnApp::Init(), CBlastpApp::Init(), CBlastxApp::Init(), CDeltaBlastApp::Init(), CPsiBlastApp::Init(), CRPSBlastApp::Init(), CRPSTBlastnApp::Init(), CSeedTopApp::Init(), CTblastnApp::Init(), CTblastxApp::Init(), CBlastDBAliasApp::Init(), CBlastdbConvertApp::Init(), CBlastDBCmdApp::Init(), CMakeBlastDBApp::Init(), CMakeClusterDBApp::Init(), CBlastFormatterVdbApp::Init(), CBlastVdbCmdApp::Init(), CCompartApp::Init(), CCompactSAMApplication::Init(), CExonSelectorApplication::Init(), CAppHitFilter::Init(), CIdMapperApp::Init(), CIgBlastnApp::Init(), CIgBlastpApp::Init(), CMagicBlastApp::Init(), CAppNWA::Init(), CPsgClientApp::Init(), CRMBlastnApp::Init(), CSplignApp::Init(), CSrcChkApp::Init(), seqsubmit_split::CSeqSubSplitter::Init(), CVecScreenApp::Init(), CDbapiDriverSampleApp::Init(), CDbapiSampleApp::Init(), CTestGuiRegistryApp::Init(), CGBProjectTool::Init(), CNcbiApplogApp::Init(), CTax4BlastDemo::Init(), CHugeFileDemoApp::Init(), CDbapiTest::Init(), CPsgClientSampleApp::Init(), CSdbapiTest::Init(), CAnnotWriterApp::Init(), CAsn2FastaApp::Init(), CAsn2FlatApp::Init(), CCleanupApp::Init(), CDiscRepApp::Init(), CMultiReaderApp::Init(), pub_report::CPubReportApp::Init(), CPubmedFetchApplication::Init(), CTestRemoteUpdaterApplication::Init(), CThreadedApp::Init(), CAVApp::Init(), CAlignCleanupApplication::Init(), CMergeyApp::Init(), CProSplignApp::Init(), CTestCompartApplication::Init(), CDemoScoreBuilderApp::Init(), CBlastInputDemoApplication::Init(), CGumbelParamsApplication::Init(), CCkblastindexApplication::Init(), CBlastKmerApplication::Init(), CBlastKmerBuildIndexApplication::Init(), CClustererApplication::Init(), CMultiApplication::Init(), CLocalFinderApp::Init(), COmssa2pepxmlApplication::Init(), CAdapterSearchApplication::Init(), CCpGDemoApp::Init(), CGeneModelDemoApp::Init(), CRegexpLocApp::Init(), CXcompareAnnotsApplication::Init(), CWinMaskDemoApplication::Init(), CAgpValidateApplication::Init(), CAgpconvertApplication::Init(), CAsnCacheTestApplication::Init(), CCacheIndexCopyApp::Init(), CConcatSeqEntriesApplication::Init(), CAsnCacheDumpSeqIdsApplication::Init(), CPrimeCacheApplication::Init(), CReadIndexSpeedApp::Init(), CAsnSubCacheCreateApplication::Init(), CWalkAsnCacheApplication::Init(), CBDBEnvKeeperApp::Init(), CBiosampleChkApp::Init(), CBlastDbCheckApplication::Init(), BlastdbCopyApplication::Init(), CConvert2BlastMaskApplication::Init(), CGuideTreeApplication::Init(), CVDBBlastnApp::Init(), CVDBTblastnApp::Init(), Cn3DNoWin::Init(), CCompartApplication::Init(), CConversionApp::Init(), CDBLBClientApp::Init(), CDustMaskApplication::Init(), CFeatImportApp::Init(), CFormatGuessApp::Init(), CGapStatsApplication::Init(), CGffDeconcatApp::Init(), CGi2TaxIdApp::Init(), CHgvsToSeqfeatConverter::Init(), CId1FetchApp::Init(), CId2FetchApp::Init(), CIdfetchApplication::Init(), CMultipatternApp::Init(), CNcbiEncryptApp::Init(), CNetScheduleDApp::Init(), CNetStorageDApp::Init(), CNetStorageGCApp::Init(), CNmer_repeatsApplication::Init(), CObjExtractApp::Init(), CDemoApp::Init(), CReadBlastApp::Init(), SegMaskerApplication::Init(), CMytestApplication::Init(), CSplitCacheApp::Init(), CStreamTestApp::Init(), subfuse::CSubfuseApp::Init(), CWig2tableApplication::Init(), CWinMaskApplication::Init(), CProjBulderApp::Init(), CPsgPerfApplication::Init(), CNcbiTestApplication::Init(), CBDB_CacheVerifyApp::Init(), CBDB_PhoneBookDemo1::Init(), CBDB_PhoneBookDemo2::Init(), CBDB_PhoneBookDemo3::Init(), CBDB_BLobDemo1::Init(), CBDB_FileDumperApp::Init(), CBDB_SplitTest::Init(), CBDB_MergeTest::Init(), CRunTestApplication::Init(), CMysqlDemoApp::Init(), CTestApplication::Init(), CObjConvProfile::Init(), CAppJobTestApplication::Init(), CTestDispatchApp::Init(), CMakeScoreMethodApp::Init(), CColumnarVCFReaderApp::Init(), CEntrez2ClientApp::Init(), CAlnMrgApp::Init(), CAlnVwrApp::Init(), CFetchGBProjectApp::Init(), CSampleAlnmgrApplication::Init(), CSampleAsnApplication::Init(), CSampleBasicApplication::Init(), CBlastDemoApplication::Init(), CBlastSampleApplication::Init(), VSRunSampleApplication::Init(), CDbapiSimpleApp::Init(), CEUtilsApp::Init(), CHttpSessionApp::Init(), CSampleLds2Application::Init(), CMultiCommandApplication::Init(), CSampleNetCacheClient::Init(), CGridClientSampleApp::Init(), CSampleNetScheduleClient::Init(), CSampleNetScheduleNode::Init(), CRemoteAppClientSampleApp::Init(), CSampleObjectsApplication::Init(), CEditBioseqSampleApp::Init(), CFeatTreeSampleApp::Init(), CSampleObjmgrApplication::Init(), CSdbapiSimpleApp::Init(), CBssInfoApp::Init(), CProcessHighestSeObjs::Init(), CSeqAnnotSplicerApp::Init(), CSampleSoapClientApplication::Init(), CSampleLibtestApplication::Init(), CDataTool::Init(), CBam2GraphApp::Init(), CConvImageApp::Init(), CImageDemoApp::Init(), CSubImageApp::Init(), CCgiApplication::SetupArgDescriptions(), CGridWorkerApp::SetupArgDescriptions(), CNCBIwxApplication::x_SetupArgDescriptions(), CTestBMApp::x_SetupArgDescriptions(), CMakeProfileDBApp::x_SetupArgDescriptions(), and CNcbiApplicationAPI::x_TryInit().
|
protected |
Setup the application diagnostic stream.
Definition at line 1225 of file ncbiapp.cpp.
References eDCM_Flush, CNcbiApplicationAPI::m_LogFile, and CDiagContext::SetupDiag().
|
virtual |
Setup application specific diagnostic stream.
Called from SetupDiag when it is passed the eDS_AppSpecific parameter. Currently, this calls SetupDiag(eDS_ToStderr) to setup diagonistic stream to the std error channel.
Definition at line 1232 of file ncbiapp.cpp.