BrightSide Workbench Full Report + Source Code
org.turro.erp.time.XMLTimeControlSet Class Reference
Inheritance diagram for org.turro.erp.time.XMLTimeControlSet:
Collaboration diagram for org.turro.erp.time.XMLTimeControlSet:

Public Member Functions

 XMLTimeControlSet (IConstructor constructor)
 
void saveCollection ()
 
void createCopy ()
 

Static Public Attributes

static final String XML_TIMECONTROL = "/WEB-INF/local/timeControl.xml"
 

Detailed Description

Author
Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g

Definition at line 45 of file XMLTimeControlSet.java.

Constructor & Destructor Documentation

◆ XMLTimeControlSet()

org.turro.erp.time.XMLTimeControlSet.XMLTimeControlSet ( IConstructor  constructor)

Definition at line 51 of file XMLTimeControlSet.java.

51  {
52  this.constructor = constructor;
53  loadCollection();
54  }

Member Function Documentation

◆ createCopy()

void org.turro.erp.time.XMLTimeControlSet.createCopy ( )

Definition at line 72 of file XMLTimeControlSet.java.

72  {
73  File confFile = new File(ElephantContext.getRealPath(XML_TIMECONTROL));
74  File copseg = new File(FileUtil.getFolderFile(confFile).getAbsolutePath() + "/copseg");
75  copseg.mkdirs();
76  try {
77  org.amic.util.file.FileUtil.copyFile(confFile, copseg.getAbsolutePath());
78  } catch (IOException ex) {
79  Logger.getLogger(XMLTimeControlSet.class.getName()).log(Level.SEVERE, null, ex);
80  }
81  }
XMLTimeControlSet(IConstructor constructor)
Here is the call graph for this function:

◆ saveCollection()

void org.turro.erp.time.XMLTimeControlSet.saveCollection ( )

Definition at line 56 of file XMLTimeControlSet.java.

56  {
57  Document doc = new Document(new Element("time-controls"));
58  writeXML(doc.getRootElement());
59  try {
60  OutputStreamWriter fw = FileUtil.getFileWriter(
61  ElephantContext.getRealPath(XML_TIMECONTROL));
62  Format fm = Format.getPrettyFormat();
63  fm.setEncoding(ElephantContext.getEncoding());
64  XMLOutputter xo = new XMLOutputter(fm);
65  xo.output(doc, fw);
66  fw.close();
67  } catch (IOException ex) {
68  Logger.getLogger(XMLHumanResourceSet.class.getName()).log(Level.SEVERE, null, ex);
69  }
70  }
Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ XML_TIMECONTROL

final String org.turro.erp.time.XMLTimeControlSet.XML_TIMECONTROL = "/WEB-INF/local/timeControl.xml"
static

Definition at line 47 of file XMLTimeControlSet.java.


The documentation for this class was generated from the following file: