Android Open Source - HRForecast-WFM Test Serializer






From Project

Back to project page HRForecast-WFM.

License

The source code is released under:

Copyright 2014 Ahmed Shafei

If you think the Android project HRForecast-WFM listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package de.hrf.workforcemanagement.models;
//from  www.  j av  a  2s. co  m
import java.io.File;

import org.simpleframework.xml.Serializer;
import org.simpleframework.xml.core.Persister;


public class TestSerializer {
  public static void main(String[] args) throws Exception {
    /* Deserializing an example object from chartTest.xml */
    Serializer serializer = new Persister();
//    File source = new File("chartTest.xml");
//    Chart chart = serializer.read(Chart.class, source);
//    System.out.println("Chart TestXML\n-----------------");
//    System.out.println("Chart id:" + chart.getId());
//    System.out.println("Chart properties:" + chart.getPropertyList());
//    System.out.println("Chart category:" + chart.getCategory());
//    System.out.println("Chart subcategory:" + chart.getSubcategory());
//    System.out.println("Chart filters:" + chart.getFilterList());
//    System.out.println(chart.getChartList().get(0).properties);
//    System.out.println("--------------------------------------------------------------");
//    for (int i = 0; i < chart.getChartList().size(); i++) {
//      System.out.println(chart.getChartList().get(i));
//    }
    
    /* Deserializing an example object from filter.xml */
    File source = new File("filter.xml");
    CoreFilter filter = serializer.read(CoreFilter.class, source);
    System.out.println("Filter\n-----------------");
    System.out.println("Filter id:" + filter.getId());
    System.out.println("Filter properties:" + filter.getFilterPropertyList());
    System.out.println("Filter label:" + filter.getLabel());
    System.out.println("Filter family:" + filter.getFamily());
    System.out.println("--------------------------------------------------------------");
    for (int i = 0; i < filter.getChartList().size(); i++) {
      System.out.println(filter.getChartList().get(i));
    }
    
  }
}




Java Source Code List

de.hrf.workforcemanagement.AnalysisMainActivity.java
de.hrf.workforcemanagement.BarChartFragment.java
de.hrf.workforcemanagement.BubbleChartFragment.java
de.hrf.workforcemanagement.CustomAdapter.java
de.hrf.workforcemanagement.CustomOnItemSelectedListener.java
de.hrf.workforcemanagement.HorizontalBarChartFragment.java
de.hrf.workforcemanagement.LineBarChartFragment.java
de.hrf.workforcemanagement.LineChartFragment.java
de.hrf.workforcemanagement.MainActivity.java
de.hrf.workforcemanagement.PieChartFragment.java
de.hrf.workforcemanagement.RadarChartFragment.java
de.hrf.workforcemanagement.RowModel.java
de.hrf.workforcemanagement.StackedBarChartFragment.java
de.hrf.workforcemanagement.adapter.MetadataListAdapter.java
de.hrf.workforcemanagement.dialog.BaseDialog.java
de.hrf.workforcemanagement.dialog.MetadataListDialog.java
de.hrf.workforcemanagement.listener.ChartValueSelectedListener.java
de.hrf.workforcemanagement.models.Bar.java
de.hrf.workforcemanagement.models.ChartType.java
de.hrf.workforcemanagement.models.Chart.java
de.hrf.workforcemanagement.models.Color.java
de.hrf.workforcemanagement.models.CoreFilter.java
de.hrf.workforcemanagement.models.Dimension.java
de.hrf.workforcemanagement.models.Filter.java
de.hrf.workforcemanagement.models.MetadataList.java
de.hrf.workforcemanagement.models.Metadata.java
de.hrf.workforcemanagement.models.Property.java
de.hrf.workforcemanagement.models.SpecialChartXAxis.java
de.hrf.workforcemanagement.models.SpecialChartYAxis.java
de.hrf.workforcemanagement.models.StandardChartAxis.java
de.hrf.workforcemanagement.models.StandardChartXAxis.java
de.hrf.workforcemanagement.models.StandardChartYAxis.java
de.hrf.workforcemanagement.models.TestSerializer.java
de.hrf.workforcemanagement.models.barchart.BarChart.java
de.hrf.workforcemanagement.models.bubblechart.BubbleChart.java
de.hrf.workforcemanagement.models.bubblechart.BubbleData.java
de.hrf.workforcemanagement.models.bubblechart.BubbleYAxis.java
de.hrf.workforcemanagement.models.linechart.LineChart.java
de.hrf.workforcemanagement.models.linechart.LinePoint.java
de.hrf.workforcemanagement.models.piechart.PieChart.java
de.hrf.workforcemanagement.models.piechart.PieLabel.java
de.hrf.workforcemanagement.models.piechart.PieRegion.java
de.hrf.workforcemanagement.models.radarchart.RadarChart.java
de.hrf.workforcemanagement.models.radarchart.RadarRegion.java
de.hrf.workforcemanagement.models.radarchart.RadarYAxis.java
de.hrf.workforcemanagement.models.stackedbarchart.StackedbarChart.java
de.hrf.workforcemanagement.parser.ChartParser.java