org.eaglei.datatools.etl.utils
Class DeETL

java.lang.Object
  extended by org.eaglei.datatools.etl.utils.DeETL

public class DeETL
extends java.lang.Object

This class is for deleting instances which ETled from particular file, -f takes filename as input ,this is the file name which we want to delete all instances ETLed from .-r takes repository configuration file path FLOW : deleteInsntaceETledFromFIle(String) takes file name as input ,it then calls getResourcesOfFile(String) where it builds query to ge the Instance URI's we want to delete,It builds the query by calling SPARQLQueryUtil.getInstance().getResourcesETLedFromFileQuery(fileName); .We query repository using the query which we built it then returns results in xml format ,xml is parsed for Instance URIs in ETLSPARQLQueryUtil.getInstanceURI(resources) method ,which returns array if instance URI's . instanceURI array is then passed to deleteInsntaceETledFromFIle(String) where it will be deleted one by one by looping throught he array

Author:
Sravan Kumar Cheriyala

Constructor Summary
DeETL()
          Constructor where we get the ReposiotryProvider object and also gets session by loging into reposiotry
 
Method Summary
 int deleteInstanceETLedFromFile(java.lang.String fileName)
          Delete the instances which are ETLed from fileName
static java.lang.String getFileName()
           
static RDFtoRepoService getRdftorepo()
           
static java.lang.String getRepo()
           
 java.lang.String[] getResourcesOfFile(java.lang.String fileName)
          gets the resources Array by making query and queriying it against repository
 org.eaglei.security.Session getSession()
           
static void main(java.lang.String[] args)
           
static void setRepo(java.lang.String repo)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DeETL

public DeETL()
      throws org.apache.commons.configuration.ConfigurationException,
             java.io.IOException
Constructor where we get the ReposiotryProvider object and also gets session by loging into reposiotry

Throws:
org.apache.commons.configuration.ConfigurationException
java.io.IOException
Method Detail

main

public static void main(java.lang.String[] args)
                 throws java.lang.Exception
Throws:
java.lang.Exception

deleteInstanceETLedFromFile

public int deleteInstanceETLedFromFile(java.lang.String fileName)
                                throws java.lang.Exception
Delete the instances which are ETLed from fileName

Throws:
java.lang.Exception

getResourcesOfFile

public java.lang.String[] getResourcesOfFile(java.lang.String fileName)
gets the resources Array by making query and queriying it against repository

Parameters:
fileName -
Returns:

getSession

public org.eaglei.security.Session getSession()

getRepo

public static java.lang.String getRepo()

setRepo

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

getFileName

public static java.lang.String getFileName()

getRdftorepo

public static RDFtoRepoService getRdftorepo()


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