34 #ifndef RAG_TIME_5_CLUSTER_MANAGER
35 # define RAG_TIME_5_CLUSTER_MANAGER
117 for (
int i=0; i<2; ++i)
125 for (
size_t i=0; i<
m_ids.size(); ++i)
126 if (
m_ids[i]>0)
return false;
146 return "unicodeListLink";
148 return "unknownClusterC";
152 return "fieldsList[unkn]";
175 if (z.
empty())
return o;
177 size_t numLinks=z.
m_ids.size();
178 if (numLinks>1) o <<
"[";
179 for (
size_t i=0; i<numLinks; ++i) {
183 o <<
"data" << z.
m_ids[i] <<
"A";
184 if (i+1!=numLinks) o <<
",";
186 if (numLinks>1) o <<
"]";
188 o <<
"[" << std::hex << z.
m_fieldSize << std::dec <<
":" << z.
m_N <<
"]";
398 shared_ptr<RagTime5ClusterManagerInternal::State>
m_state;
bool readClusterMainList(ClusterRoot &root, std::vector< int > &list, std::vector< int > const &clusterIdList)
try to read the cluster root list (in general Data14)
Definition: RagTime5ClusterManager.cxx:212
librevenge::RVNGString m_scriptName
the scriptname if known
Definition: RagTime5ClusterManager.hxx:315
Definition: RagTime5ClusterManager.hxx:218
int m_clusterIds[1]
other cluster id (unknown cluster b, )
Definition: RagTime5ClusterManager.hxx:281
Definition: RagTime5ClusterManager.hxx:107
virtual ~ClusterScript()
destructor
Definition: RagTime5ClusterManager.hxx:311
RagTime5Parser & m_mainParser
the main parser
Definition: RagTime5ClusterManager.hxx:400
Type m_type
the cluster type
Definition: RagTime5ClusterManager.hxx:238
Definition: RagTime5ClusterManager.hxx:221
virtual ~Cluster()
destructor
Definition: RagTime5ClusterManager.hxx:236
Type
the link type
Definition: RagTime5ClusterManager.hxx:107
Cluster(Type type)
constructor
Definition: RagTime5ClusterManager.hxx:230
bool readCluster(RagTime5Zone &zone, ClusterParser &parser, bool warnForUnparsed=true)
try to read a cluster zone
Definition: RagTime5ClusterManager.cxx:338
Definition: RagTime5ClusterManager.hxx:223
RagTime5ClusterManager & m_parser
the main parser
Definition: RagTime5ClusterManager.hxx:381
Definition: RagTime5ClusterManager.hxx:223
Definition: RagTime5ClusterManager.hxx:108
ClusterRoot()
constructor
Definition: RagTime5ClusterManager.hxx:269
RagTime5ClusterManager operator=(RagTime5ClusterManager const &orig)
Link m_linkUnknown
other link: scripts and field 6
Definition: RagTime5ClusterManager.hxx:298
Link m_listUnicodeLink
a link to a list of unknown index+unicode string
Definition: RagTime5ClusterManager.hxx:289
virtual void endZone()
end of a start zone call
Definition: RagTime5ClusterManager.hxx:357
bool m_hiLoEndian
zone endian
Definition: RagTime5ClusterManager.hxx:385
int m_styleClusterIds[8]
the list of style cluster ( graph, units, unitsbis, text, format, unknown, graphcolor, col/pattern id)
Definition: RagTime5ClusterManager.hxx:278
int m_type
the cluster type
Definition: RagTime5ClusterManager.hxx:383
Definition: RagTime5ClusterManager.hxx:217
the cluster script ( 2/a/4002/400a zone)
Definition: RagTime5ClusterManager.hxx:305
Link m_graphicTypeLink
the graphic type id
Definition: RagTime5ClusterManager.hxx:284
bool isANameHeader(long N) const
return true if N correspond to a file/script name
Definition: RagTime5ClusterManager.hxx:371
bool m_isSent
true if the cluster was send
Definition: RagTime5ClusterManager.hxx:260
Link m_listClusterLink[2]
first the main cluster link, second list of field definition link
Definition: RagTime5ClusterManager.hxx:295
virtual class use to parse the cluster data
Definition: RagTime5ClusterManager.hxx:323
Definition: RagTime5ClusterManager.hxx:109
std::vector< Link > m_conditionFormulaLinks
the conditions formula links
Definition: RagTime5ClusterManager.hxx:252
main zone in a RagTime v5-v6 document
Definition: RagTime5StructManager.hxx:48
bool readClusterGObjProperties(RagTime5Zone &zone)
try to read a level 2 child of a cluster (picture resizing, ...)
Definition: RagTime5ClusterManager.cxx:2171
Definition: RagTime5ClusterManager.hxx:217
Link m_docInfoLink
the doc info link
Definition: RagTime5ClusterManager.hxx:287
Internal: the structures of a RagTime5ClusterManager.
Definition: RagTime5ClusterManager.cxx:48
friend std::ostream & operator<<(std::ostream &o, Link const &z)
operator<<
Definition: RagTime5ClusterManager.hxx:173
librevenge::RVNGString m_fileName
the filename if known
Definition: RagTime5ClusterManager.hxx:301
std::vector< int > m_ids
the data ids
Definition: RagTime5ClusterManager.hxx:198
the cluster for root
Definition: RagTime5ClusterManager.hxx:267
std::string m_name
the link name
Definition: RagTime5ClusterManager.hxx:196
Definition: RagTime5ClusterManager.hxx:109
ClusterScript()
constructor
Definition: RagTime5ClusterManager.hxx:307
Definition: RagTime5ClusterManager.hxx:111
long m_fileType[2]
the zone type in file
Definition: RagTime5ClusterManager.hxx:204
bool m_hiLoEndian
the cluster hiLo endian
Definition: RagTime5ClusterManager.hxx:242
Definition: RagTime5ClusterManager.hxx:218
Link(Type type=L_Unknown)
constructor
Definition: RagTime5ClusterManager.hxx:115
virtual shared_ptr< Cluster > getCluster()=0
return the current cluster
ClusterParser(RagTime5ClusterManager &parser, int type, std::string const &zoneName)
constructor
Definition: RagTime5ClusterManager.hxx:325
virtual void startZone()
start a new zone
Definition: RagTime5ClusterManager.hxx:348
int m_N
the number of data ( or some flag if m_N & 0x8020)
Definition: RagTime5ClusterManager.hxx:200
Definition: RagTime5ClusterManager.hxx:110
Definition: RagTime5ClusterManager.hxx:217
Link m_listClusterName
the cluster list id name zone link
Definition: RagTime5ClusterManager.hxx:293
basic class used to manage RagTime 5/6 zones
Definition: RagTime5ClusterManager.hxx:58
Definition: RagTime5ClusterManager.hxx:221
Definition: RagTime5ClusterManager.hxx:223
std::vector< Link > m_linksList
the link list
Definition: RagTime5ClusterManager.hxx:256
RagTime5ClusterManager(RagTime5Parser &parser)
constructor
Definition: RagTime5ClusterManager.cxx:148
Link m_link
the actual link
Definition: RagTime5ClusterManager.hxx:391
virtual bool parseZone(MWAWInputStreamPtr &, long, int, int, libmwaw::DebugStream &)
parse a zone
Definition: RagTime5ClusterManager.hxx:352
Type m_type
the link type
Definition: RagTime5ClusterManager.hxx:194
int getClusterType(RagTime5Zone &zone, int fileType)
returns the local zone type
Definition: RagTime5ClusterManager.cxx:2051
the main class to read a RagTime v5 file
Definition: RagTime5Parser.hxx:72
int m_fieldSize
the field size
Definition: RagTime5ClusterManager.hxx:202
a field of RagTime 5/6 structures
Definition: RagTime5StructManager.hxx:218
Definition: RagTime5ClusterManager.hxx:110
virtual std::string getZoneName() const
return the debug name corresponding to a zone
Definition: RagTime5ClusterManager.hxx:334
std::string getClusterName(int id)
returns "data"+id+"A" ( followed by the cluster type and name if know)
Definition: RagTime5ClusterManager.cxx:497
shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:489
Definition: RagTime5ClusterManager.hxx:221
bool getClusterBasicHeaderInfo(RagTime5Zone &zone, long &N, long &fSz, long &debHeaderPos)
try to return basic information about the header cluster's zone
Definition: RagTime5ClusterManager.cxx:2030
bool readLinkHeader(MWAWInputStreamPtr &input, long fSz, Link &link, long(&values)[4], std::string &message)
try to read a link header
Definition: RagTime5ClusterManager.cxx:502
Link m_dataLink
the main data link
Definition: RagTime5ClusterManager.hxx:246
Definition: RagTime5ClusterManager.hxx:218
Type
the cluster type
Definition: RagTime5ClusterManager.hxx:216
std::vector< Link > m_settingLinks
the settings links
Definition: RagTime5ClusterManager.hxx:254
int m_listClusterId
the cluster list id
Definition: RagTime5ClusterManager.hxx:291
~RagTime5ClusterManager()
destructor
Definition: RagTime5ClusterManager.cxx:153
bool sendClusterMainList()
try to send the root cluster zone
Definition: RagTime5ClusterManager.cxx:472
Definition: RagTime5ClusterManager.hxx:227
std::vector< int > m_clusterIdsList
the cluster ids
Definition: RagTime5ClusterManager.hxx:258
Definition: RagTime5ClusterManager.hxx:227
Definition: RagTime5ClusterManager.hxx:217
librevenge::RVNGString m_name
the cluster name (if know)
Definition: RagTime5ClusterManager.hxx:244
shared_ptr< RagTime5ClusterManagerInternal::State > m_state
the state
Definition: RagTime5ClusterManager.hxx:398
Definition: RagTime5ClusterManager.hxx:223
virtual bool parseField(RagTime5StructManager::Field const &, int, libmwaw::DebugStream &)
parse a n_dataId:m
Definition: RagTime5ClusterManager.hxx:361
std::string m_name
the cluster name
Definition: RagTime5ClusterManager.hxx:387
std::stringstream DebugStream
a basic stream (if debug_with_files is not defined, does nothing)
Definition: MWAWDebug.hxx:61
Link m_scriptComment
the script comment zone
Definition: RagTime5ClusterManager.hxx:313
int m_dataId
the actual zone id
Definition: RagTime5ClusterManager.hxx:389
shared_ptr< RagTime5StructManager > m_structManager
the structure manager
Definition: RagTime5ClusterManager.hxx:402
virtual ~ClusterParser()
destructor
Definition: RagTime5ClusterManager.hxx:330
std::string getZoneName() const
returns the zone name
Definition: RagTime5ClusterManager.hxx:130
Link m_nameLink
the name link
Definition: RagTime5ClusterManager.hxx:248
bool empty() const
returns true if all link are empty
Definition: RagTime5ClusterManager.hxx:121
ClusterParser & operator=(ClusterParser const &orig)
Definition: RagTime5ClusterManager.hxx:223
basic class used to store RagTime 5/6 structures
Definition: RagTime5StructManager.hxx:156
bool readFieldClusters(Link const &link)
try to read some field cluster
Definition: RagTime5ClusterManager.cxx:299
std::string getClusterName(int id)
returns "data"+id+"A" ( followed by the cluster type and name if know)
Definition: RagTime5ClusterManager.cxx:199
bool readUnknownClusterC(Link const &link)
try to read some unknown cluster
Definition: RagTime5ClusterManager.cxx:317
int getClusterFileType(RagTime5Zone &zone)
try to find a cluster zone type ( heuristic when the cluster type is unknown )
Definition: RagTime5ClusterManager.cxx:2121
Link m_fieldClusterLink
the field cluster links (def and pos)
Definition: RagTime5ClusterManager.hxx:250
Definition: RagTime5ClusterManager.hxx:221
Definition: RagTime5ClusterManager.hxx:112
bool readFieldHeader(RagTime5Zone &zone, long endPos, std::string const &headerName, long &endDataPos, long expectedLVal=-99999)
try to read a field header, if ok set the endDataPos positions
Definition: RagTime5ClusterManager.cxx:170
virtual std::string getZoneName(int n, int m=-1) const
return the debug name corresponding to a cluster
Definition: RagTime5ClusterManager.hxx:339
int m_zoneId
the zone id
Definition: RagTime5ClusterManager.hxx:240
Definition: RagTime5ClusterManager.hxx:221
Definition: RagTime5ClusterManager.hxx:225
a link to a small zone (or set of zones) in RagTime 5/6 documents
Definition: RagTime5ClusterManager.hxx:105
the cluster data
Definition: RagTime5ClusterManager.hxx:214
virtual ~ClusterRoot()
destructor
Definition: RagTime5ClusterManager.hxx:276
std::vector< long > m_longList
a list of long used to store decal
Definition: RagTime5ClusterManager.hxx:206