org.eaglei.datatools.etl.server
Class RdfMaker

java.lang.Object
  extended by org.eaglei.datatools.etl.server.RdfMaker

public class RdfMaker
extends java.lang.Object


Constructor Summary
RdfMaker(org.eaglei.datatools.model.AnnotationFormModel anntModel, org.eaglei.model.jena.JenaEIInstanceFactory instanceFactory)
           
 
Method Summary
 java.util.Map<java.lang.String,ExcelAbstractions.ExcelTab> ExcelToTableModel(java.io.InputStream excelInputStream)
          converts Excel into CSV TableModel
 java.util.Map<java.lang.String,com.hp.hpl.jena.rdf.model.Model> generateRDFGraph(java.util.Map<java.lang.String,ExcelAbstractions.ExcelTab> tableModelMap, java.util.Map<java.lang.String,java.io.InputStream> mapStreamMap)
          Generates RDGGraph by tableModel and mapStream and pushes into Repo
 int getCount()
           
static java.lang.String getCurrentlyProcessingFile()
           
static java.lang.String getDirectory()
           
 java.util.Map<java.lang.String,java.lang.String> getGlobalColumnsHash()
           
 java.io.InputStream getInputStreamOfExcelFile(java.lang.String excelFolder, java.lang.String excelFile)
           
 java.lang.String[] getLabelAndRootURI(com.hp.hpl.jena.rdf.model.Model tempModel, int row, Rdf123Expression rdf123Exp)
           
 java.lang.String getLabelBySubjectExpression(com.hp.hpl.jena.rdf.model.Model tempModel, int row, Rdf123Expression rdf123Exp, java.lang.String subjectExpression)
           
static java.lang.String getLog()
           
static java.lang.String getMaps()
           
 java.lang.String getObjectFromModelBySubjectAndType(com.hp.hpl.jena.rdf.model.Model rdfModel, java.lang.String subjectExpression)
           
static java.lang.String getOutputdirectory()
           
static java.lang.String getPromoteParameter()
           
static RDFtoRepoService getRdftorepo()
           
static java.lang.String getRepo()
           
 org.eaglei.security.Session getSession()
           
 java.lang.String getTypeFromModelByObject(com.hp.hpl.jena.rdf.model.Model rdfModel, java.lang.String objectExpression)
           
static void main(java.lang.String[] args)
           
 boolean rdfToRepoByExcelStream(java.lang.String excelFolder, java.lang.String mapFolder)
          Get all files from the specified directory and call generateRDFGraph(which inturn generates the RDF and pushes into Repo)
static void setCurrentlyProcessingFile(java.lang.String currentlyProcessingFile)
           
static void setDirectory(java.lang.String directory)
           
 void setGlobalColumnsHash(java.util.Map<java.lang.String,java.lang.String> globalColumnsHash)
           
static void setLog(java.lang.String log)
           
static void setMaps(java.lang.String maps)
           
static void setOutputdirectory(java.lang.String oputputdirectory)
           
static void setPromoteParameter(java.lang.String promoteParameter)
           
static void setRdftorepo(RDFtoRepoService rdftorepo)
           
static void setRepo(java.lang.String repo)
           
 void setSession(org.eaglei.security.Session session)
           
 void updateInstanceIfAdditionalDatafound(java.lang.String instanceID, com.hp.hpl.jena.rdf.model.Model modelFromExcel, java.lang.String subjectExpression)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RdfMaker

public RdfMaker(org.eaglei.datatools.model.AnnotationFormModel anntModel,
                org.eaglei.model.jena.JenaEIInstanceFactory instanceFactory)
         throws java.lang.Exception
Throws:
java.lang.Exception
Method Detail

main

public static void main(java.lang.String[] args)

getCount

public int getCount()

getSession

public org.eaglei.security.Session getSession()

setSession

public final void setSession(org.eaglei.security.Session session)

rdfToRepoByExcelStream

public boolean rdfToRepoByExcelStream(java.lang.String excelFolder,
                                      java.lang.String mapFolder)
                               throws java.lang.Exception
Get all files from the specified directory and call generateRDFGraph(which inturn generates the RDF and pushes into Repo)

