Package thredds.catalog.dl
Class DIFWriter
- java.lang.Object
-
- thredds.catalog.dl.DIFWriter
-
public class DIFWriter extends Object
-
-
Constructor Summary
Constructors Constructor Description DIFWriter()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
doOneDataset(InvDataset ds)
Write a DIF record for a specific datasetvoid
doOneDataset(InvDataset ds, String fileDir, StringBuilder mess)
Write a DIF record for a specific datasetboolean
isDatasetUseable(InvDataset ds, StringBuilder sbuff)
See if a dataset is harvestable to a DIF record.static void
main(String[] args)
testingvoid
writeDatasetEntries(InvCatalogImpl cat, String fileDir, StringBuilder mess)
Write all harvestable datasets to DIF records that have at least the minimum metadata.
-
-
-
Method Detail
-
writeDatasetEntries
public void writeDatasetEntries(InvCatalogImpl cat, String fileDir, StringBuilder mess)
Write all harvestable datasets to DIF records that have at least the minimum metadata. Call isDatasetUseable() to find out.- Parameters:
cat
- harvest the datasets starting from herefileDir
- write records to this directory. The dataset id is used as the filename, appending "dif.xml"mess
- status messages are appended here
-
doOneDataset
public void doOneDataset(InvDataset ds)
Write a DIF record for a specific dataset- Parameters:
ds
- use this dataset
-
doOneDataset
public void doOneDataset(InvDataset ds, String fileDir, StringBuilder mess)
Write a DIF record for a specific dataset- Parameters:
ds
- use this datasetfileDir
- write records to this directory. The dataset id is used as the filename, appending "dif.xml"mess
- status messages are appended here
-
isDatasetUseable
public boolean isDatasetUseable(InvDataset ds, StringBuilder sbuff)
See if a dataset is harvestable to a DIF record.- Parameters:
ds
- check this dataset.sbuff
- put status messages here.- Returns:
- true if a DIF record can be written
-
-