-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4f17014
commit 5289b69
Showing
3 changed files
with
204 additions
and
0 deletions.
There are no files selected for viewing
119 changes: 119 additions & 0 deletions
119
...xt-data-profiler/src/main/java/org/irodsext/dataprofiler/IrodsextDataProfilerService.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,119 @@ | ||
/** | ||
* | ||
*/ | ||
package org.irodsext.dataprofiler; | ||
|
||
import org.irods.jargon.core.connection.IRODSAccount; | ||
import org.irods.jargon.core.exception.DataNotFoundException; | ||
import org.irods.jargon.core.exception.JargonException; | ||
import org.irods.jargon.core.pub.IRODSAccessObjectFactory; | ||
import org.irods.jargon.core.pub.domain.Collection; | ||
import org.irods.jargon.core.pub.domain.DataObject; | ||
import org.irods.jargon.extensions.dataprofiler.DataProfile; | ||
import org.irods.jargon.extensions.dataprofiler.DataProfileService; | ||
import org.irods.jargon.extensions.dataprofiler.DataProfilerSettings; | ||
import org.irods.jargon.extensions.datatyper.DataTypeResolutionService; | ||
import org.slf4j.Logger; | ||
import org.slf4j.LoggerFactory; | ||
|
||
/** | ||
* @author Mike Conway - NIEHS | ||
* | ||
*/ | ||
public class IrodsextDataProfilerService extends DataProfileService { | ||
|
||
public static final Logger log = LoggerFactory.getLogger(IrodsextDataProfilerService.class); | ||
|
||
/** | ||
* @param defaultDataProfilerSettings | ||
* @param dataTypeResolutionService | ||
* @param irodsAccessObjectFactory | ||
* @param irodsAccount | ||
*/ | ||
public IrodsextDataProfilerService(DataProfilerSettings defaultDataProfilerSettings, | ||
DataTypeResolutionService dataTypeResolutionService, IRODSAccessObjectFactory irodsAccessObjectFactory, | ||
IRODSAccount irodsAccount) { | ||
super(defaultDataProfilerSettings, dataTypeResolutionService, irodsAccessObjectFactory, irodsAccount); | ||
} | ||
|
||
/* | ||
* (non-Javadoc) | ||
* | ||
* @see org.irods.jargon.extensions.dataprofiler.DataProfileService# | ||
* retrieveDataProfile(java.lang.String) | ||
*/ | ||
@Override | ||
public DataProfile retrieveDataProfile(String irodsAbsolutePath) throws DataNotFoundException, JargonException { | ||
// TODO Auto-generated method stub | ||
return null; | ||
} | ||
|
||
/* | ||
* (non-Javadoc) | ||
* | ||
* @see org.irods.jargon.extensions.dataprofiler.DataProfileService# | ||
* retrieveDataProfile(java.lang.String, | ||
* org.irods.jargon.extensions.dataprofiler.DataProfilerSettings) | ||
*/ | ||
@Override | ||
public DataProfile retrieveDataProfile(String irodsAbsolutePath, DataProfilerSettings dataProfilerSettings) | ||
throws DataNotFoundException, JargonException { | ||
// TODO Auto-generated method stub | ||
return null; | ||
} | ||
|
||
/* | ||
* (non-Javadoc) | ||
* | ||
* @see org.irods.jargon.extensions.dataprofiler.DataProfileService# | ||
* retrieveDataProfileForCollection(java.lang.String) | ||
*/ | ||
@Override | ||
public DataProfile<Collection> retrieveDataProfileForCollection(String irodsAbsolutePath) | ||
throws DataNotFoundException, JargonException { | ||
// TODO Auto-generated method stub | ||
return null; | ||
} | ||
|
||
/* | ||
* (non-Javadoc) | ||
* | ||
* @see org.irods.jargon.extensions.dataprofiler.DataProfileService# | ||
* retrieveDataProfileForCollection(java.lang.String, | ||
* org.irods.jargon.extensions.dataprofiler.DataProfilerSettings) | ||
*/ | ||
@Override | ||
public DataProfile<Collection> retrieveDataProfileForCollection(String irodsAbsolutePath, | ||
DataProfilerSettings dataProfilerSettings) throws DataNotFoundException, JargonException { | ||
// TODO Auto-generated method stub | ||
return null; | ||
} | ||
|
||
/* | ||
* (non-Javadoc) | ||
* | ||
* @see org.irods.jargon.extensions.dataprofiler.DataProfileService# | ||
* retrieveDataProfileForDataObject(java.lang.String) | ||
*/ | ||
@Override | ||
public DataProfile<DataObject> retrieveDataProfileForDataObject(String irodsAbsolutePath) | ||
throws DataNotFoundException, JargonException { | ||
// TODO Auto-generated method stub | ||
return null; | ||
} | ||
|
||
/* | ||
* (non-Javadoc) | ||
* | ||
* @see org.irods.jargon.extensions.dataprofiler.DataProfileService# | ||
* retrieveDataProfileForDataObject(java.lang.String, | ||
* org.irods.jargon.extensions.dataprofiler.DataProfilerSettings) | ||
*/ | ||
@Override | ||
public DataProfile<DataObject> retrieveDataProfileForDataObject(String irodsAbsolutePath, | ||
DataProfilerSettings dataProfilerSettings) throws DataNotFoundException, JargonException { | ||
// TODO Auto-generated method stub | ||
return null; | ||
} | ||
|
||
} |
9 changes: 9 additions & 0 deletions
9
irodsext-data-profiler/src/main/java/org/irodsext/dataprofiler/package-info.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
|
||
/** | ||
* Data profiler associated with 'info' page functions of metalnx/irods-ext | ||
* schema and conventions | ||
* | ||
* @author Mike Conway - NIEHS | ||
* | ||
*/ | ||
package org.irodsext.dataprofiler; |
76 changes: 76 additions & 0 deletions
76
...ata-profiler/src/test/java/org/irodsext/dataprofiler/IrodsextDataProfilerServiceTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
/** | ||
* | ||
*/ | ||
package org.irodsext.dataprofiler; | ||
|
||
import static org.junit.Assert.fail; | ||
|
||
import java.util.Properties; | ||
|
||
import org.irods.jargon.core.connection.JargonProperties; | ||
import org.irods.jargon.core.connection.SettableJargonProperties; | ||
import org.irods.jargon.core.pub.IRODSFileSystem; | ||
import org.irods.jargon.testutils.IRODSTestSetupUtilities; | ||
import org.irods.jargon.testutils.TestingPropertiesHelper; | ||
import org.irods.jargon.testutils.filemanip.ScratchFileUtils; | ||
import org.junit.After; | ||
import org.junit.AfterClass; | ||
import org.junit.Before; | ||
import org.junit.BeforeClass; | ||
import org.junit.Test; | ||
|
||
/** | ||
* @author Mike Conway - NIEHS | ||
* | ||
*/ | ||
public class IrodsextDataProfilerServiceTest { | ||
|
||
private static Properties testingProperties = new Properties(); | ||
private static TestingPropertiesHelper testingPropertiesHelper = new TestingPropertiesHelper(); | ||
private static ScratchFileUtils scratchFileUtils = null; | ||
public static final String IRODS_TEST_SUBDIR_PATH = "IrodsextDataProfilerServiceTest"; | ||
private static IRODSTestSetupUtilities irodsTestSetupUtilities = null; | ||
private static IRODSFileSystem irodsFileSystem; | ||
private static JargonProperties jargonOriginalProperties = null; | ||
|
||
@BeforeClass | ||
public static void setUpBeforeClass() throws Exception { | ||
TestingPropertiesHelper testingPropertiesLoader = new TestingPropertiesHelper(); | ||
testingProperties = testingPropertiesLoader.getTestProperties(); | ||
scratchFileUtils = new ScratchFileUtils(testingProperties); | ||
scratchFileUtils.clearAndReinitializeScratchDirectory(IRODS_TEST_SUBDIR_PATH); | ||
irodsTestSetupUtilities = new IRODSTestSetupUtilities(); | ||
irodsTestSetupUtilities.initializeIrodsScratchDirectory(); | ||
irodsTestSetupUtilities.initializeDirectoryForTest(IRODS_TEST_SUBDIR_PATH); | ||
irodsFileSystem = IRODSFileSystem.instance(); | ||
SettableJargonProperties settableJargonProperties = new SettableJargonProperties( | ||
irodsFileSystem.getJargonProperties()); | ||
jargonOriginalProperties = settableJargonProperties; | ||
} | ||
|
||
@AfterClass | ||
public static void tearDownAfterClass() throws Exception { | ||
irodsFileSystem.closeAndEatExceptions(); | ||
} | ||
|
||
@Before | ||
public void before() throws Exception { | ||
// be sure that normal config is set up | ||
irodsFileSystem.getIrodsSession().setJargonProperties(jargonOriginalProperties); | ||
} | ||
|
||
@After | ||
public void afterEach() throws Exception { | ||
irodsFileSystem.closeAndEatExceptions(); | ||
} | ||
|
||
/** | ||
* Test method for | ||
* {@link org.irodsext.dataprofiler.IrodsextDataProfilerService#retrieveDataProfile(java.lang.String, org.irods.jargon.extensions.dataprofiler.DataProfilerSettings)}. | ||
*/ | ||
@Test | ||
public void testRetrieveDataProfileStringDataProfilerSettings() { | ||
fail("Not yet implemented"); | ||
} | ||
|
||
} |