Throws:
java.lang.Exception

getInputStreamOfExcelFile

public java.io.InputStream getInputStreamOfExcelFile(java.lang.String excelFolder,
                                                     java.lang.String excelFile)
                                              throws java.io.FileNotFoundException
Throws:
java.io.FileNotFoundException

generateRDFGraph

public java.util.Map<java.lang.String,com.hp.hpl.jena.rdf.model.Model> generateRDFGraph(java.util.Map<java.lang.String,ExcelAbstractions.ExcelTab> tableModelMap,
                                                                                        java.util.Map<java.lang.String,java.io.InputStream> mapStreamMap)
                                                                                 throws java.lang.Exception
Generates RDGGraph by tableModel and mapStream and pushes into Repo

Throws:
java.lang.Exception
java.lang.Exception

ExcelToTableModel

public java.util.Map<java.lang.String,ExcelAbstractions.ExcelTab> ExcelToTableModel(java.io.InputStream excelInputStream)
                                                                             throws org.apache.commons.configuration.ConfigurationException,
                                                                                    java.io.IOException
converts Excel into CSV TableModel

Parameters:
excelInputStream -
Returns:
Throws:
org.apache.commons.configuration.ConfigurationException
java.io.IOException
java.lang.Exception

getLabelAndRootURI

public java.lang.String[] getLabelAndRootURI(com.hp.hpl.jena.rdf.model.Model tempModel,
                                             int row,
                                             Rdf123Expression rdf123Exp)
                                      throws java.lang.Exception
Throws:
java.lang.Exception

getLabelBySubjectExpression

public java.lang.String getLabelBySubjectExpression(com.hp.hpl.jena.rdf.model.Model tempModel,
                                                    int row,
                                                    Rdf123Expression rdf123Exp,
                                                    java.lang.String subjectExpression)
                                             throws java.lang.Exception
Throws:
java.lang.Exception

getObjectFromModelBySubjectAndType

public java.lang.String getObjectFromModelBySubjectAndType(com.hp.hpl.jena.rdf.model.Model rdfModel,
                                                           java.lang.String subjectExpression)

getTypeFromModelByObject

public java.lang.String getTypeFromModelByObject(com.hp.hpl.jena.rdf.model.Model rdfModel,
                                                 java.lang.String objectExpression)

updateInstanceIfAdditionalDatafound

public void updateInstanceIfAdditionalDatafound(java.lang.String instanceID,
                                                com.hp.hpl.jena.rdf.model.Model modelFromExcel,
                                                java.lang.String subjectExpression)
                                         throws java.lang.Exception
Throws:
java.lang.Exception

getGlobalColumnsHash

public java.util.Map<java.lang.String,java.lang.String> getGlobalColumnsHash()

setGlobalColumnsHash

public void setGlobalColumnsHash(java.util.Map<java.lang.String,java.lang.String> globalColumnsHash)

getRepo

public static java.lang.String getRepo()

setRepo

public static void setRepo(java.lang.String repo)

getDirectory

public static java.lang.String getDirectory()

setDirectory

public static void setDirectory(java.lang.String directory)

getOutputdirectory

public static java.lang.String getOutputdirectory()

setOutputdirectory

public static void setOutputdirectory(java.lang.String oputputdirectory)

getPromoteParameter

public static java.lang.String getPromoteParameter()

setPromoteParameter

public static void setPromoteParameter(java.lang.String promoteParameter)

getCurrentlyProcessingFile

public static java.lang.String getCurrentlyProcessingFile()

setCurrentlyProcessingFile

public static void setCurrentlyProcessingFile(java.lang.String currentlyProcessingFile)

getRdftorepo

public static RDFtoRepoService getRdftorepo()

setRdftorepo

public static void setRdftorepo(RDFtoRepoService rdftorepo)

getMaps

public static java.lang.String getMaps()

setMaps

public static void setMaps(java.lang.String maps)

getLog

public static java.lang.String getLog()

setLog

public static void setLog(java.lang.String log)


Copyright © 2009-2011 Eagle-I. All Rights Reserved.