atomes 1.1.16
atomes: an atomic scale modeling tool box
Loading...
Searching...
No Matches
read_isaacs.c File Reference

Functions to read an ISAACS XML file
Functions to write an ISAACS XML file. More...

#include <libxml/encoding.h>
#include <libxml/xmlwriter.h>
#include <libxml/xmlreader.h>
#include <libxml/parser.h>
#include "global.h"
#include "interface.h"
#include "callbacks.h"
+ Include dependency graph for read_isaacs.c:

Go to the source code of this file.

Macros

#define MY_ENCODING   "UTF-8"
 
#define NFORMATS   7
 

Functions

int open_coordinate_file (int id)
 try to open coordinate file, type is based of id
 
size_t strfind (char *ida)
 size of a string without spaces
 
int XmlwriterFilename (const char *uri)
 write ISAACS XML file
 
int write_xml (const char *filetosave)
 write XML file
 
gboolean file_exists (const char *filename)
 file exists ?
 
xmlNodePtr findnode (xmlNodePtr startnode, char *nname)
 find XML node
 
int get_spec_from_data (xmlChar *data)
 get atomic species from data
 
int setprop (xmlNodePtr pnode)
 read chemical properties from XML node
 
int testopening (char *tdata, char *tfichier)
 test atomic coordinates file opening
 
int setchemistry (xmlNodePtr xsnode)
 read chemistry data from node
 
int setbox (xmlNodePtr boxnode)
 read box properties from node
 
int setpbc (xmlNodePtr pbcnode)
 read the PBC information from node
 
int setcutoffs (xmlNodePtr cutnode)
 read bond cutoffs from node
 
int settime (xmlNodePtr timenode)
 read MD information from node
 
int check_xml (const char *filetocheck)
 check the opening of ISAACS XML file
 
gchar * open_xml (const char *filetoread)
 Open ISAACS XML file.
 

Variables

char * reg_types [NFORMATS]
 

Detailed Description

Functions to read an ISAACS XML file
Functions to write an ISAACS XML file.

Author
Sébastien Le Roux sebas.nosp@m.tien.nosp@m..lero.nosp@m.ux@i.nosp@m.pcms..nosp@m.unis.nosp@m.tra.f.nosp@m.r

Definition in file read_isaacs.c.

Macro Definition Documentation

◆ MY_ENCODING

#define MY_ENCODING   "UTF-8"

Definition at line 66 of file read_isaacs.c.

◆ NFORMATS

#define NFORMATS   7

Definition at line 70 of file read_isaacs.c.

Function Documentation

◆ check_xml()

int check_xml ( const char * filetocheck)

check the opening of ISAACS XML file

Parameters
filetocheckFile name

Definition at line 1237 of file read_isaacs.c.

◆ file_exists()

gboolean file_exists ( const char * filename)

file exists ?

Parameters
filenameFile name

Definition at line 529 of file read_isaacs.c.

◆ findnode()

xmlNodePtr findnode ( xmlNodePtr startnode,
char * nname )

find XML node

Parameters
startnodeStarting node
nnameNode name to find

Definition at line 548 of file read_isaacs.c.

◆ get_spec_from_data()

int get_spec_from_data ( xmlChar * data)

get atomic species from data

Parameters
datathe data

Definition at line 571 of file read_isaacs.c.

◆ open_coordinate_file()

int open_coordinate_file ( int id)
extern

try to open coordinate file, type is based of id

Parameters
idfile type to open

Definition at line 1268 of file callbacks.c.

◆ open_xml()

gchar * open_xml ( const char * filetoread)

Open ISAACS XML file.

Parameters
filetoreadFile name

Definition at line 1409 of file read_isaacs.c.

◆ setbox()

int setbox ( xmlNodePtr boxnode)

read box properties from node

Parameters
boxnodethe XML node

Definition at line 867 of file read_isaacs.c.

◆ setchemistry()

int setchemistry ( xmlNodePtr xsnode)

read chemistry data from node

Parameters
xsnodethe XML node

Definition at line 773 of file read_isaacs.c.

◆ setcutoffs()

int setcutoffs ( xmlNodePtr cutnode)

read bond cutoffs from node

Parameters
cutnodethe XML node

Definition at line 1114 of file read_isaacs.c.

◆ setpbc()

int setpbc ( xmlNodePtr pbcnode)

read the PBC information from node

Parameters
pbcnodethe XML node

Definition at line 1060 of file read_isaacs.c.

◆ setprop()

int setprop ( xmlNodePtr pnode)

read chemical properties from XML node

Parameters
pnodethe XML node

Definition at line 591 of file read_isaacs.c.

◆ settime()

int settime ( xmlNodePtr timenode)

read MD information from node

Parameters
timenodethe XML node

Definition at line 1177 of file read_isaacs.c.

◆ strfind()

size_t strfind ( char * ida)

size of a string without spaces

Parameters
ida

Definition at line 87 of file read_isaacs.c.

◆ testopening()

int testopening ( char * tdata,
char * tfichier )

test atomic coordinates file opening

Parameters
tdataType of coordinates
tfichierFile name

Definition at line 697 of file read_isaacs.c.

◆ write_xml()

int write_xml ( const char * filetosave)

write XML file

Parameters
filetosaveFile to write

Definition at line 507 of file read_isaacs.c.

◆ XmlwriterFilename()

int XmlwriterFilename ( const char * uri)

write ISAACS XML file

Parameters
*urithe file name

Definition at line 110 of file read_isaacs.c.

Variable Documentation

◆ reg_types

char* reg_types[NFORMATS]
Initial value:
= {"XYZ file",
"Chem3D file",
"CPMD trajectory",
"VASP trajectory",
"multiple XYZ file",
"multiple Chem3D file",
"PDB file"}

Definition at line 72 of file read_isaacs.c.