1 #ifndef GUI_CORE___TABLE_IMPORT_COLUMN__HPP
2 #define GUI_CORE___TABLE_IMPORT_COLUMN__HPP
58 enum eColumnType { eSeqIdColumn=0, eNumberColumn, eRealNumberColumn,
59 eTextColumn, eSkippedColumn, eTypeUndefined };
85 static const char* m_TypeNameList[];
86 static const char* m_ShortTypeNameList[];
91 , m_ColumnType(eTextColumn)
95 , m_IsCurrent(
false) {}
118 static string GetStringFromDataType(eDataType
t);
120 static string GetShortStringFromDataType(eDataType
t);
122 static eDataType GetDataTypeFromString(
const string& s);
123 static vector<eDataType> GetMatchingDataTypes(eColumnType c);
126 void SetName(
const string&
n);
127 string GetName()
const {
return m_ColumnName; }
128 string GetNameEx()
const {
return GetSkipped() ?
"" : m_ColumnName; }
133 bool GetSkipped()
const {
return (m_ColumnType == eSkippedColumn); }
145 void LogColumnInfo()
const;
153 void SetProperty(
const string& prop_name,
const string& prop_value) { m_Properties[prop_name] = prop_value; }
154 bool HasProperty(
const string& prop_name) {
return (m_Properties.count(prop_name) > 0); }
155 string GetProperty(
const string& prop_name) {
return (HasProperty(prop_name) ? m_Properties[prop_name] :
""); }
CMapAssemblyParams m_Assembly
Matching Assembly for column identifier.
string GetShortDataTypeString() const
eColumnType GetType() const
bool m_OneBased
If integer, is it one based or 0 based?
map< string, string > & GetPropertyValues()
void SetIsCurrent(bool b)
void SetDataType(eDataType t)
Get set bio-type info for the column.
string m_ColumnName
Column name.
bool HasProperty(const string &prop_name)
void SetQualifierType(const string &q)
void SetType(eColumnType t)
string GetProperty(const string &prop_name)
void SetAssembly(const CMapAssemblyParams &a)
void SetMatchColumn(bool b)
For attribute table import we need to specify a column as the column to use in matching the table aga...
eColumnType m_ColumnType
column type
string GetQualifierType() const
string m_Qualifier
For table import in sequence editor - the qualifier field name.
void SetQualifier(const string &q)
bool m_Match
(For attribute table loading) Is this the match column
string GetDataTypeString() const
eDataType GetDataType() const
int m_ColumnWidth
width in chracters
CMapAssemblyParams GetAssembly() const
string m_QualifierType
Also for sequence editor import - text version of CFieldNamePanel::EFieldType.
bool GetMatchColumn() const
bool GetIsCurrent() const
map< string, string > m_Properties
Any properties (text only) user wants to set for the column.
void SetProperty(const string &prop_name, const string &prop_value)
Add/update a column property.
bool m_IsCurrent
If true, this is the current column for editing purposes (for views that allow you to edit column typ...
eDataType m_DataType
The semantic meaning of the column, e.g. id, start pos, stop pos, strand.
string GetQualifier() const
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
#define NCBI_GUIWIDGETS_LOADERS_EXPORT
Defines to provide correct exporting from DLLs in Windows.
Portable reference counted smart and weak pointers using CWeakRef, CRef, CObject and CObjectEx.
The NCBI C++/STL use hints.