ARCHIVE
Snapshot of
the Shogun machine learning toolbox website
as of
2013
: preserved, not maintained. The live site:
shogun-toolbox.org
SHOGUN
4.1.0
Main Page
Related Pages
Modules
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Modules
Pages
src
shogun
lib
SGStringList.h
Go to the documentation of this file.
1
/*
2
* This program is free software; you can redistribute it and/or modify
3
* it under the terms of the GNU General Public License as published by
4
* the Free Software Foundation; either version 3 of the License, or
5
* (at your option) any later version.
6
*
7
* Written (W) 2012 Fernando José Iglesias García
8
* Written (W) 2010,2012 Soeren Sonnenburg
9
* Copyright (C) 2010 Berlin Institute of Technology
10
* Copyright (C) 2012 Soeren Sonnenburg
11
*/
12
#ifndef __SGSTRINGLIST_H__
13
#define __SGSTRINGLIST_H__
14
15
#include <
shogun/lib/config.h
>
16
17
#include <
shogun/lib/common.h
>
18
#include <
shogun/lib/SGReferencedData.h
>
19
#include <
shogun/lib/SGString.h
>
20
21
namespace
shogun
22
{
23
class
CFile;
24
template
<
class
T>
class
SGString;
25
27
template
<
class
T>
class
SGStringList :
public
SGReferencedData
28
{
29
public
:
31
SGStringList
();
32
34
SGStringList
(SGString<T>* s,
index_t
num_s,
index_t
max_length,
35
bool
ref_counting=
true
);
36
38
SGStringList
(
index_t
num_s,
index_t
max_length,
bool
ref_counting=
true
);
39
41
SGStringList
(
const
SGStringList
&orig);
42
44
virtual
~SGStringList
();
45
51
inline
SGStringList<T>
get
()
52
{
53
return
*
this
;
54
}
55
60
void
load
(
CFile
* loader);
61
66
void
save
(
CFile
* saver);
67
68
69
protected
:
70
72
virtual
void
copy_data
(
const
SGReferencedData
&orig);
73
75
virtual
void
init_data
();
76
78
void
free_data
();
79
80
public
:
82
index_t
num_strings
;
83
85
index_t
max_string_length
;
86
88
SGString<T>
*
strings
;
89
};
90
}
91
#endif // __SGSTRINGLIST_H__
shogun::SGStringList
template class SGStringList
Definition:
SGObject.h:40
SGReferencedData.h
index_t
int32_t index_t
Definition:
common.h:62
config.h
shogun::SGStringList::load
void load(CFile *loader)
Definition:
SGStringList.cpp:44
shogun::SGStringList::~SGStringList
virtual ~SGStringList()
Definition:
SGStringList.cpp:39
SGString.h
shogun::SGString
shogun string
Definition:
base/Parameter.h:25
shogun::SGStringList::init_data
virtual void init_data()
Definition:
SGStringList.cpp:73
shogun::SGReferencedData
shogun reference count managed data
Definition:
SGReferencedData.h:21
shogun::CFile
A File access base class.
Definition:
File.h:34
shogun::SGStringList::num_strings
index_t num_strings
Definition:
SGStringList.h:82
shogun::SGStringList::max_string_length
index_t max_string_length
Definition:
SGStringList.h:85
shogun
all of classes and functions are contained in the shogun namespace
Definition:
class_list.h:18
shogun::SGStringList::SGStringList
SGStringList()
Definition:
SGStringList.cpp:10
shogun::SGStringList::strings
SGString< T > * strings
Definition:
SGStringList.h:88
shogun::SGStringList::save
void save(CFile *saver)
Definition:
SGStringList.cpp:54
common.h
shogun::SGStringList::free_data
void free_data()
Definition:
SGStringList.cpp:81
shogun::SGStringList::copy_data
virtual void copy_data(const SGReferencedData &orig)
Definition:
SGStringList.cpp:65
SHOGUN
Machine Learning Toolbox - Documentation