mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-08 10:34:25 +00:00
Compare commits
59 Commits
rest-tutor
...
dspace-1.6
Author | SHA1 | Date | |
---|---|---|---|
![]() |
ca73b41d05 | ||
![]() |
8995238be1 | ||
![]() |
628295e107 | ||
![]() |
6c49c32214 | ||
![]() |
a3a70825ce | ||
![]() |
0cea409f31 | ||
![]() |
24fbc03630 | ||
![]() |
6770810462 | ||
![]() |
11e85e4bed | ||
![]() |
eacde4aa32 | ||
![]() |
16c633b226 | ||
![]() |
6358b152eb | ||
![]() |
d9d91ce552 | ||
![]() |
bb0534d912 | ||
![]() |
394be66d74 | ||
![]() |
002b1c22b4 | ||
![]() |
5f1bcaa437 | ||
![]() |
d9f1e08fe7 | ||
![]() |
a7d52b7802 | ||
![]() |
6500a2e5ac | ||
![]() |
fdfab3da14 | ||
![]() |
edb9b9b8b1 | ||
![]() |
ef0cd21f64 | ||
![]() |
1b0f45a8d6 | ||
![]() |
1c6ebb0d4a | ||
![]() |
44a8a763a9 | ||
![]() |
ebc891d3d7 | ||
![]() |
c1317f8753 | ||
![]() |
cb401c2eb2 | ||
![]() |
0549c5947b | ||
![]() |
fdadd8aa9c | ||
![]() |
9fcd19153a | ||
![]() |
863d4d647a | ||
![]() |
42adb70f8d | ||
![]() |
da8285393c | ||
![]() |
e1f72043a7 | ||
![]() |
5d9691e010 | ||
![]() |
32da19a323 | ||
![]() |
2e307d5904 | ||
![]() |
815d9dd125 | ||
![]() |
aa1d546474 | ||
![]() |
e8e5bddd61 | ||
![]() |
4fcafbbcdb | ||
![]() |
8d107326e1 | ||
![]() |
dc5ecddc95 | ||
![]() |
2b51d2fbbf | ||
![]() |
c3f730bb4b | ||
![]() |
c207333067 | ||
![]() |
2501b276fc | ||
![]() |
216a7b4665 | ||
![]() |
0c0b6e6c25 | ||
![]() |
f2fde095c0 | ||
![]() |
072416ad3a | ||
![]() |
91bdd593c9 | ||
![]() |
668a4b7d14 | ||
![]() |
b4a55a7011 | ||
![]() |
f2be846fb9 | ||
![]() |
81e7c37073 | ||
![]() |
c82e847113 |
@@ -13,7 +13,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -39,9 +39,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace</url>
|
||||
</scm>
|
||||
|
||||
<!--
|
||||
|
@@ -66,11 +66,17 @@ public class BulkEditChange
|
||||
/** The ArrayList of the complete set of new values (constant + adds) */
|
||||
private ArrayList<DCValue> complete;
|
||||
|
||||
/** The Arraylist of old collections the item has been moved from */
|
||||
private ArrayList<Collection> oldOwningCollections;
|
||||
/** The Arraylist of old collections the item used to be mapped to */
|
||||
private ArrayList<Collection> oldMappedCollections;
|
||||
|
||||
/** The Arraylist of new collections the item has been moved into */
|
||||
private ArrayList<Collection> newOwningCollections;
|
||||
/** The Arraylist of new collections the item has been mapped into */
|
||||
private ArrayList<Collection> newMappedCollections;
|
||||
|
||||
/** The old owning collection */
|
||||
private Collection oldOwningCollection;
|
||||
|
||||
/** The new owning collection */
|
||||
private Collection newOwningCollection;
|
||||
|
||||
/** Is this a new item */
|
||||
private boolean newItem;
|
||||
@@ -88,14 +94,16 @@ public class BulkEditChange
|
||||
item = null;
|
||||
newItem = true;
|
||||
empty = true;
|
||||
oldOwningCollection = null;
|
||||
newOwningCollection = null;
|
||||
|
||||
// Initialise the arrays
|
||||
adds = new ArrayList<DCValue>();
|
||||
removes = new ArrayList<DCValue>();
|
||||
constant = new ArrayList<DCValue>();
|
||||
complete = new ArrayList<DCValue>();
|
||||
oldOwningCollections = new ArrayList<Collection>();
|
||||
newOwningCollections = new ArrayList<Collection>();
|
||||
oldMappedCollections = new ArrayList<Collection>();
|
||||
newMappedCollections = new ArrayList<Collection>();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -115,8 +123,8 @@ public class BulkEditChange
|
||||
removes = new ArrayList<DCValue>();
|
||||
constant = new ArrayList<DCValue>();
|
||||
complete = new ArrayList<DCValue>();
|
||||
oldOwningCollections = new ArrayList<Collection>();
|
||||
newOwningCollections = new ArrayList<Collection>();
|
||||
oldMappedCollections = new ArrayList<Collection>();
|
||||
newMappedCollections = new ArrayList<Collection>();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -168,28 +176,75 @@ public class BulkEditChange
|
||||
}
|
||||
|
||||
/**
|
||||
* Add a new owning Collection
|
||||
* Add a new mapped Collection
|
||||
*
|
||||
* @param c The new owning Collection
|
||||
* @param c The new mapped Collection
|
||||
*/
|
||||
public void registerNewOwningCollection(Collection c)
|
||||
public void registerNewMappedCollection(Collection c)
|
||||
{
|
||||
// Add the new owning Collection\
|
||||
newOwningCollections.add(c);
|
||||
// Add the new owning Collection
|
||||
newMappedCollections.add(c);
|
||||
empty = false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add an old owning Collection
|
||||
* Add an old mapped Collection
|
||||
*
|
||||
* @param c The old owning Collection
|
||||
* @param c The old mapped Collection
|
||||
*/
|
||||
public void registerOldOwningCollection(Collection c)
|
||||
public void registerOldMappedCollection(Collection c)
|
||||
{
|
||||
// Add the old owning Collection\
|
||||
oldOwningCollections.add(c);
|
||||
// Add the old owning Collection (if it isn't there already, or is an old collection)
|
||||
boolean found = false;
|
||||
|
||||
if ((this.getOldOwningCollection() != null) &&
|
||||
(this.getOldOwningCollection().getHandle().equals(c.getHandle())))
|
||||
{
|
||||
found = true;
|
||||
}
|
||||
|
||||
for (Collection collection : oldMappedCollections)
|
||||
{
|
||||
if (collection.getHandle().equals(c.getHandle()))
|
||||
{
|
||||
found = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (!found)
|
||||
{
|
||||
oldMappedCollections.add(c);
|
||||
empty = false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Register a change to the owning collection
|
||||
*
|
||||
* @param oldC The old owning collection
|
||||
* @param newC The new owning collection
|
||||
*/
|
||||
public void changeOwningCollection(Collection oldC, Collection newC)
|
||||
{
|
||||
// Store the old owning collection
|
||||
oldOwningCollection = oldC;
|
||||
|
||||
// Store the new owning collection
|
||||
newOwningCollection = newC;
|
||||
empty = false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the owning collection of an item
|
||||
*
|
||||
* @param newC The new owning collection
|
||||
*/
|
||||
public void setOwningCollection(Collection newC)
|
||||
{
|
||||
// Store the new owning collection
|
||||
newOwningCollection = newC;
|
||||
//empty = false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the DSpace Item that these changes are applicable to.
|
||||
@@ -247,25 +302,47 @@ public class BulkEditChange
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the list of new owning Collections
|
||||
* Get the list of new mapped Collections
|
||||
*
|
||||
* @return the list of new owning collections
|
||||
* @return the list of new mapped collections
|
||||
*/
|
||||
public ArrayList<Collection> getNewOwningCollections()
|
||||
public ArrayList<Collection> getNewMappedCollections()
|
||||
{
|
||||
// Return the array
|
||||
return newOwningCollections;
|
||||
return newMappedCollections;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the list of old owning Collections
|
||||
* Get the list of old mapped Collections
|
||||
*
|
||||
* @return the list of old owning collections
|
||||
* @return the list of old mapped collections
|
||||
*/
|
||||
public ArrayList<Collection> getOldOwningCollections()
|
||||
public ArrayList<Collection> getOldMappedCollections()
|
||||
{
|
||||
// Return the array
|
||||
return oldOwningCollections;
|
||||
return oldMappedCollections;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the old owning collection
|
||||
*
|
||||
* @return the old owning collection
|
||||
*/
|
||||
public Collection getOldOwningCollection()
|
||||
{
|
||||
// Return the old owning collection
|
||||
return oldOwningCollection;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the new owning collection
|
||||
*
|
||||
* @return the new owning collection
|
||||
*/
|
||||
public Collection getNewOwningCollection()
|
||||
{
|
||||
// Return the new owning collection
|
||||
return newOwningCollection;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -265,12 +265,20 @@ public class DSpaceCSV
|
||||
// Create the CSV line
|
||||
DSpaceCSVLine line = new DSpaceCSVLine(i.getID());
|
||||
|
||||
// Add in owning collections
|
||||
// Add in owning collection
|
||||
String owningCollectionHandle = i.getOwningCollection().getHandle();
|
||||
line.add("collection", owningCollectionHandle);
|
||||
|
||||
// Add in any mapped collections
|
||||
Collection[] collections = i.getCollections();
|
||||
for (Collection c : collections)
|
||||
{
|
||||
// Only add if it is not the owning collection
|
||||
if (!c.getHandle().equals(owningCollectionHandle))
|
||||
{
|
||||
line.add("collection", c.getHandle());
|
||||
}
|
||||
}
|
||||
|
||||
// Populate it
|
||||
DCValue md[] = i.getMetadata(Item.ANY, Item.ANY, Item.ANY, Item.ANY);
|
||||
|
@@ -120,6 +120,10 @@ public class MetadataImport
|
||||
{
|
||||
// Get the item
|
||||
Item item = Item.find(c, id);
|
||||
if (item == null)
|
||||
{
|
||||
throw new MetadataImportException("Unknown item ID " + id);
|
||||
}
|
||||
BulkEditChange whatHasChanged = new BulkEditChange(item);
|
||||
|
||||
// Has it moved collection?
|
||||
@@ -224,10 +228,19 @@ public class MetadataImport
|
||||
}
|
||||
|
||||
// Record the addition to collections
|
||||
boolean first = true;
|
||||
for (String handle : collections)
|
||||
{
|
||||
Collection extra = (Collection)HandleManager.resolveToObject(c, handle);
|
||||
whatHasChanged.registerNewOwningCollection(extra);
|
||||
if (first)
|
||||
{
|
||||
whatHasChanged.setOwningCollection(extra);
|
||||
}
|
||||
else
|
||||
{
|
||||
whatHasChanged.registerNewMappedCollection(extra);
|
||||
}
|
||||
first = false;
|
||||
}
|
||||
|
||||
// Create the new item?
|
||||
@@ -454,10 +467,11 @@ public class MetadataImport
|
||||
}
|
||||
|
||||
/**
|
||||
* Compare changes between an items owning collections and what is in the CSV file
|
||||
* Compare changes between an items owning collection and mapped collections
|
||||
* and what is in the CSV file
|
||||
*
|
||||
* @param item The item in question
|
||||
* @param collections The collection handles fro mthe CSV file
|
||||
* @param collections The collection handles from the CSV file
|
||||
* @param actualCollections The Collections from the actual item
|
||||
* @param bechange The bulkedit change object for this item
|
||||
* @param change Whether or not to actuate a change
|
||||
@@ -473,90 +487,138 @@ public class MetadataImport
|
||||
BulkEditChange bechange,
|
||||
boolean change) throws SQLException, AuthorizeException, IOException, MetadataImportException
|
||||
{
|
||||
// First, loop through the strings from the CSV
|
||||
// First, check the owning collection (as opposed to mapped collections) is the same of changed
|
||||
String oldOwner = item.getOwningCollection().getHandle();
|
||||
String newOwner = collections.get(0);
|
||||
// Resolve the handle to the collection
|
||||
Collection newCollection = (Collection)HandleManager.resolveToObject(c, newOwner);
|
||||
|
||||
// Check it resolved OK
|
||||
if (newCollection == null)
|
||||
{
|
||||
throw new MetadataImportException("'" + newOwner + "' is not a Collection! You must specify a valid collection ID");
|
||||
}
|
||||
|
||||
if (!oldOwner.equals(newOwner))
|
||||
{
|
||||
// Register the old and new owning collections
|
||||
bechange.changeOwningCollection(item.getOwningCollection(), (Collection)HandleManager.resolveToObject(c, newOwner));
|
||||
}
|
||||
|
||||
// Second, loop through the strings from the CSV of mapped collections
|
||||
boolean first = true;
|
||||
for (String csvcollection : collections)
|
||||
{
|
||||
// Ignore the first collection as this is the owning collection
|
||||
if (!first)
|
||||
{
|
||||
// Look for it in the actual list of Collections
|
||||
boolean found = false;
|
||||
for (Collection collection : actualCollections)
|
||||
{
|
||||
if (collection.getID() != item.getOwningCollection().getID()) {
|
||||
// Is it there?
|
||||
if (csvcollection.equals(collection.getHandle()))
|
||||
{
|
||||
found = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Was it found?
|
||||
if (!found)
|
||||
{
|
||||
// Register than change
|
||||
DSpaceObject dso = HandleManager.resolveToObject(c, csvcollection);
|
||||
if ((dso == null) || (dso.getType() != Constants.COLLECTION))
|
||||
{
|
||||
throw new MetadataImportException("Collection defined for item " + item.getID() +
|
||||
" (" + item.getHandle() + ") is not a collection");
|
||||
}
|
||||
else
|
||||
if (!found)
|
||||
{
|
||||
// Register the new mapped collection
|
||||
Collection col = (Collection)dso;
|
||||
bechange.registerNewOwningCollection(col);
|
||||
|
||||
// Execute the change
|
||||
if (change)
|
||||
{
|
||||
// Add the item to the community
|
||||
col.addItem(item);
|
||||
}
|
||||
bechange.registerNewMappedCollection(col);
|
||||
}
|
||||
}
|
||||
first = false;
|
||||
}
|
||||
|
||||
// Second, loop through the strings from the current item
|
||||
// Third, loop through the strings from the current item
|
||||
for (Collection collection : actualCollections)
|
||||
{
|
||||
// Look for it in the actual list of Collections
|
||||
boolean found = false;
|
||||
first = true;
|
||||
for (String csvcollection : collections)
|
||||
{
|
||||
// Don't check the owning collection
|
||||
if ((first) && (collection.getID() == item.getOwningCollection().getID()))
|
||||
{
|
||||
found = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!first)
|
||||
{
|
||||
// Is it there?
|
||||
if (collection.getHandle().equals(csvcollection))
|
||||
{
|
||||
found = true;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
first = false;
|
||||
}
|
||||
|
||||
// Was it found?
|
||||
if (!found)
|
||||
{
|
||||
// Reocrd that it isn't there any more
|
||||
bechange.registerOldOwningCollection(collection);
|
||||
// Record that it isn't there any more
|
||||
bechange.registerOldMappedCollection(collection);
|
||||
}
|
||||
}
|
||||
|
||||
// Execute the change
|
||||
// Process the changes
|
||||
if (change)
|
||||
{
|
||||
// Sanity check it is in another collection
|
||||
if (item.getCollections().length > 1)
|
||||
// Remove old mapped collections
|
||||
for (Collection c : bechange.getOldMappedCollections())
|
||||
{
|
||||
collection.removeItem(item);
|
||||
c.removeItem(item);
|
||||
}
|
||||
else
|
||||
|
||||
// Add to new owned collection
|
||||
if (bechange.getNewOwningCollection() != null)
|
||||
{
|
||||
throw new MetadataImportException("Not removing item " + item.getHandle() +
|
||||
" from collection " + collection.getHandle() +
|
||||
" as it would leave it oprhaned!");
|
||||
}
|
||||
bechange.getNewOwningCollection().addItem(item);
|
||||
item.setOwningCollection(bechange.getNewOwningCollection());
|
||||
item.update();
|
||||
}
|
||||
|
||||
// Remove from old owned collection (if still a member)
|
||||
if (bechange.getOldOwningCollection() != null)
|
||||
{
|
||||
boolean found = false;
|
||||
for (Collection c : item.getCollections())
|
||||
{
|
||||
if (c.getID() == bechange.getOldOwningCollection().getID())
|
||||
{
|
||||
found = true;
|
||||
}
|
||||
}
|
||||
|
||||
// Now check the owning_collection (item table) is the same as
|
||||
// the first collection given in the CSV file entry
|
||||
if ((change) && (!collections.get(0).equals(item.getOwningCollection().getHandle())))
|
||||
if (found)
|
||||
{
|
||||
Collection owner = (Collection)HandleManager.resolveToObject(c, collections.get(0));
|
||||
item.setOwningCollection(Collection.find(c, owner.getID()));
|
||||
item.update();
|
||||
bechange.getOldOwningCollection().removeItem(item);
|
||||
}
|
||||
}
|
||||
|
||||
// Add to new mapped collections
|
||||
for (Collection c : bechange.getNewMappedCollections())
|
||||
{
|
||||
c.addItem(item);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -695,10 +757,11 @@ public class MetadataImport
|
||||
// Get the changes
|
||||
ArrayList<DCValue> adds = change.getAdds();
|
||||
ArrayList<DCValue> removes = change.getRemoves();
|
||||
ArrayList<Collection> newCollections = change.getNewOwningCollections();
|
||||
ArrayList<Collection> oldCollections = change.getOldOwningCollections();
|
||||
ArrayList<Collection> newCollections = change.getNewMappedCollections();
|
||||
ArrayList<Collection> oldCollections = change.getOldMappedCollections();
|
||||
if ((adds.size() > 0) || (removes.size() > 0) ||
|
||||
(newCollections.size() > 0) || (oldCollections.size() > 0))
|
||||
(newCollections.size() > 0) || (oldCollections.size() > 0) ||
|
||||
(change.getNewOwningCollection() != null) || (change.getOldOwningCollection() != null))
|
||||
{
|
||||
// Show the item
|
||||
Item i = change.getItem();
|
||||
@@ -727,34 +790,69 @@ public class MetadataImport
|
||||
changeCounter++;
|
||||
}
|
||||
|
||||
// Show new collections
|
||||
if (change.getNewOwningCollection() != null)
|
||||
{
|
||||
Collection c = change.getNewOwningCollection();
|
||||
if (c != null)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
if (!changed)
|
||||
{
|
||||
System.out.print(" + New owning collection (" + cHandle + "): ");
|
||||
}
|
||||
else
|
||||
{
|
||||
System.out.print(" + New owning collection (" + cHandle + "): ");
|
||||
}
|
||||
System.out.println(cName);
|
||||
}
|
||||
|
||||
c = change.getOldOwningCollection();
|
||||
if (c != null)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
if (!changed)
|
||||
{
|
||||
System.out.print(" + Old owning collection (" + cHandle + "): ");
|
||||
}
|
||||
else
|
||||
{
|
||||
System.out.print(" + Old owning collection (" + cHandle + "): ");
|
||||
}
|
||||
System.out.println(cName);
|
||||
}
|
||||
}
|
||||
|
||||
// Show new mapped collections
|
||||
for (Collection c : newCollections)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
if (!changed)
|
||||
{
|
||||
System.out.print(" + Add to collection (" + cHandle + "): ");
|
||||
System.out.print(" + Map to collection (" + cHandle + "): ");
|
||||
}
|
||||
else
|
||||
{
|
||||
System.out.print(" + Added to collection (" + cHandle + "): ");
|
||||
System.out.print(" + Mapped to collection (" + cHandle + "): ");
|
||||
}
|
||||
System.out.println(cName);
|
||||
}
|
||||
|
||||
// Show old collections
|
||||
// Show old mapped collections
|
||||
for (Collection c : oldCollections)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
if (!changed)
|
||||
{
|
||||
System.out.print(" + Remove from collection (" + cHandle + "): ");
|
||||
System.out.print(" + Um-map from collection (" + cHandle + "): ");
|
||||
}
|
||||
else
|
||||
{
|
||||
System.out.print(" + Removed from collection (" + cHandle + "): ");
|
||||
System.out.print(" + Un-mapped from collection (" + cHandle + "): ");
|
||||
}
|
||||
System.out.println(cName);
|
||||
}
|
||||
|
@@ -113,7 +113,21 @@ public class ScriptLauncher
|
||||
{
|
||||
// Instantiate the class
|
||||
Class target = null;
|
||||
String className = step.getChild("class").getValue();
|
||||
|
||||
// Is it the special case 'dsrun' where the user provides the class name?
|
||||
String className;
|
||||
if ("dsrun".equals(request))
|
||||
{
|
||||
if (args.length < 2)
|
||||
{
|
||||
System.err.println("Error in launcher.xml: Missing class name");
|
||||
System.exit(1);
|
||||
}
|
||||
className = args[1];
|
||||
}
|
||||
else {
|
||||
className = step.getChild("class").getValue();
|
||||
}
|
||||
try
|
||||
{
|
||||
target = Class.forName(className,
|
||||
@@ -136,16 +150,20 @@ public class ScriptLauncher
|
||||
{
|
||||
passargs = false;
|
||||
}
|
||||
if ((args.length == 1) || (!passargs))
|
||||
if ((args.length == 1) || (("dsrun".equals(request)) && (args.length == 2)) || (!passargs))
|
||||
{
|
||||
useargs = new String[0];
|
||||
}
|
||||
else
|
||||
{
|
||||
String[] argsnew = new String[useargs.length - 1];
|
||||
for (int i = 1; i < useargs.length; i++)
|
||||
// The number of arguments to ignore
|
||||
// If dsrun is the command, ignore the next, as it is the class name not an arg
|
||||
int x = 1;
|
||||
if ("dsrun".equals(request)) x = 2;
|
||||
String[] argsnew = new String[useargs.length - x];
|
||||
for (int i = x; i < useargs.length; i++)
|
||||
{
|
||||
argsnew[i - 1] = useargs[i];
|
||||
argsnew[i - x] = useargs[i];
|
||||
}
|
||||
useargs = argsnew;
|
||||
}
|
||||
|
@@ -89,7 +89,7 @@ public class DailyReportEmailer
|
||||
* Send the report through email.
|
||||
*
|
||||
* @param attachment
|
||||
* the file conntaing the report
|
||||
* the file containing the report
|
||||
* @param numberOfBitstreams
|
||||
* the number of bitstreams reported
|
||||
*
|
||||
@@ -117,7 +117,7 @@ public class DailyReportEmailer
|
||||
// create the first part of the email
|
||||
BodyPart messageBodyPart = new MimeBodyPart();
|
||||
messageBodyPart
|
||||
.setText("This is the checksum checker report see attachement for details \n"
|
||||
.setText("This is the checksum checker report see attachment for details \n"
|
||||
+ numberOfBitstreams
|
||||
+ " Bitstreams found with POSSIBLE issues");
|
||||
multipart.addBodyPart(messageBodyPart);
|
||||
@@ -183,7 +183,7 @@ public class DailyReportEmailer
|
||||
"c",
|
||||
"Changed",
|
||||
false,
|
||||
"Send E-mail report for all bitstrems where checksum has been changed for today");
|
||||
"Send E-mail report for all bitstreams where checksum has been changed for today");
|
||||
options.addOption("a", "All", false, "Send all E-mail reports");
|
||||
|
||||
options.addOption("u", "Unchecked", false,
|
||||
|
@@ -384,7 +384,7 @@ public class DCDate
|
||||
*/
|
||||
public int getYear()
|
||||
{
|
||||
return getLocalCalendar() == null ? -1 : localCalendar.get(Calendar.YEAR);
|
||||
return ((getLocalCalendar() == null) || (!withinGranularity(DateGran.YEAR))) ? -1 : localCalendar.get(Calendar.YEAR);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -394,7 +394,7 @@ public class DCDate
|
||||
*/
|
||||
public int getMonth()
|
||||
{
|
||||
return getLocalCalendar() == null ? -1 : localCalendar.get(Calendar.MONTH) + 1;
|
||||
return ((getLocalCalendar() == null) || (!withinGranularity(DateGran.MONTH))) ? -1 : localCalendar.get(Calendar.MONTH) + 1;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -404,7 +404,7 @@ public class DCDate
|
||||
*/
|
||||
public int getDay()
|
||||
{
|
||||
return getLocalCalendar() == null ? -1 : localCalendar.get(Calendar.DAY_OF_MONTH);
|
||||
return ((getLocalCalendar() == null) || (!withinGranularity(DateGran.DAY))) ? -1 : localCalendar.get(Calendar.DAY_OF_MONTH);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -524,6 +524,52 @@ public class DCDate
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Test if the requested level of granularity is within that of the date.
|
||||
*
|
||||
* @param dg
|
||||
* The requested level of granularity.
|
||||
* @return
|
||||
* true or false.
|
||||
*
|
||||
*/
|
||||
private boolean withinGranularity(DateGran dg)
|
||||
{
|
||||
if (granularity == DateGran.TIME)
|
||||
{
|
||||
if ((dg == DateGran.TIME) || (dg == DateGran.DAY) || (dg == DateGran.MONTH) || (dg == DateGran.YEAR))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
if (granularity == DateGran.DAY)
|
||||
{
|
||||
if ((dg == DateGran.DAY) || (dg == DateGran.MONTH) || (dg == DateGran.YEAR))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
if (granularity == DateGran.MONTH)
|
||||
{
|
||||
if ((dg == DateGran.MONTH) || (dg == DateGran.YEAR))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
if (granularity == DateGran.YEAR)
|
||||
{
|
||||
if (dg == DateGran.YEAR)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Simple test program
|
||||
* Usage: java org.dspace.content.DCdate [DCDate | -l yyyy [mm [dd ..]]] ]
|
||||
|
@@ -262,6 +262,8 @@ public class LCNameAuthority implements ChoiceAuthority
|
||||
private int hits = -1;
|
||||
private String textValue = null;
|
||||
private String name = null;
|
||||
private String oname = null;
|
||||
private String bname = null;
|
||||
private String lccn = null;
|
||||
private String lastTag = null;
|
||||
private String lastCode = null;
|
||||
@@ -332,6 +334,10 @@ public class LCNameAuthority implements ChoiceAuthority
|
||||
// 100.a is the personal name
|
||||
else if (lastTag.equals("100") && lastCode.equals("a"))
|
||||
name = textValue;
|
||||
|
||||
if (lastTag.equals("100") && lastCode.equals("d") && (name != null))
|
||||
name = name+" "+textValue;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -203,7 +203,7 @@ public abstract class AbstractMETSIngester
|
||||
METSManifest manifest = null;
|
||||
wi = WorkspaceItem.create(context, collection, useTemplate);
|
||||
Item item = wi.getItem();
|
||||
Bundle contentBundle = item.createBundle(Constants.CONTENT_BUNDLE_NAME);
|
||||
Bundle contentBundle = null;
|
||||
Bundle mdBundle = null;
|
||||
ZipEntry ze;
|
||||
while ((ze = zip.getNextEntry()) != null)
|
||||
@@ -238,6 +238,11 @@ public abstract class AbstractMETSIngester
|
||||
}
|
||||
else
|
||||
{
|
||||
// we need to create the bundle only the first time
|
||||
if (contentBundle == null)
|
||||
{
|
||||
contentBundle = item.createBundle(Constants.CONTENT_BUNDLE_NAME);
|
||||
}
|
||||
bs = contentBundle.createBitstream(new PackageUtils.UnclosableInputStream(zip));
|
||||
bs.setSource(fname);
|
||||
bs.setName(fname);
|
||||
|
@@ -479,7 +479,7 @@ public class Group extends DSpaceObject
|
||||
// However, we only do this is we are looking up the special groups
|
||||
// of the current user, as we cannot look up the special groups
|
||||
// of a user who is not logged in.
|
||||
if ((c.getCurrentUser() != null) && (c.getCurrentUser().getID() == e.getID()))
|
||||
if ((c.getCurrentUser() == null) || (((c.getCurrentUser() != null) && (c.getCurrentUser().getID() == e.getID()))))
|
||||
{
|
||||
Group[] specialGroups = c.getSpecialGroups();
|
||||
for(Group special : specialGroups)
|
||||
|
@@ -289,7 +289,7 @@ public class Harvest
|
||||
itemInfo.item = Item.find(context, itemInfo.itemID);
|
||||
}
|
||||
|
||||
if ((nonAnon) || (itemInfo.item == null))
|
||||
if ((nonAnon) || (itemInfo.item == null) || (withdrawn && itemInfo.withdrawn))
|
||||
{
|
||||
infoObjects.add(itemInfo);
|
||||
itemCounter++;
|
||||
|
@@ -516,10 +516,14 @@ public class DescribeStep extends AbstractProcessingStep
|
||||
+ "_first");
|
||||
lasts = getRepeatedParameter(request, metadataField, metadataField
|
||||
+ "_last");
|
||||
|
||||
if(isAuthorityControlled)
|
||||
{
|
||||
auths = getRepeatedParameter(request, metadataField, metadataField
|
||||
+ "_authority");
|
||||
confs = getRepeatedParameter(request, metadataField, metadataField
|
||||
+ "_confidence");
|
||||
}
|
||||
|
||||
// Find out if the relevant "remove" button was pressed
|
||||
// TODO: These separate remove buttons are only relevant
|
||||
@@ -535,10 +539,13 @@ public class DescribeStep extends AbstractProcessingStep
|
||||
|
||||
firsts.remove(valToRemove);
|
||||
lasts.remove(valToRemove);
|
||||
if(isAuthorityControlled)
|
||||
{
|
||||
auths.remove(valToRemove);
|
||||
confs.remove(valToRemove);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Just a single name
|
||||
@@ -684,6 +691,11 @@ public class DescribeStep extends AbstractProcessingStep
|
||||
.substring(removeButton.length()));
|
||||
|
||||
vals.remove(valToRemove);
|
||||
if(isAuthorityControlled)
|
||||
{
|
||||
auths.remove(valToRemove);
|
||||
confs.remove(valToRemove);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
|
@@ -291,10 +291,14 @@ jsp.dspace-admin.metadataimport.apply = Apply changes
|
||||
jsp.dspace-admin.metadataimport.unknownerror = An unknown error has occured
|
||||
jsp.dspace-admin.metadataimport.changesforitem = Changes for item
|
||||
jsp.dspace-admin.metadataimport.newitem = New item
|
||||
jsp.dspace-admin.metadataimport.addtocollection = Add to collection
|
||||
jsp.dspace-admin.metadataimport.addedtocollection = Added to collection
|
||||
jsp.dspace-admin.metadataimport.removefromcollection = Remove from collection
|
||||
jsp.dspace-admin.metadataimport.removedfromcollection = Removed from collection
|
||||
jsp.dspace-admin.metadataimport.addtocollection = Map to collection
|
||||
jsp.dspace-admin.metadataimport.addedtocollection = Mapped to collection
|
||||
jsp.dspace-admin.metadataimport.removefromcollection = Un-map from collection
|
||||
jsp.dspace-admin.metadataimport.removedfromcollection = Un-mapped from collection
|
||||
jsp.dspace-admin.metadataimport.addtoownercollection = Add to new owning collection
|
||||
jsp.dspace-admin.metadataimport.addedtoownercollection = Added to new owning collection
|
||||
jsp.dspace-admin.metadataimport.removefromownercollection = Remove from owning collection
|
||||
jsp.dspace-admin.metadataimport.removedfromownercollection = Removed from owning collection
|
||||
jsp.dspace-admin.metadataimport.add = Add
|
||||
jsp.dspace-admin.metadataimport.added = Added
|
||||
jsp.dspace-admin.metadataimport.remove = Remove
|
||||
@@ -1073,6 +1077,21 @@ jsp.tools.edit-collection.form.label11 = Step:
|
||||
jsp.tools.edit-collection.form.label12 = Collection Administrators:
|
||||
jsp.tools.edit-collection.form.label13 = Item template:
|
||||
jsp.tools.edit-collection.form.label14 = Collection's Authorizations:
|
||||
jsp.tools.edit-collection.form.label15 = Harvesting Settings
|
||||
jsp.tools.edit-collection.form.label16 = Content Source
|
||||
jsp.tools.edit-collection.form.label17 = This is a standard DSpace collection
|
||||
jsp.tools.edit-collection.form.label18 = This collection harvests its content from an external source
|
||||
jsp.tools.edit-collection.form.label19 = OAI Provider
|
||||
jsp.tools.edit-collection.form.label20 = OAI Set Id
|
||||
jsp.tools.edit-collection.form.label21 = Metadata Format
|
||||
jsp.tools.edit-collection.form.label21.select.qdc = Qualified Dublin Core
|
||||
jsp.tools.edit-collection.form.label21.select.dc = Dublin Core
|
||||
jsp.tools.edit-collection.form.label21.select.dim = DSpace Intermediate Format
|
||||
jsp.tools.edit-collection.form.label22 = Content being Harvested
|
||||
jsp.tools.edit-collection.form.label23 = Harvest metadata only.
|
||||
jsp.tools.edit-collection.form.label24 = Harvest metadata and references to bitstreams (requires ORE support).
|
||||
jsp.tools.edit-collection.form.label25 = Harvest metadata and bitstreams (requires ORE support).
|
||||
jsp.tools.edit-collection.form.label26 = Last Harvest Result
|
||||
jsp.tools.edit-collection.form.label2 = Short Description
|
||||
jsp.tools.edit-collection.form.label3 = Introductory text (HTML):
|
||||
jsp.tools.edit-collection.form.label4 = Copyright text (plain text):
|
||||
@@ -1216,6 +1235,7 @@ jsp.tools.itemmap-info.button.continue = Continue
|
||||
jsp.tools.itemmap-info.heading = Item Map Info
|
||||
jsp.tools.itemmap-info.msg.added = Add item {0}
|
||||
jsp.tools.itemmap-info.msg.none-selected = No items selected, none added.
|
||||
jsp.tools.itemmap-info.msg.none-removed = No items selected, none removed.
|
||||
# In the following 2 messages the only parameter is an item ID
|
||||
jsp.tools.itemmap-info.msg.remove = Remove item {0}
|
||||
jsp.tools.itemmap-info.title = Item Map Info
|
||||
@@ -1234,6 +1254,7 @@ jsp.tools.move-item.collection.from.msg = Collection to
|
||||
jsp.tools.move-item.collection.to.msg = Collection to move to
|
||||
jsp.tools.move-item.item.name.msg = Name of the item to be moved
|
||||
jsp.tools.move-item.title = Moving an item
|
||||
jsp.tools.move-item.inheritpolicies = Inherit default policies of destination collection
|
||||
jsp.tools.upload-bitstream.info = Select the bitstream to upload
|
||||
jsp.tools.upload-bitstream.title = Upload Bitstream
|
||||
jsp.tools.upload-bitstream.upload = Upload
|
||||
@@ -1393,6 +1414,8 @@ org.dspace.eperson.Subscribe.authors
|
||||
org.dspace.eperson.Subscribe.id = ID:
|
||||
org.dspace.eperson.Subscribe.new-items = New Items:
|
||||
org.dspace.eperson.Subscribe.title = Title:
|
||||
org.dspace.statistics.util.LocationUtils.unknown-continent = Unknown Continent
|
||||
org.dspace.statistics.util.LocationUtils.unknown-country = Unknown Country
|
||||
org.dspace.workflow.WorkflowManager.step1 = It requires reviewing.
|
||||
org.dspace.workflow.WorkflowManager.step2 = The submission must be checked before inclusion in the archive.
|
||||
org.dspace.workflow.WorkflowManager.step3 = The metadata needs to be checked to ensure compliance with the collection's standards, and edited if necessary.
|
||||
|
@@ -14,7 +14,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-jspui</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -40,9 +40,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-jspui/dspace-jspui-api</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-jspui/dspace-jspui-api</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-jspui/dspace-jspui-api</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-jspui/dspace-jspui-api</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-jspui/dspace-jspui-api</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-jspui/dspace-jspui-api</url>
|
||||
</scm>
|
||||
|
||||
<dependencies>
|
||||
|
@@ -731,7 +731,19 @@ public class ItemTag extends TagSupport
|
||||
{
|
||||
Bundle[] bundles = item.getBundles("ORIGINAL");
|
||||
|
||||
if (bundles.length == 0)
|
||||
boolean filesExist = false;
|
||||
|
||||
for (Bundle bnd : bundles)
|
||||
{
|
||||
filesExist = bnd.getBitstreams().length > 0;
|
||||
if (filesExist)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// if user already has uploaded at least one file
|
||||
if (!filesExist)
|
||||
{
|
||||
out.println("<p>"
|
||||
+ LocaleSupport.getLocalizedMessage(pageContext,
|
||||
|
@@ -81,8 +81,8 @@ public class AuthorityChooseServlet extends DSpaceServlet {
|
||||
// };
|
||||
//
|
||||
// Choices result = new Choices(testValues,start,testValues.length,Choices.CF_ACCEPTED,false);
|
||||
Writer writer = response.getWriter();
|
||||
response.setContentType("text/xml; charset=\"utf-8\"");
|
||||
Writer writer = response.getWriter();
|
||||
// borrow xalan's serializer to let us use SAX choice menu generator
|
||||
Properties props =
|
||||
OutputPropertiesFactory.getDefaultMethodProperties(Method.XML);
|
||||
|
@@ -198,72 +198,6 @@ public class ItemMapServlet extends DSpaceServlet
|
||||
// show the page
|
||||
JSPManager.showJSP(request, response, jspPage);
|
||||
}
|
||||
/*
|
||||
* else if( action.equals("add") ) { int itemID =
|
||||
* UIUtil.getIntParameter(request, "item_id"); String handle =
|
||||
* (String)request.getParameter("handle"); boolean error = true; Item
|
||||
* itemToAdd = null;
|
||||
*
|
||||
* if( itemID > 0 ) { itemToAdd = Item.find(context, itemID);
|
||||
*
|
||||
* if( itemToAdd != null ) error = false; } else if(handle != null &&
|
||||
* !handle.equals("")) { DSpaceObject
|
||||
* dso=HandleManager.resolveToObject(context, handle);
|
||||
*
|
||||
* if(dso != null && dso.getType() == Constants.ITEM) { itemToAdd =
|
||||
* (Item)dso; error = false; } }
|
||||
*
|
||||
* //FIXME: error handling! if( !error ) { String myTitle =
|
||||
* itemToAdd.getDC("title",null,Item.ANY)[0].value; String ownerName =
|
||||
* itemToAdd.getOwningCollection().getMetadata("name");
|
||||
* // hook up item, but first, does it belong already? TableRowIterator
|
||||
* tri = DatabaseManager.query(context, "collection2item", "SELECT
|
||||
* collection2item.* FROM collection2item WHERE " + "collection_id=" +
|
||||
* myCollection.getID() + " AND item_id=" + itemToAdd.getID());
|
||||
*
|
||||
* if(tri.hasNext()) { request.setAttribute("message", "Item is already
|
||||
* part of that collection!"); } else { // Create mapping
|
||||
* myCollection.addItem( itemToAdd );
|
||||
* // set up a nice 'done' message request.setAttribute("message",
|
||||
* "Item added successfully: <br> " + myTitle + " <br> From Collection:
|
||||
* <br> " + ownerName);
|
||||
* }
|
||||
*
|
||||
* request.setAttribute("collection", myCollection);
|
||||
* // show this page when we're done jspPage = "itemmap-info.jsp";
|
||||
* // show the page JSPManager.showJSP(request, response, jspPage); }
|
||||
* else { // Display an error } } else if( action.equals("Add Entire
|
||||
* Collection") ) { int targetID = UIUtil.getIntParameter(request,
|
||||
* "collection2import");
|
||||
*
|
||||
* Collection targetCollection = Collection.find(context, targetID);
|
||||
* // get all items from that collection and add them if not // already
|
||||
* added
|
||||
* // get all items to be added ItemIterator i =
|
||||
* targetCollection.getItems(); Map toAdd = new HashMap(); String
|
||||
* message = "";
|
||||
*
|
||||
* while( i.hasNext() ) { Item myItem = i.next();
|
||||
*
|
||||
* toAdd.put(new Integer(myItem.getID()), myItem); }
|
||||
* // now see what we already have, removing dups from the 'toAdd' list
|
||||
* i = myCollection.getItems();
|
||||
*
|
||||
* while( i.hasNext() ) { Item myItem = i.next(); Integer myKey = new
|
||||
* Integer(myItem.getID());
|
||||
* // remove works even if key isn't present toAdd.remove(myKey); }
|
||||
* // what's left in toAdd should be added Iterator addKeys =
|
||||
* toAdd.keySet().iterator();
|
||||
*
|
||||
* while( addKeys.hasNext() ) { Item myItem =
|
||||
* (Item)toAdd.get(addKeys.next()); myCollection.addItem(myItem);
|
||||
* message += " <br> Added item ID: " + myItem.getID(); }
|
||||
*
|
||||
* request.setAttribute("message", message);
|
||||
* request.setAttribute("collection", myCollection);
|
||||
* // show this page when we're done jspPage = "itemmap-info.jsp";
|
||||
* // show the page JSPManager.showJSP(request, response, jspPage); }
|
||||
*/
|
||||
else if (action.equals("Remove"))
|
||||
{
|
||||
// get item IDs to remove
|
||||
@@ -271,6 +205,12 @@ public class ItemMapServlet extends DSpaceServlet
|
||||
String message = "remove";
|
||||
LinkedList removedItems = new LinkedList();
|
||||
|
||||
if (itemIDs == null)
|
||||
{
|
||||
message = "none-removed";
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int j = 0; j < itemIDs.length; j++)
|
||||
{
|
||||
int i = Integer.parseInt(itemIDs[j]);
|
||||
@@ -294,6 +234,7 @@ public class ItemMapServlet extends DSpaceServlet
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
request.setAttribute("message", message);
|
||||
request.setAttribute("collection", myCollection);
|
||||
|
@@ -39,11 +39,7 @@
|
||||
*/
|
||||
package org.dspace.app.webui.submit.step;
|
||||
|
||||
import java.io.BufferedInputStream;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.sql.SQLException;
|
||||
|
||||
import javax.servlet.ServletException;
|
||||
@@ -51,15 +47,12 @@ import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.apache.log4j.Logger;
|
||||
|
||||
import org.dspace.app.util.DCInputsReader;
|
||||
import org.dspace.app.util.DCInputsReaderException;
|
||||
import org.dspace.app.util.Util;
|
||||
import org.dspace.app.util.SubmissionInfo;
|
||||
import org.dspace.app.webui.submit.JSPStep;
|
||||
import org.dspace.app.webui.submit.JSPStepManager;
|
||||
import org.dspace.app.webui.util.FileUploadRequest;
|
||||
import org.dspace.app.webui.util.JSPManager;
|
||||
import org.dspace.app.util.SubmissionInfo;
|
||||
import org.dspace.app.webui.util.UIUtil;
|
||||
import org.dspace.authorize.AuthorizeException;
|
||||
import org.dspace.content.Bitstream;
|
||||
@@ -67,7 +60,6 @@ import org.dspace.content.BitstreamFormat;
|
||||
import org.dspace.content.Bundle;
|
||||
import org.dspace.content.Collection;
|
||||
import org.dspace.content.FormatIdentifier;
|
||||
import org.dspace.content.Item;
|
||||
import org.dspace.core.ConfigurationManager;
|
||||
import org.dspace.core.Context;
|
||||
import org.dspace.core.LogManager;
|
||||
@@ -217,8 +209,19 @@ public class JSPUploadStep extends JSPStep
|
||||
Bundle[] bundles = subInfo.getSubmissionItem().getItem()
|
||||
.getBundles("ORIGINAL");
|
||||
|
||||
boolean fileAlreadyUploaded = false;
|
||||
|
||||
for (Bundle bnd : bundles)
|
||||
{
|
||||
fileAlreadyUploaded = bnd.getBitstreams().length > 0;
|
||||
if (fileAlreadyUploaded)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// if user already has uploaded at least one file
|
||||
if (bundles.length > 0)
|
||||
if (fileAlreadyUploaded)
|
||||
{
|
||||
// return to list of uploaded files
|
||||
showUploadFileList(context, request, response, subInfo, true,
|
||||
@@ -409,7 +412,22 @@ public class JSPUploadStep extends JSPStep
|
||||
Bundle[] bundles = subInfo.getSubmissionItem().getItem().getBundles(
|
||||
"ORIGINAL");
|
||||
|
||||
if (justUploaded || bundles.length > 0)
|
||||
boolean fileAlreadyUploaded = false;
|
||||
|
||||
if (!justUploaded)
|
||||
{
|
||||
for (Bundle bnd : bundles)
|
||||
{
|
||||
fileAlreadyUploaded = bnd.getBitstreams().length > 0;
|
||||
if (fileAlreadyUploaded)
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// if user already has uploaded at least one file
|
||||
if (justUploaded || fileAlreadyUploaded)
|
||||
{
|
||||
// The item already has files associated with it.
|
||||
showUploadFileList(context, request, response, subInfo,
|
||||
|
@@ -14,7 +14,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-jspui</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -40,9 +40,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-jspui/dspace-jspui-webapp</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-jspui/dspace-jspui-webapp</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-jspui/dspace-jspui-webapp</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-jspui/dspace-jspui-webapp</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-jspui/dspace-jspui-webapp</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-jspui/dspace-jspui-webapp</url>
|
||||
</scm>
|
||||
|
||||
<build>
|
||||
|
@@ -99,11 +99,12 @@
|
||||
// Get the changes
|
||||
ArrayList<DCValue> adds = change.getAdds();
|
||||
ArrayList<DCValue> removes = change.getRemoves();
|
||||
ArrayList<Collection> newCollections = change.getNewOwningCollections();
|
||||
ArrayList<Collection> oldCollections = change.getOldOwningCollections();
|
||||
ArrayList<Collection> newCollections = change.getNewMappedCollections();
|
||||
ArrayList<Collection> oldCollections = change.getOldMappedCollections();
|
||||
boolean first = false;
|
||||
if ((adds.size() > 0) || (removes.size() > 0) ||
|
||||
(newCollections.size() > 0) || (oldCollections.size() > 0))
|
||||
(newCollections.size() > 0) || (oldCollections.size() > 0) ||
|
||||
(change.getNewOwningCollection() != null) || (change.getOldOwningCollection() != null))
|
||||
{
|
||||
// Show the item
|
||||
if (!change.isNewItem())
|
||||
@@ -119,6 +120,60 @@
|
||||
first = true;
|
||||
}
|
||||
|
||||
// Show new owner collection
|
||||
if (change.getNewOwningCollection() != null)
|
||||
{
|
||||
Collection c = change.getNewOwningCollection();
|
||||
if (c != null)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
if (!first)
|
||||
{
|
||||
%><tr><td bgcolor="white"></td><%
|
||||
}
|
||||
else
|
||||
{
|
||||
first = false;
|
||||
}
|
||||
if (!changed)
|
||||
{
|
||||
%><td bgcolor="#4E9258" style="font-size:10pt"><fmt:message key="jsp.dspace-admin.metadataimport.addtoownercollection"/></td><td bgcolor="4E9258" style="font-size:10pt">(<%= cHandle %>): <%= cName %></td></tr><%
|
||||
}
|
||||
else
|
||||
{
|
||||
%><td bgcolor="#4E9258" style="font-size:10pt"><fmt:message key="jsp.dspace-admin.metadataimport.addedtoownercollection"/></td><td bgcolor="4E9258" style="font-size:10pt">(<%= cHandle %>): <%= cName %></td></tr><%
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Show old owner collection
|
||||
if (change.getOldOwningCollection() != null)
|
||||
{
|
||||
Collection c = change.getOldOwningCollection();
|
||||
if (c != null)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
if (!first)
|
||||
{
|
||||
%><tr><td bgcolor="white"></td><%
|
||||
}
|
||||
else
|
||||
{
|
||||
first = false;
|
||||
}
|
||||
if (!changed)
|
||||
{
|
||||
%><td bgcolor="#4E9258" style="font-size:10pt"><fmt:message key="jsp.dspace-admin.metadataimport.removefromownercollection"/></td><td bgcolor="4E9258" style="font-size:10pt">(<%= cHandle %>): <%= cName %></td></tr><%
|
||||
}
|
||||
else
|
||||
{
|
||||
%><td bgcolor="#4E9258" style="font-size:10pt"><fmt:message key="jsp.dspace-admin.metadataimport.removedfromownercollection"/></td><td bgcolor="4E9258" style="font-size:10pt">(<%= cHandle %>): <%= cName %></td></tr><%
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Show new collections
|
||||
for (Collection c : newCollections)
|
||||
{
|
||||
|
@@ -396,7 +396,7 @@
|
||||
=========================================================== --%>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
<tr><td colspan="2"><center><h3>Harvesting Settings</h3></center></td></tr>
|
||||
<tr><td colspan="2"><center><h3><fmt:message key="jsp.tools.edit-collection.form.label15"/></h3></center></td></tr>
|
||||
|
||||
<%--
|
||||
oaiProviderValue = hc.getOaiSource();
|
||||
@@ -411,22 +411,22 @@
|
||||
--%>
|
||||
|
||||
<tr>
|
||||
<td class="submitFormLabel">Content Source</td>
|
||||
<td class="submitFormLabel"><fmt:message key="jsp.tools.edit-collection.form.label16"/></td>
|
||||
<td>
|
||||
<input type="radio" value="source_normal" <% if (harvestLevelValue == 0) { %> checked="checked" <% } %> name="source">This is a standard DSpace collection</input><br/>
|
||||
<input type="radio" value="source_harvested" <% if (harvestLevelValue > 0) { %> checked="checked" <% } %> name="source">This collection harvests its content from an external source</input><br/>
|
||||
<input type="radio" value="source_normal" <% if (harvestLevelValue == 0) { %> checked="checked" <% } %> name="source"><fmt:message key="jsp.tools.edit-collection.form.label17"/></input><br/>
|
||||
<input type="radio" value="source_harvested" <% if (harvestLevelValue > 0) { %> checked="checked" <% } %> name="source"><fmt:message key="jsp.tools.edit-collection.form.label18"/></input><br/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="submitFormLabel">OAI Provider</td>
|
||||
<td class="submitFormLabel"><fmt:message key="jsp.tools.edit-collection.form.label19"/></td>
|
||||
<td><input type="text" name="oai_provider" value="<%= oaiProviderValue %>" size="50" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="submitFormLabel">OAI Set Id</td>
|
||||
<td class="submitFormLabel"><fmt:message key="jsp.tools.edit-collection.form.label20"/></td>
|
||||
<td><input type="text" name="oai_setid" value="<%= oaiSetIdValue %>" size="50" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="submitFormLabel">Metadata Format</td>
|
||||
<td class="submitFormLabel"><fmt:message key="jsp.tools.edit-collection.form.label21"/></td>
|
||||
<td>
|
||||
<select name="metadata_format" >
|
||||
<%
|
||||
@@ -436,21 +436,19 @@
|
||||
while (pe.hasMoreElements())
|
||||
{
|
||||
String key = (String)pe.nextElement();
|
||||
|
||||
|
||||
if (key.startsWith(metaString)) {
|
||||
String metadataString = ConfigurationManager.getProperty(key);
|
||||
String metadataKey = key.substring(metaString.length());
|
||||
String displayName;
|
||||
|
||||
if (metadataString.indexOf(',') != -1)
|
||||
displayName = metadataString.substring(metadataString.indexOf(',') + 1);
|
||||
else
|
||||
displayName = metadataKey + "(" + metadataString + ")";
|
||||
String label = "jsp.tools.edit-collection.form.label21.select." + metadataKey;
|
||||
|
||||
%>
|
||||
<option value="<%= metadataKey %>"
|
||||
<% if(metadataKey.equalsIgnoreCase(metadataFormatValue)) { %>
|
||||
selected="selected" <% } %> >
|
||||
<%= displayName %></option>
|
||||
<fmt:message key="<%=label%>"/>
|
||||
</option>
|
||||
<%
|
||||
}
|
||||
}
|
||||
@@ -459,15 +457,15 @@
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="submitFormLabel">Content being Harvested</td>
|
||||
<td class="submitFormLabel"><fmt:message key="jsp.tools.edit-collection.form.label22"/></td>
|
||||
<td>
|
||||
<input type="radio" value="1" <% if (harvestLevelValue != 2 && harvestLevelValue != 3) { %> checked="checked" <% } %> name="harvest_level">Harvest metadata only.</input><br/>
|
||||
<input type="radio" value="2" <% if (harvestLevelValue == 2) { %> checked="checked" <% } %> name="harvest_level">Harvest metadata and references to bitstreams (requires ORE support).</input><br/>
|
||||
<input type="radio" value="3" <% if (harvestLevelValue == 3) { %> checked="checked" <% } %> name="harvest_level">Harvest metadata and bitstreams (requires ORE support).</input><br/>
|
||||
<input type="radio" value="1" <% if (harvestLevelValue != 2 && harvestLevelValue != 3) { %> checked="checked" <% } %> name="harvest_level"><fmt:message key="jsp.tools.edit-collection.form.label23"/></input><br/>
|
||||
<input type="radio" value="2" <% if (harvestLevelValue == 2) { %> checked="checked" <% } %> name="harvest_level"><fmt:message key="jsp.tools.edit-collection.form.label24"/></input><br/>
|
||||
<input type="radio" value="3" <% if (harvestLevelValue == 3) { %> checked="checked" <% } %> name="harvest_level"><fmt:message key="jsp.tools.edit-collection.form.label25"/></input><br/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="submitFormLabel">Last Harvest Result</td>
|
||||
<td class="submitFormLabel"><fmt:message key="jsp.tools.edit-collection.form.label26"/></td>
|
||||
<td><%= lastHarvestMsg %></td>
|
||||
</tr>
|
||||
<!--
|
||||
|
@@ -63,7 +63,7 @@
|
||||
<%
|
||||
Collection collection = (Collection)request.getAttribute("collection");
|
||||
|
||||
// supported values: "none-selected", "added", "remove"
|
||||
// supported values: "none-selected", "none-removed", "added", "remove"
|
||||
String message = (String)request.getAttribute("message");
|
||||
|
||||
LinkedList processedItems = (LinkedList)request.getAttribute("processedItems");
|
||||
@@ -76,6 +76,8 @@
|
||||
<p>
|
||||
<% if (message.equals("none-selected")) { %>
|
||||
<fmt:message key="jsp.tools.itemmap-info.msg.none-selected" />
|
||||
<% } else if (message.equals("none-removed")) { %>
|
||||
<fmt:message key="jsp.tools.itemmap-info.msg.none-removed" />
|
||||
<% } else if (message.equals("added")) { %>
|
||||
<%-- Iterate through processed items --%>
|
||||
<% for (int i=0; i<processedItems.size(); i++) { %>
|
||||
|
@@ -14,7 +14,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -40,9 +40,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-jspui</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-jspui</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-jspui</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-jspui</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-jspui</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-jspui</url>
|
||||
</scm>
|
||||
|
||||
<modules>
|
||||
|
@@ -12,7 +12,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-lni</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -33,9 +33,9 @@
|
||||
</repositories>
|
||||
|
||||
<scm>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni/dspace-lni-client</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni/dspace-lni-client</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni/dspace-lni-client</url>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-lni/dspace-lni-client</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-lni/dspace-lni-client</url>
|
||||
</scm>
|
||||
|
||||
<profiles>
|
||||
|
@@ -10,7 +10,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-lni</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -31,9 +31,9 @@
|
||||
</repositories>
|
||||
|
||||
<scm>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni/dspace-lni-core</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni/dspace-lni-core</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni/dspace-lni-core</url>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-lni/dspace-lni-core</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-lni/dspace-lni-core</url>
|
||||
</scm>
|
||||
|
||||
<dependencies>
|
||||
|
@@ -12,7 +12,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-lni</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -33,9 +33,9 @@
|
||||
</repositories>
|
||||
|
||||
<scm>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni/dspace-lni-webapp</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni/dspace-lni-webapp</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni/dspace-lni-webapp</url>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-lni/dspace-lni-webapp</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-lni/dspace-lni-webapp</url>
|
||||
</scm>
|
||||
|
||||
<build>
|
||||
|
@@ -12,7 +12,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -38,9 +38,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-lni</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-lni</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-lni</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-lni</url>
|
||||
</scm>
|
||||
|
||||
<modules>
|
||||
|
@@ -14,7 +14,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-oai</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -40,9 +40,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-oai/dspace-oai-api</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-oai/dspace-oai-api</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-oai/dspace-oai-api</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-oai/dspace-oai-api</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-oai/dspace-oai-api</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-oai/dspace-oai-api</url>
|
||||
</scm>
|
||||
|
||||
<dependencies>
|
||||
|
@@ -45,8 +45,6 @@ import org.apache.commons.codec.binary.Base64;
|
||||
import org.dspace.app.didl.UUIDFactory;
|
||||
import org.dspace.content.Bitstream;
|
||||
import org.dspace.content.Bundle;
|
||||
import org.dspace.content.DCDate;
|
||||
import org.dspace.content.DCValue;
|
||||
import org.dspace.content.Item;
|
||||
import org.dspace.core.ConfigurationManager;
|
||||
import org.dspace.core.Context;
|
||||
@@ -72,9 +70,16 @@ public class DIDLCrosswalk extends Crosswalk
|
||||
/** default value if no oai.didl.maxresponse property is defined */
|
||||
public static int MAXRESPONSE_INLINE_BITSTREAM = 0;
|
||||
|
||||
/** another crosswalk that will be used to generate the metadata section */
|
||||
private Crosswalk metadataCrosswalk;
|
||||
|
||||
public DIDLCrosswalk(Properties properties)
|
||||
{
|
||||
super("urn:mpeg:mpeg21:2002:02-DIDL-NS http://standards.iso.org/ittf/PubliclyAvailableStandards/MPEG-21_schema_files/did/didl.xsd ");
|
||||
|
||||
// FIXME this should be injected from the configuration...
|
||||
// but it is better than duplicate the OAIDCCrosswalk code!
|
||||
metadataCrosswalk = new OAIDCCrosswalk(properties);
|
||||
}
|
||||
|
||||
|
||||
@@ -90,14 +95,7 @@ public class DIDLCrosswalk extends Crosswalk
|
||||
{
|
||||
Item item = ((HarvestedItemInfo) nativeItem).item;
|
||||
|
||||
Date d = ((HarvestedItemInfo) nativeItem).datestamp;
|
||||
String ITEMDATE = new DCDate(d).toString();
|
||||
|
||||
// Get all the DC
|
||||
DCValue[] allDC = item.getDC(Item.ANY, Item.ANY, Item.ANY);
|
||||
|
||||
StringBuffer metadata = new StringBuffer();
|
||||
StringBuffer metadata1 = new StringBuffer();
|
||||
String itemhandle=item.getHandle();
|
||||
String strMaxSize = ConfigurationManager.getProperty("oai.didl.maxresponse");
|
||||
int maxsize = MAXRESPONSE_INLINE_BITSTREAM;
|
||||
@@ -128,57 +126,10 @@ public class DIDLCrosswalk extends Crosswalk
|
||||
metadata.append("<didl:Descriptor>")
|
||||
.append("<didl:Statement mimeType=\"application/xml; charset=utf-8\">");
|
||||
|
||||
for (int i = 0; i < allDC.length; i++)
|
||||
{
|
||||
// Do not include description.provenance
|
||||
boolean description = allDC[i].element.equals("description");
|
||||
boolean provenance = allDC[i].qualifier != null &&
|
||||
allDC[i].qualifier.equals("provenance");
|
||||
// delegate the metadata section to another crosswalk
|
||||
metadata.append(metadataCrosswalk.createMetadata(nativeItem));
|
||||
|
||||
if (!(description && provenance))
|
||||
{
|
||||
// Escape XML chars <, > and &
|
||||
String value = allDC[i].value;
|
||||
|
||||
// First do &'s - need to be careful not to replace the
|
||||
// & in "&" again!
|
||||
int c = -1;
|
||||
while ((c = value.indexOf("&", c + 1)) > -1)
|
||||
{
|
||||
value = value.substring(0, c) +
|
||||
"&" +
|
||||
value.substring(c + 1);
|
||||
}
|
||||
|
||||
while ((c = value.indexOf("<")) > -1)
|
||||
{
|
||||
value = value.substring(0, c) +
|
||||
"<" +
|
||||
value.substring(c + 1);
|
||||
}
|
||||
|
||||
while ((c = value.indexOf(">")) > -1)
|
||||
{
|
||||
value = value.substring(0, c) +
|
||||
">" +
|
||||
value.substring(c + 1);
|
||||
}
|
||||
|
||||
metadata1.append("<dc:")
|
||||
.append(allDC[i].element)
|
||||
.append(">")
|
||||
.append(value)
|
||||
.append("</dc:")
|
||||
.append(allDC[i].element)
|
||||
.append(">");
|
||||
}
|
||||
}
|
||||
|
||||
metadata.append("<oai_dc:dc xmlns:oai_dc=\"http://www.openarchives.org/OAI/2.0/oai_dc/\" xmlns:dc=\"http://purl.org/dc/elements/1.1/\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:schemaLocation=\"http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd\">");
|
||||
|
||||
metadata.append(metadata1);
|
||||
|
||||
metadata.append("</oai_dc:dc>")
|
||||
metadata
|
||||
.append("</didl:Statement>")
|
||||
.append("</didl:Descriptor>");
|
||||
|
||||
@@ -191,11 +142,7 @@ public class DIDLCrosswalk extends Crosswalk
|
||||
{
|
||||
Bundle[] bundles= item.getBundles("ORIGINAL");
|
||||
|
||||
if (bundles.length == 0)
|
||||
{
|
||||
metadata.append("<P>There are no files associated with this item.</P>");
|
||||
}
|
||||
else
|
||||
if (bundles.length != 0)
|
||||
{
|
||||
/**cycle bundles**/
|
||||
for (int i = 0; i < bundles.length; i++)
|
||||
|
@@ -52,16 +52,19 @@ import java.util.StringTokenizer;
|
||||
import java.util.Vector;
|
||||
|
||||
import org.apache.log4j.Logger;
|
||||
import org.dspace.authorize.AuthorizeManager;
|
||||
import org.dspace.content.Collection;
|
||||
import org.dspace.content.Community;
|
||||
import org.dspace.content.DSpaceObject;
|
||||
import org.dspace.core.ConfigurationManager;
|
||||
import org.dspace.core.Constants;
|
||||
import org.dspace.core.Context;
|
||||
import org.dspace.core.LogManager;
|
||||
import org.dspace.core.Utils;
|
||||
import org.dspace.handle.HandleManager;
|
||||
import org.dspace.search.Harvest;
|
||||
import org.dspace.search.HarvestedItemInfo;
|
||||
import org.dspace.eperson.Group;
|
||||
|
||||
import ORG.oclc.oai.server.catalog.AbstractCatalog;
|
||||
import ORG.oclc.oai.server.verb.BadArgumentException;
|
||||
@@ -370,6 +373,28 @@ public class DSpaceOAICatalog extends AbstractCatalog
|
||||
throw new IdDoesNotExistException(identifier);
|
||||
}
|
||||
|
||||
boolean includeAll = ConfigurationManager.getBooleanProperty("harvest.includerestricted.oai", true);
|
||||
|
||||
if (!includeAll)
|
||||
{
|
||||
Group[] authorizedGroups = AuthorizeManager.getAuthorizedGroups(context, itemInfo.item, Constants.READ);
|
||||
boolean authorized = false;
|
||||
for (int i = 0; i < authorizedGroups.length; i++)
|
||||
{
|
||||
if ((authorizedGroups[i].getID() == 0) && (!authorized))
|
||||
{
|
||||
authorized = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (!authorized)
|
||||
{
|
||||
log.info(LogManager.getHeader(null, "oai_error",
|
||||
"id_not_accessible"));
|
||||
throw new IdDoesNotExistException(identifier);
|
||||
}
|
||||
}
|
||||
|
||||
String schemaURL;
|
||||
|
||||
if ((schemaURL = getCrosswalks().getSchemaURL(metadataPrefix)) == null)
|
||||
|
@@ -14,7 +14,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-oai</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -40,9 +40,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-oai/dspace-oai-webapp</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-oai/dspace-oai-webapp</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-oai/dspace-oai-webapp</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-oai/dspace-oai-webapp</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-oai/dspace-oai-webapp</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-oai/dspace-oai-webapp</url>
|
||||
</scm>
|
||||
|
||||
<build>
|
||||
|
@@ -14,7 +14,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -40,9 +40,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-oai</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-oai</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-oai</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-oai</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-oai</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-oai</url>
|
||||
</scm>
|
||||
|
||||
<modules>
|
||||
|
@@ -3,14 +3,14 @@
|
||||
<parent>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<groupId>org.dspace</groupId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-stats</artifactId>
|
||||
<name>DSpace Solr Statistics Logging Client Library</name>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
<description>Library of Shared UsageEvent and EventConsumer Tools for Logging to Solr.</description>
|
||||
|
||||
<repositories>
|
||||
@@ -36,9 +36,9 @@
|
||||
releases snapshots into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-stats</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-stats</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-stats</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-stats</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-stats</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-stats</url>
|
||||
</scm>
|
||||
|
||||
<distributionManagement>
|
||||
@@ -115,7 +115,7 @@
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-api</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.dspace.dependencies</groupId>
|
||||
|
@@ -168,7 +168,10 @@ public class Dataset {
|
||||
|
||||
public String[][] getMatrixFormatted(){
|
||||
DecimalFormat decimalFormat = new DecimalFormat(format);
|
||||
String [][]strMatrix = new String[matrix.length][matrix[0].length];
|
||||
if (matrix.length == 0) {
|
||||
return new String[0][0];
|
||||
} else {
|
||||
String[][] strMatrix = new String[matrix.length][matrix[0].length];
|
||||
for (int i = 0; i < matrix.length; i++) {
|
||||
for (int j = 0; j < matrix[i].length; j++) {
|
||||
strMatrix[i][j] = decimalFormat.format(matrix[i][j]);
|
||||
@@ -176,6 +179,7 @@ public class Dataset {
|
||||
}
|
||||
return strMatrix;
|
||||
}
|
||||
}
|
||||
|
||||
public void addValueToMatrix(int row, int coll, float value) {
|
||||
matrix[row][coll] = value;
|
||||
|
@@ -186,7 +186,8 @@ public class SolrLogger
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
log.error(e.getMessage());
|
||||
log.error("Failed DNS Lookup for IP:" + ip);
|
||||
log.debug(e.getMessage(),e);
|
||||
}
|
||||
|
||||
// Save the location information if valid, save the event without
|
||||
|
@@ -15,6 +15,7 @@ import java.util.Vector;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.lang.reflect.Array;
|
||||
import org.dspace.core.I18nUtil;
|
||||
|
||||
/**
|
||||
* Mapping between Country codes, English Country names,
|
||||
@@ -799,13 +800,21 @@ public class LocationUtils {
|
||||
{"OC", "Oceania"}};
|
||||
|
||||
public static String getCountryName(String countryCode){
|
||||
if (countryCode.length() > 0 && countryCodeList.contains(countryCode)) {
|
||||
int index = countryCodeList.indexOf(countryCode);
|
||||
return countryNameList.get(index).toString();
|
||||
} else {
|
||||
return I18nUtil.getMessage("org.dspace.statistics.util.LocationUtils.unknown-country");
|
||||
}
|
||||
}
|
||||
|
||||
public static String getContinentCode(String countryCode){
|
||||
if(countryCode.length() > 0 && countryCodeList.contains(countryCode)) {
|
||||
int index = countryCodeList.indexOf(countryCode);
|
||||
return continentCodeList.get(index).toString();
|
||||
} else {
|
||||
return I18nUtil.getMessage("org.dspace.statistics.util.LocationUtils.unknown-continent");
|
||||
}
|
||||
}
|
||||
|
||||
public static String getContinentName(String continentCode){
|
||||
|
@@ -242,8 +242,6 @@ public class StatisticsImporter
|
||||
|
||||
data += ("ip addr = " + ip);
|
||||
data += (", dns name = " + dns);
|
||||
data += (", country = " + country);
|
||||
data += (", city = " + city);
|
||||
if ((dns.endsWith(".googlebot.com.")) ||
|
||||
(dns.endsWith(".crawl.yahoo.net.")) ||
|
||||
(dns.endsWith(".search.msn.com.")))
|
||||
@@ -253,7 +251,6 @@ public class StatisticsImporter
|
||||
searchengines++;
|
||||
continue;
|
||||
}
|
||||
if (verbose) System.out.println(data);
|
||||
|
||||
// Get the geo information for the user
|
||||
Location location;
|
||||
@@ -264,6 +261,11 @@ public class StatisticsImporter
|
||||
countryCode = location.countryCode;
|
||||
longitude = location.longitude;
|
||||
latitude = location.latitude;
|
||||
if(verbose) {
|
||||
data += (", country = " + country);
|
||||
data += (", city = " + city);
|
||||
System.out.println(data);
|
||||
}
|
||||
try {
|
||||
continent = LocationUtils.getContinentCode(countryCode);
|
||||
} catch (Exception e) {
|
||||
|
@@ -16,7 +16,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-sword</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -42,9 +42,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-sword/dspace-sword-api</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-sword/dspace-sword-api</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-sword/dspace-sword-api</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-sword/dspace-sword-api</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-sword/dspace-sword-api</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-sword/dspace-sword-api</url>
|
||||
</scm>
|
||||
|
||||
<dependencies>
|
||||
@@ -67,22 +67,11 @@
|
||||
<artifactId>dspace-api-lang</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>xom</groupId>
|
||||
<artifactId>xom</artifactId>
|
||||
<version>1.1</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>jaxen</groupId>
|
||||
<artifactId>jaxen</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
<artifactId>servlet-api</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- additional dependencies for the sword-common code -->
|
||||
<dependency>
|
||||
<groupId>commons-fileupload</groupId>
|
||||
@@ -124,13 +113,6 @@
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
<!-- GUI client dependency
|
||||
<dependency>
|
||||
<groupId>org.jdesktop</groupId>
|
||||
<artifactId>swing-worker</artifactId>
|
||||
<version>1.1</version>
|
||||
</dependency>
|
||||
-->
|
||||
<dependency>
|
||||
<groupId>xom</groupId>
|
||||
<artifactId>xom</artifactId>
|
||||
@@ -142,7 +124,6 @@
|
||||
<version>1.3.1</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
</dependencies>
|
||||
|
||||
</project>
|
@@ -80,7 +80,7 @@ public class DSpaceSWORDServer implements SWORDServer
|
||||
{
|
||||
// gah. bloody variable scoping.
|
||||
// set up a dummy sword context for the "finally" block
|
||||
SWORDContext sc = new SWORDContext();
|
||||
SWORDContext sc = null;
|
||||
|
||||
try
|
||||
{
|
||||
@@ -113,9 +113,12 @@ public class DSpaceSWORDServer implements SWORDServer
|
||||
finally
|
||||
{
|
||||
// this is a read operation only, so there's never any need to commit the context
|
||||
if (sc != null)
|
||||
{
|
||||
sc.abort();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.purl.sword.SWORDServer#doSWORDDeposit(org.purl.sword.server.Deposit)
|
||||
@@ -125,7 +128,7 @@ public class DSpaceSWORDServer implements SWORDServer
|
||||
{
|
||||
// gah. bloody variable scoping.
|
||||
// set up a dummy sword context for the "finally" block
|
||||
SWORDContext sc = new SWORDContext();
|
||||
SWORDContext sc = null;
|
||||
|
||||
try
|
||||
{
|
||||
@@ -163,9 +166,12 @@ public class DSpaceSWORDServer implements SWORDServer
|
||||
{
|
||||
// if, for some reason, we wind up here with a not null context
|
||||
// then abort it (the above should commit it if everything works fine)
|
||||
if (sc != null)
|
||||
{
|
||||
sc.abort();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.purl.sword.SWORDServer#doSWORDDeposit(org.purl.sword.server.Deposit)
|
||||
@@ -175,7 +181,7 @@ public class DSpaceSWORDServer implements SWORDServer
|
||||
{
|
||||
// gah. bloody variable scoping.
|
||||
// set up a dummy sword context for the "finally" block
|
||||
SWORDContext sc = new SWORDContext();
|
||||
SWORDContext sc = null;
|
||||
|
||||
try
|
||||
{
|
||||
@@ -208,7 +214,10 @@ public class DSpaceSWORDServer implements SWORDServer
|
||||
finally
|
||||
{
|
||||
// this is a read operation only, so there's never any need to commit the context
|
||||
if (sc != null)
|
||||
{
|
||||
sc.abort();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -129,7 +129,44 @@ public class SWORDAuthenticator
|
||||
throws SWORDException, SWORDErrorException, SWORDAuthenticationException
|
||||
{
|
||||
Context context = this.constructContext(request.getIPAddress());
|
||||
return this.authenticate(context, request);
|
||||
SWORDContext sc = null;
|
||||
try
|
||||
{
|
||||
sc = this.authenticate(context, request);
|
||||
}
|
||||
catch (SWORDException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
catch (SWORDErrorException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
catch (SWORDAuthenticationException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
catch (RuntimeException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
return sc;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -146,7 +183,44 @@ public class SWORDAuthenticator
|
||||
throws SWORDException, SWORDErrorException, SWORDAuthenticationException
|
||||
{
|
||||
Context context = this.constructContext(request.getIPAddress());
|
||||
return this.authenticate(context, request);
|
||||
SWORDContext sc = null;
|
||||
try
|
||||
{
|
||||
sc = this.authenticate(context, request);
|
||||
}
|
||||
catch (SWORDException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
catch (SWORDErrorException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
catch (SWORDAuthenticationException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
catch (RuntimeException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
return sc;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -194,7 +268,44 @@ public class SWORDAuthenticator
|
||||
throws SWORDException, SWORDErrorException, SWORDAuthenticationException
|
||||
{
|
||||
Context context = this.constructContext(deposit.getIPAddress());
|
||||
return this.authenticate(context, deposit);
|
||||
SWORDContext sc = null;
|
||||
try
|
||||
{
|
||||
sc = this.authenticate(context, deposit);
|
||||
}
|
||||
catch (SWORDException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
catch (SWORDErrorException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
catch (SWORDAuthenticationException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
catch (RuntimeException e)
|
||||
{
|
||||
if (context != null && context.isValid())
|
||||
{
|
||||
context.abort();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
return sc;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -14,7 +14,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-sword</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -40,9 +40,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-sword/dspace-sword-webapp</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-sword/dspace-sword-webapp</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-sword/dspace-sword-webapp</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-sword/dspace-sword-webapp</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-sword/dspace-sword-webapp</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-sword/dspace-sword-webapp</url>
|
||||
</scm>
|
||||
|
||||
<build>
|
||||
@@ -130,7 +130,7 @@
|
||||
<dependency>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-sword-api</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
|
@@ -16,7 +16,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -42,9 +42,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-sword</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-sword</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-sword</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-sword</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-sword</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-sword</url>
|
||||
</scm>
|
||||
|
||||
|
||||
|
@@ -14,7 +14,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -40,9 +40,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-ui-shared</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-ui-shared</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-ui-shared</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-ui-shared</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-ui-shared</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-ui-shared</url>
|
||||
</scm>
|
||||
|
||||
<!--
|
||||
|
@@ -13,7 +13,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-xmlui</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -34,9 +34,9 @@
|
||||
</repositories>
|
||||
|
||||
<scm>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui/dspace-xmlui-api</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui/dspace-xmlui-api</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui/dspace-xmlui-api/</url>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-xmlui/dspace-xmlui-api</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-xmlui/dspace-xmlui-api</url>
|
||||
</scm>
|
||||
|
||||
<dependencies>
|
||||
|
@@ -87,8 +87,10 @@ public class MetadataImportConfirm extends AbstractDSpaceTransformer {
|
||||
private static final Message T_changes_committed = message("xmlui.administrative.metadataimport.MetadataImportConfirm.changes_committed");
|
||||
private static final Message T_item_addition = message("xmlui.administrative.metadataimport.MetadataImportConfirm.item_added");
|
||||
private static final Message T_item_deletion = message("xmlui.administrative.metadataimport.MetadataImportConfirm.item_removed");
|
||||
private static final Message T_collection_addition = message("xmlui.administrative.metadataimport.MetadataImportConfirm.collection_added");
|
||||
private static final Message T_collection_deletion = message("xmlui.administrative.metadataimport.MetadataImportConfirm.collection_removed");
|
||||
private static final Message T_collection_newowner = message("xmlui.administrative.metadataimport.MetadataImportConfirm.collection_newowner");
|
||||
private static final Message T_collection_oldowner = message("xmlui.administrative.metadataimport.MetadataImportConfirm.collection_oldowner");
|
||||
private static final Message T_collection_mapped = message("xmlui.administrative.metadataimport.MetadataImportConfirm.collection_mapped");
|
||||
private static final Message T_collection_unmapped = message("xmlui.administrative.metadataimport.MetadataImportConfirm.collection_unmapped");
|
||||
|
||||
|
||||
public void addPageMeta(PageMeta pageMeta) throws WingException
|
||||
@@ -108,7 +110,9 @@ public class MetadataImportConfirm extends AbstractDSpaceTransformer {
|
||||
ArrayList<BulkEditChange> changes = null;
|
||||
|
||||
if(request.getAttribute("changes") != null)
|
||||
{
|
||||
changes = ((ArrayList<BulkEditChange>)request.getAttribute("changes"));
|
||||
}
|
||||
|
||||
// DIVISION: metadata-import
|
||||
Division div = body.addInteractiveDivision("metadata-import",contextPath + "/admin/metadataimport", Division.METHOD_MULTIPART,"primary administrative");
|
||||
@@ -129,11 +133,12 @@ public class MetadataImportConfirm extends AbstractDSpaceTransformer {
|
||||
// Get the changes
|
||||
ArrayList<DCValue> adds = change.getAdds();
|
||||
ArrayList<DCValue> removes = change.getRemoves();
|
||||
ArrayList<Collection> newCollections = change.getNewOwningCollections();
|
||||
ArrayList<Collection> oldCollections = change.getOldOwningCollections();
|
||||
ArrayList<Collection> newCollections = change.getNewMappedCollections();
|
||||
ArrayList<Collection> oldCollections = change.getOldMappedCollections();
|
||||
|
||||
if ((adds.size() > 0) || (removes.size() > 0) ||
|
||||
(newCollections.size() > 0) || (oldCollections.size() > 0))
|
||||
(newCollections.size() > 0) || (oldCollections.size() > 0) ||
|
||||
(change.getNewOwningCollection() != null) || (change.getOldOwningCollection() != null))
|
||||
{
|
||||
Row headerrow = mdchanges.addRow(Row.ROLE_HEADER);
|
||||
// Show the item
|
||||
@@ -153,23 +158,51 @@ public class MetadataImportConfirm extends AbstractDSpaceTransformer {
|
||||
changeCounter++;
|
||||
}
|
||||
|
||||
// Show new collections
|
||||
// Show new owning collection
|
||||
if (change.getNewOwningCollection() != null)
|
||||
{
|
||||
Collection c = change.getNewOwningCollection();
|
||||
if (c != null)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
Row colrow = mdchanges.addRow("addition",Row.ROLE_DATA,"metadata-addition");
|
||||
colrow.addCellContent(T_collection_newowner);
|
||||
colrow.addCellContent(cHandle + " (" + cName + ")");
|
||||
}
|
||||
}
|
||||
|
||||
// Show old owning collection
|
||||
if (change.getOldOwningCollection() != null)
|
||||
{
|
||||
Collection c = change.getOldOwningCollection();
|
||||
if (c != null)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
Row colrow = mdchanges.addRow("deletion",Row.ROLE_DATA,"metadata-deletion");
|
||||
colrow.addCellContent(T_collection_oldowner);
|
||||
colrow.addCellContent(cHandle + " (" + cName + ")");
|
||||
}
|
||||
}
|
||||
|
||||
// Show new mapped collections
|
||||
for (Collection c : newCollections)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
Row colrow = mdchanges.addRow("addition",Row.ROLE_DATA,"metadata-addition");
|
||||
colrow.addCellContent(T_collection_addition);
|
||||
colrow.addCellContent(T_collection_mapped);
|
||||
colrow.addCellContent(cHandle + " (" + cName + ")");
|
||||
}
|
||||
|
||||
// Show old collections
|
||||
// Show old mapped collections
|
||||
for (Collection c : oldCollections)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
Row colrow = mdchanges.addRow("deletion",Row.ROLE_DATA,"metadata-deletion");
|
||||
colrow.addCellContent(T_collection_deletion);
|
||||
colrow.addCellContent(T_collection_unmapped);
|
||||
colrow.addCellContent(cHandle + " (" + cName + ")");
|
||||
}
|
||||
|
||||
|
@@ -87,10 +87,10 @@ public class MetadataImportUpload extends AbstractDSpaceTransformer {
|
||||
private static final Message T_changes_pending = message("xmlui.administrative.metadataimport.MetadataImportUpload.changes_pending");
|
||||
private static final Message T_item_addition = message("xmlui.administrative.metadataimport.MetadataImportUpload.item_add");
|
||||
private static final Message T_item_deletion = message("xmlui.administrative.metadataimport.MetadataImportUpload.item_remove");
|
||||
private static final Message T_collection_addition = message("xmlui.administrative.metadataimport.MetadataImportUpload.collection_add");
|
||||
private static final Message T_collection_deletion = message("xmlui.administrative.metadataimport.MetadataImportUpload.collection_remove");
|
||||
|
||||
|
||||
private static final Message T_collection_newowner = message("xmlui.administrative.metadataimport.MetadataImportUpload.collection_newowner");
|
||||
private static final Message T_collection_oldowner = message("xmlui.administrative.metadataimport.MetadataImportUpload.collection_oldowner");
|
||||
private static final Message T_collection_mapped = message("xmlui.administrative.metadataimport.MetadataImportUpload.collection_mapped");
|
||||
private static final Message T_collection_unmapped = message("xmlui.administrative.metadataimport.MetadataImportUpload.collection_unmapped");
|
||||
|
||||
public void addPageMeta(PageMeta pageMeta) throws WingException
|
||||
{
|
||||
@@ -134,8 +134,8 @@ public class MetadataImportUpload extends AbstractDSpaceTransformer {
|
||||
// Get the changes
|
||||
ArrayList<DCValue> adds = change.getAdds();
|
||||
ArrayList<DCValue> removes = change.getRemoves();
|
||||
ArrayList<Collection> newCollections = change.getNewOwningCollections();
|
||||
ArrayList<Collection> oldCollections = change.getOldOwningCollections();
|
||||
ArrayList<Collection> newCollections = change.getNewMappedCollections();
|
||||
ArrayList<Collection> oldCollections = change.getOldMappedCollections();
|
||||
|
||||
if ((adds.size() > 0) || (removes.size() > 0) ||
|
||||
(newCollections.size() > 0) || (oldCollections.size() > 0))
|
||||
@@ -158,23 +158,51 @@ public class MetadataImportUpload extends AbstractDSpaceTransformer {
|
||||
changeCounter++;
|
||||
}
|
||||
|
||||
// Show new collections
|
||||
// Show new owning collection
|
||||
if (change.getNewOwningCollection() != null)
|
||||
{
|
||||
Collection c = change.getNewOwningCollection();
|
||||
if (c != null)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
Row colrow = mdchanges.addRow("addition",Row.ROLE_DATA,"metadata-addition");
|
||||
colrow.addCellContent(T_collection_newowner);
|
||||
colrow.addCellContent(cHandle + " (" + cName + ")");
|
||||
}
|
||||
}
|
||||
|
||||
// Show old owning collection
|
||||
if (change.getOldOwningCollection() != null)
|
||||
{
|
||||
Collection c = change.getOldOwningCollection();
|
||||
if (c != null)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
Row colrow = mdchanges.addRow("deletion",Row.ROLE_DATA,"metadata-deletion");
|
||||
colrow.addCellContent(T_collection_oldowner);
|
||||
colrow.addCellContent(cHandle + " (" + cName + ")");
|
||||
}
|
||||
}
|
||||
|
||||
// Show new mapped collections
|
||||
for (Collection c : newCollections)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
Row colrow = mdchanges.addRow("addition",Row.ROLE_DATA,"metadata-addition");
|
||||
colrow.addCellContent(T_collection_addition);
|
||||
colrow.addCellContent(T_collection_mapped);
|
||||
colrow.addCellContent(cHandle + " (" + cName + ")");
|
||||
}
|
||||
|
||||
// Show old collections
|
||||
// Show old mapped collections
|
||||
for (Collection c : oldCollections)
|
||||
{
|
||||
String cHandle = c.getHandle();
|
||||
String cName = c.getName();
|
||||
Row colrow = mdchanges.addRow("deletion",Row.ROLE_DATA,"metadata-deletion");
|
||||
colrow.addCellContent(T_collection_deletion);
|
||||
colrow.addCellContent(T_collection_unmapped);
|
||||
colrow.addCellContent(cHandle + " (" + cName + ")");
|
||||
}
|
||||
|
||||
|
@@ -124,7 +124,7 @@ public class CollectionViewer extends AbstractDSpaceTransformer implements Cache
|
||||
message("xmlui.ArtifactBrowser.CollectionViewer.head_recent_submissions");
|
||||
|
||||
/** How many recent submissions to include in the page */
|
||||
private static final int RECENT_SUBMISISONS = 5;
|
||||
private static final int RECENT_SUBMISSIONS = 5;
|
||||
|
||||
/** The cache of recently submitted items */
|
||||
private java.util.List<BrowseItem> recentSubmissionItems;
|
||||
@@ -355,9 +355,10 @@ public class CollectionViewer extends AbstractDSpaceTransformer implements Cache
|
||||
return recentSubmissionItems;
|
||||
|
||||
String source = ConfigurationManager.getProperty("recent.submissions.sort-option");
|
||||
int numRecentSubmissions = ConfigurationManager.getIntProperty("recent.submissions.count", RECENT_SUBMISSIONS);
|
||||
BrowserScope scope = new BrowserScope(context);
|
||||
scope.setCollection(collection);
|
||||
scope.setResultsPerPage(RECENT_SUBMISISONS);
|
||||
scope.setResultsPerPage(numRecentSubmissions);
|
||||
|
||||
// FIXME Exception Handling
|
||||
try
|
||||
|
@@ -125,7 +125,7 @@ public class CommunityViewer extends AbstractDSpaceTransformer implements Cachea
|
||||
message("xmlui.ArtifactBrowser.CommunityViewer.head_recent_submissions");
|
||||
|
||||
/** How many recent submissions to list */
|
||||
private static final int RECENT_SUBMISISONS = 5;
|
||||
private static final int RECENT_SUBMISSIONS = 5;
|
||||
|
||||
/** The cache of recently submitted items */
|
||||
private java.util.List<BrowseItem> recentSubmittedItems;
|
||||
@@ -397,9 +397,10 @@ public class CommunityViewer extends AbstractDSpaceTransformer implements Cachea
|
||||
return recentSubmittedItems;
|
||||
|
||||
String source = ConfigurationManager.getProperty("recent.submissions.sort-option");
|
||||
int numRecentSubmissions = ConfigurationManager.getIntProperty("recent.submissions.count", RECENT_SUBMISSIONS);
|
||||
BrowserScope scope = new BrowserScope(context);
|
||||
scope.setCommunity(community);
|
||||
scope.setResultsPerPage(RECENT_SUBMISISONS);
|
||||
scope.setResultsPerPage(numRecentSubmissions);
|
||||
|
||||
// FIXME Exception Handling
|
||||
try
|
||||
|
@@ -128,6 +128,8 @@ public class ConfigurableBrowse extends AbstractDSpaceTransformer implements
|
||||
|
||||
private final static Message T_order = message("xmlui.ArtifactBrowser.ConfigurableBrowse.general.order");
|
||||
|
||||
private final static Message T_no_results= message("xmlui.ArtifactBrowser.ConfigurableBrowse.general.no_results");
|
||||
|
||||
private final static Message T_rpp = message("xmlui.ArtifactBrowser.ConfigurableBrowse.general.rpp");
|
||||
|
||||
private final static Message T_etal = message("xmlui.ArtifactBrowser.ConfigurableBrowse.general.etal");
|
||||
@@ -282,9 +284,12 @@ public class ConfigurableBrowse extends AbstractDSpaceTransformer implements
|
||||
// This div will hold the browsing results
|
||||
Division results = div.addDivision("browse-by-" + type + "-results", "primary");
|
||||
|
||||
// Add the pagination
|
||||
// If there are items to browse, add the pagination
|
||||
int itemsTotal = info.getTotal();
|
||||
if (itemsTotal > 0)
|
||||
{
|
||||
//results.setSimplePagination(itemsTotal, firstItemIndex, lastItemIndex, previousPage, nextPage)
|
||||
results.setSimplePagination(info.getTotal(), browseInfo.getOverallPosition() + 1,
|
||||
results.setSimplePagination(itemsTotal, browseInfo.getOverallPosition() + 1,
|
||||
browseInfo.getOverallPosition() + browseInfo.getResultCount(), getPreviousPageURL(
|
||||
params, info), getNextPageURL(params, info));
|
||||
|
||||
@@ -335,6 +340,11 @@ public class ConfigurableBrowse extends AbstractDSpaceTransformer implements
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
results.addPara(T_no_results);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Recycle
|
||||
|
@@ -447,7 +447,11 @@ public class DescribeStep extends AbstractSubmissionStep
|
||||
if (dcInput.isRequired())
|
||||
fullName.setRequired();
|
||||
if (isFieldInError(fieldName))
|
||||
if (dcInput.getWarning() != null && dcInput.getWarning().length() > 0) {
|
||||
fullName.addError(dcInput.getWarning());
|
||||
} else {
|
||||
fullName.addError(T_required_field);
|
||||
}
|
||||
if (dcInput.isRepeatable() && !readonly)
|
||||
fullName.enableAddOperation();
|
||||
if ((dcInput.isRepeatable() || dcValues.length > 1) && !readonly)
|
||||
@@ -543,7 +547,11 @@ public class DescribeStep extends AbstractSubmissionStep
|
||||
if (dcInput.isRequired())
|
||||
fullDate.setRequired();
|
||||
if (isFieldInError(fieldName))
|
||||
if (dcInput.getWarning() != null && dcInput.getWarning().length() > 0) {
|
||||
fullDate.addError(dcInput.getWarning());
|
||||
} else {
|
||||
fullDate.addError(T_required_field);
|
||||
}
|
||||
if (dcInput.isRepeatable() && !readonly)
|
||||
fullDate.enableAddOperation();
|
||||
if ((dcInput.isRepeatable() || dcValues.length > 1) && !readonly)
|
||||
@@ -632,7 +640,11 @@ public class DescribeStep extends AbstractSubmissionStep
|
||||
if (dcInput.isRequired())
|
||||
fullSeries.setRequired();
|
||||
if (isFieldInError(fieldName))
|
||||
if (dcInput.getWarning() != null && dcInput.getWarning().length() > 0) {
|
||||
fullSeries.addError(dcInput.getWarning());
|
||||
} else {
|
||||
fullSeries.addError(T_required_field);
|
||||
}
|
||||
if (dcInput.isRepeatable() && !readonly)
|
||||
fullSeries.enableAddOperation();
|
||||
if ((dcInput.isRepeatable() || dcValues.length > 1) && !readonly)
|
||||
@@ -698,7 +710,11 @@ public class DescribeStep extends AbstractSubmissionStep
|
||||
if (dcInput.isRequired())
|
||||
qualdrop.setRequired();
|
||||
if (isFieldInError(fieldName))
|
||||
if (dcInput.getWarning() != null && dcInput.getWarning().length() > 0) {
|
||||
qualdrop.addError(dcInput.getWarning());
|
||||
} else {
|
||||
qualdrop.addError(T_required_field);
|
||||
}
|
||||
if (dcInput.isRepeatable() && !readonly)
|
||||
qualdrop.enableAddOperation();
|
||||
// Update delete based upon the filtered values.
|
||||
@@ -776,7 +792,11 @@ public class DescribeStep extends AbstractSubmissionStep
|
||||
if (dcInput.isRequired())
|
||||
textArea.setRequired();
|
||||
if (isFieldInError(fieldName))
|
||||
if (dcInput.getWarning() != null && dcInput.getWarning().length() > 0) {
|
||||
textArea.addError(dcInput.getWarning());
|
||||
} else {
|
||||
textArea.addError(T_required_field);
|
||||
}
|
||||
if (dcInput.isRepeatable() && !readonly)
|
||||
textArea.enableAddOperation();
|
||||
if ((dcInput.isRepeatable() || dcValues.length > 1) && !readonly)
|
||||
@@ -845,7 +865,11 @@ public class DescribeStep extends AbstractSubmissionStep
|
||||
if (dcInput.isRequired())
|
||||
select.setRequired();
|
||||
if (isFieldInError(fieldName))
|
||||
if (dcInput.getWarning() != null && dcInput.getWarning().length() > 0) {
|
||||
select.addError(dcInput.getWarning());
|
||||
} else {
|
||||
select.addError(T_required_field);
|
||||
}
|
||||
if (dcInput.isRepeatable() || dcValues.length > 1)
|
||||
{
|
||||
// Use the multiple functionality from the HTML
|
||||
@@ -900,7 +924,11 @@ public class DescribeStep extends AbstractSubmissionStep
|
||||
if (dcInput.isRequired())
|
||||
select.setRequired();
|
||||
if (isFieldInError(fieldName))
|
||||
if (dcInput.getWarning() != null && dcInput.getWarning().length() > 0) {
|
||||
select.addError(dcInput.getWarning());
|
||||
} else {
|
||||
select.addError(T_required_field);
|
||||
}
|
||||
if (dcInput.isRepeatable() || dcValues.length > 1)
|
||||
{
|
||||
// Use the multiple functionality from the HTML
|
||||
@@ -974,7 +1002,11 @@ public class DescribeStep extends AbstractSubmissionStep
|
||||
if (dcInput.isRequired())
|
||||
listField.setRequired();
|
||||
if (isFieldInError(fieldName))
|
||||
if (dcInput.getWarning() != null && dcInput.getWarning().length() > 0) {
|
||||
listField.addError(dcInput.getWarning());
|
||||
} else {
|
||||
listField.addError(T_required_field);
|
||||
}
|
||||
|
||||
|
||||
//Setup each of the possible options
|
||||
@@ -1050,7 +1082,11 @@ public class DescribeStep extends AbstractSubmissionStep
|
||||
if (dcInput.isRequired())
|
||||
text.setRequired();
|
||||
if (isFieldInError(fieldName))
|
||||
if (dcInput.getWarning() != null && dcInput.getWarning().length() > 0) {
|
||||
text.addError(dcInput.getWarning());
|
||||
} else {
|
||||
text.addError(T_required_field);
|
||||
}
|
||||
if (dcInput.isRepeatable() && !readonly)
|
||||
text.enableAddOperation();
|
||||
if ((dcInput.isRepeatable() || dcValues.length > 1) && !readonly)
|
||||
|
@@ -184,8 +184,19 @@ public class DSpaceMETSGenerator extends AbstractGenerator
|
||||
if (parts.length == 2)
|
||||
{
|
||||
String type = parts[0];
|
||||
int id = Integer.valueOf(parts[1]);
|
||||
String strid = parts[1];
|
||||
int id = 0;
|
||||
|
||||
// Handle prefixes must be treated as strings
|
||||
// all non-repository types need integer IDs
|
||||
if ("repository".equals(type))
|
||||
{
|
||||
if (ConfigurationManager.getProperty("handle.prefix").equals(strid))
|
||||
adapter = new RepositoryAdapter(context,contextPath);
|
||||
}
|
||||
else
|
||||
{
|
||||
id = Integer.valueOf(parts[1]);
|
||||
if ("item".equals(type))
|
||||
{
|
||||
Item item = Item.find(context,id);
|
||||
@@ -204,12 +215,7 @@ public class DSpaceMETSGenerator extends AbstractGenerator
|
||||
if (community != null)
|
||||
adapter = new ContainerAdapter(context, community,contextPath);
|
||||
}
|
||||
else if ("repository".equals(type))
|
||||
{
|
||||
if (ConfigurationManager.getProperty("handle.prefix").equals(String.valueOf(id)))
|
||||
adapter = new RepositoryAdapter(context,contextPath);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
return adapter;
|
||||
|
@@ -564,8 +564,12 @@ public class AuthenticationUtil
|
||||
|
||||
// Return the path for which this request belongs too. Only urls
|
||||
// for this path may be resumed.
|
||||
if (interruptedRequest.getServletPath() == null || interruptedRequest.getServletPath().length() == 0) {
|
||||
return interruptedRequest.getActualPath();
|
||||
} else {
|
||||
return interruptedRequest.getServletPath();
|
||||
}
|
||||
}
|
||||
|
||||
// No request was interrupted.
|
||||
return null;
|
||||
|
@@ -118,6 +118,14 @@ public class RequestInfo
|
||||
return this.servletPath;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the servlet path that this request is for.
|
||||
*/
|
||||
public String getActualPath()
|
||||
{
|
||||
return this.pathInfo + ((queryString == null || queryString.length() == 0) ? "" : "?"+queryString);
|
||||
}
|
||||
|
||||
/**
|
||||
* Wrap an incoming request to make it look like the request that the
|
||||
* constructor was called with
|
||||
|
@@ -13,7 +13,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-xmlui</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -34,9 +34,9 @@
|
||||
</repositories>
|
||||
|
||||
<scm>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui/dspace-xmlui-webapp</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui/dspace-xmlui-webapp</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui/dspace-xmlui-webapp</url>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-xmlui/dspace-xmlui-webapp</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-xmlui/dspace-xmlui-webapp</url>
|
||||
</scm>
|
||||
|
||||
<build>
|
||||
|
@@ -3,8 +3,8 @@
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:util="http://www.springframework.org/schema/util"
|
||||
xmlns:configurator="http://cocoon.apache.org/schema/configurator"
|
||||
xmlns:avalon="http://cocoon.apache.org/schema/avalon" xmlns:servlet="http://cocoon.apache.org/schema/servlet"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.0.xsd
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
|
||||
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.5.xsd
|
||||
http://cocoon.apache.org/schema/configurator http://cocoon.apache.org/schema/configurator/cocoon-configurator-1.0.1.xsd
|
||||
http://cocoon.apache.org/schema/avalon http://cocoon.apache.org/schema/avalon/cocoon-avalon-1.0.xsd
|
||||
http://cocoon.apache.org/schema/servlet http://cocoon.apache.org/schema/servlet/cocoon-servlet-1.0.xsd">
|
||||
@@ -17,7 +17,7 @@
|
||||
<!-- Activate Avalon Bridge -->
|
||||
<avalon:bridge />
|
||||
|
||||
<bean id="dspace.org.myApplication" class="org.apache.cocoon.servlet.SitemapServlet">
|
||||
<bean id="dspace.org.myApplication" class="org.apache.cocoon.sitemap.SitemapServlet">
|
||||
<servlet:context mount-path="" context-path="" />
|
||||
</bean>
|
||||
|
||||
|
@@ -168,6 +168,7 @@
|
||||
<message key="xmlui.ArtifactBrowser.ConfigurableBrowse.general.choose_year">(Choose year)</message>
|
||||
<message key="xmlui.ArtifactBrowser.ConfigurableBrowse.general.jump_year">Or type in a year: </message>
|
||||
<message key="xmlui.ArtifactBrowser.ConfigurableBrowse.general.jump_year_help">Browse for items that are from the given year.</message>
|
||||
<message key="xmlui.ArtifactBrowser.ConfigurableBrowse.general.no_results">Sorry, there are no results for this browse.</message>
|
||||
<message key="xmlui.ArtifactBrowser.ConfigurableBrowse.general.sort_by"> Sort by: </message>
|
||||
<message key="xmlui.ArtifactBrowser.ConfigurableBrowse.general.order"> Order: </message>
|
||||
<message key="xmlui.ArtifactBrowser.ConfigurableBrowse.general.rpp"> Results: </message><!-- /Page -->
|
||||
@@ -1277,6 +1278,8 @@
|
||||
<message key="xmlui.administrative.item.MoveItemForm.collection_help">Select the collection you wish to move this item to.</message>
|
||||
<message key="xmlui.administrative.item.MoveItemForm.collection_default">Select a collection...</message>
|
||||
<message key="xmlui.administrative.item.MoveItemForm.submit_move">Move</message>
|
||||
<message key="xmlui.administrative.item.MoveItemForm.inherit_policies">Inherit policies</message>
|
||||
<message key="xmlui.administrative.item.MoveItemForm.inherit_policies_help">Inherit the default policies of the destination collection</message>
|
||||
|
||||
<!-- org.dspace.app.xmlui.administrative.item.EditBitstreamForm -->
|
||||
<message key="xmlui.administrative.item.EditBitstreamForm.title">Edit Bitstream</message>
|
||||
@@ -1383,14 +1386,18 @@
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportConfirm.changes_committed">Changes applied to item</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportConfirm.item_added">Added: </message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportConfirm.item_removed">Removed: </message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportConfirm.collection_added">Added to collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportConfirm.collection_removed">Removed from collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportConfirm.collection_newowner">Added to owning collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportConfirm.collection_oldowner">Removed from owning collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportConfirm.collection_mapped">Mapped to collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportConfirm.collection_unmapped">Unmapped from collection</message>
|
||||
|
||||
<!-- org.dspace.app.xmlui.administrative.metadataimport.MetadataImportUpload -->
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.item_add">Add: </message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.item_remove">Remove: </message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.collection_add">Add to collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.collection_remove">Remove from collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.collection_newowner">Add to owning collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.collection_oldowner">Remove from owning collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.collection_mapped">Map to collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.collection_unmapped">Un-map from collection</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.changes_pending">Changes pending for item</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.submit_confirm">Apply changes</message>
|
||||
<message key="xmlui.administrative.metadataimport.MetadataImportUpload.hint">Pending changes are listed below for review</message>
|
||||
|
@@ -800,24 +800,40 @@
|
||||
</span>
|
||||
<xsl:text>, </xsl:text>
|
||||
</xsl:if>
|
||||
|
||||
<span class="date">
|
||||
<!--
|
||||
<xsl:value-of select="substring(dim:field[@element='date' and @qualifier='issued']/node(),1,10)"/>
|
||||
-->
|
||||
|
||||
<xsl:variable name="month-issued" select= "substring(dim:field[@element='date' and @qualifier='issued']/node(),6,2)"/>
|
||||
<xsl:variable name="day-issued" select= "substring(dim:field[@element='date' and @qualifier='issued']/node(),9,2)"/>
|
||||
|
||||
<xsl:if test="string-length($month-issued) > 0">
|
||||
|
||||
<xsl:call-template name="month-name">
|
||||
<xsl:with-param name="date-time" select = "dim:field[@element='date' and @qualifier='issued']/node()"/>
|
||||
</xsl:call-template>
|
||||
|
||||
<xsl:text> </xsl:text>
|
||||
|
||||
<xsl:if test="string-length($day-issued) > 0">
|
||||
|
||||
<xsl:call-template name="day-in-month">
|
||||
<xsl:with-param name="date-time" select = "dim:field[@element='date' and @qualifier='issued']/node()"/>
|
||||
</xsl:call-template>
|
||||
|
||||
</xsl:if>
|
||||
|
||||
<xsl:text>, </xsl:text>
|
||||
|
||||
</xsl:if>
|
||||
|
||||
<xsl:call-template name="year">
|
||||
<xsl:with-param name="date-time" select = "dim:field[@element='date' and @qualifier='issued']/node()"/>
|
||||
</xsl:call-template>
|
||||
|
||||
</span>
|
||||
<xsl:text>)</xsl:text>
|
||||
</span>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</xsl:template>
|
||||
|
@@ -829,7 +829,7 @@
|
||||
</div>
|
||||
</xsl:if>
|
||||
|
||||
<xsl:if test="string-length(dim:field[@element='rights'][not(@qualifier)])>0 or string-length(dim:field[@element='rights'][@qualifier='license'])>0">
|
||||
<xsl:if test="string-length(dim:field[@element='rights'][not(@qualifier)])>0">
|
||||
<div class="detail-view-rights-and-license">
|
||||
<xsl:if test="string-length(dim:field[@element='rights'][not(@qualifier)])>0">
|
||||
<p class="copyright-text">
|
||||
|
@@ -206,7 +206,7 @@
|
||||
</xsl:choose>
|
||||
</td>
|
||||
<!-- Display the contents of 'Description' as long as at least one bitstream contains a description -->
|
||||
<xsl:if test="$context/mets:fileSec/mets:fileGrp/mets:file/mets:FLocat/@xlink:label != ''">
|
||||
<xsl:if test="$context/mets:fileSec/mets:fileGrp[@USE='CONTENT']/mets:file/mets:FLocat/@xlink:label != ''">
|
||||
<td>
|
||||
<xsl:value-of select="mets:FLocat[@LOCTYPE='URL']/@xlink:label"/>
|
||||
</td>
|
||||
|
@@ -552,9 +552,9 @@
|
||||
<xsl:value-of select="mods:note[1]"/>
|
||||
</p>
|
||||
</xsl:if>
|
||||
<xsl:if test="string-length(mods:accessCondition[@type='useAndReproducation'])>0">
|
||||
<xsl:if test="string-length(mods:accessCondition[@type='useAndReproduction'])>0">
|
||||
<p class="copyright-text">
|
||||
<xsl:value-of select="mods:accessCondition[@type='useAndReproducation']"/>
|
||||
<xsl:value-of select="mods:accessCondition[@type='useAndReproduction']"/>
|
||||
</p>
|
||||
</xsl:if>
|
||||
<xsl:if test="string-length(mods:extension/dim:field[@mdschema='dc' and @element='rights.license'])>0">
|
||||
@@ -583,9 +583,9 @@
|
||||
<xsl:value-of select="mods:note[1]"/>
|
||||
</p>
|
||||
</xsl:if>
|
||||
<xsl:if test="string-length(mods:accessCondition[@type='useAndReproducation'])>0">
|
||||
<xsl:if test="string-length(mods:accessCondition[@type='useAndReproduction'])>0">
|
||||
<p class="copyright-text">
|
||||
<xsl:value-of select="mods:accessCondition[@type='useAndReproducation']"/>
|
||||
<xsl:value-of select="mods:accessCondition[@type='useAndReproduction']"/>
|
||||
</p>
|
||||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
@@ -10,7 +10,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-xmlui</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -31,9 +31,9 @@
|
||||
</repositories>
|
||||
|
||||
<scm>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui/dspace-xmlui-wing</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui/dspace-xmlui-wing</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui/dspace-xmlui-wing</url>
|
||||
<connection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-xmlui/dspace-xmlui-wing</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-xmlui/dspace-xmlui-wing</url>
|
||||
</scm>
|
||||
|
||||
<dependencies>
|
||||
@@ -67,15 +67,21 @@
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.apache.cocoon</groupId>
|
||||
<artifactId>cocoon-servlet-service-components</artifactId>
|
||||
<version>1.0.0</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>org.apache.cocoon</groupId>
|
||||
<artifactId>cocoon-servlet-service-impl</artifactId>
|
||||
<version>1.2.0</version>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.apache.cocoon</groupId>
|
||||
<artifactId>cocoon-linkrewriter-impl</artifactId>
|
||||
<version>1.0.0</version>
|
||||
<groupId>org.dspace.dependencies.cocoon</groupId>
|
||||
<artifactId>dspace-cocoon-servlet-service-impl</artifactId>
|
||||
<version>1.0.1</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
|
@@ -12,7 +12,7 @@
|
||||
<parent>
|
||||
<groupId>org.dspace</groupId>
|
||||
<artifactId>dspace-parent</artifactId>
|
||||
<version>1.6.1-SNAPSHOT</version>
|
||||
<version>1.6.1</version>
|
||||
</parent>
|
||||
|
||||
<repositories>
|
||||
@@ -38,9 +38,9 @@
|
||||
into the snapshot repository below.
|
||||
-->
|
||||
<scm>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/trunk/dspace-xmlui</url>
|
||||
<connection>scm:svn:http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-xmlui</connection>
|
||||
<developerConnection>scm:svn:https://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-xmlui</developerConnection>
|
||||
<url>http://scm.dspace.org/svn/repo/dspace/tags/dspace-1.6.1/dspace-xmlui</url>
|
||||
</scm>
|
||||
|
||||
<modules>
|
||||
|
@@ -1,6 +1,84 @@
|
||||
1.6.0
|
||||
1.6.1
|
||||
=====
|
||||
|
||||
(Javier Garrido)
|
||||
- [DS-582] Basque translation (of jspui for DSpace 1.5.2)
|
||||
|
||||
(Mark Diggory)
|
||||
- [DS-571] Upgrade DSpace Services to next release 2.0.1
|
||||
|
||||
|
||||
(Dale Poulter)
|
||||
- [DS-557] LC Authority Names - Lookup Feature - names w/o dates
|
||||
|
||||
(Paulo Jobim)
|
||||
- [DS-471] Accessing site-level 'mets.xml' in XMLUI doesn't work properly for handle prefixes with periods (e.g. 2010.1)
|
||||
|
||||
(Yin Yin Latt)
|
||||
- [DS-565] Empty description column in Itemview Page - General-Handler.xsl
|
||||
- [DS-566] Side bar menu dropping when there is license text in collection - DIM-Handler.xsl
|
||||
|
||||
(Robin Taylor)
|
||||
- [DS-497] Date month and day get default values when user returns to describe form
|
||||
- [DS-501] Change kubrick.xsl to check for the presence of a day and month before displaying them
|
||||
|
||||
(Keiji Suzuki)
|
||||
- [DS-537] Malformed Japanese option values in the authority lookup window
|
||||
|
||||
(Peter Dietz)
|
||||
- [DS-509] SOLR returns ArrayIndexOutOfBounds with non-existent country code OR when there is no view/download data
|
||||
- [DS-542] verbose output for stats-log-importer displays spurious city/country from previous committed entry
|
||||
|
||||
(Kim Shepherd)
|
||||
- [DS-547] Value for Recent Submissions is not workin in the XMLUI
|
||||
- [DS-527] Withdrawn items not shown as deleted in OAI
|
||||
- [DS-548] Removing repeatable values in DescribeStep does not properly test for authority control
|
||||
- [DS-544] Removal of mapped items can lead to NPE
|
||||
|
||||
(Claudia Jurgen)
|
||||
- [DS-558] Error in update sequence script 1.5 to 1.6 Oracle
|
||||
- [DS-551] Export directories dspace.cfg and build.xml out of sync
|
||||
- [DS-543] Harvest not internationalized
|
||||
|
||||
(Serhij Dubyk)
|
||||
- [DS-500] Ukrainian for DSpace 1.6.0
|
||||
|
||||
(Andrea Bollini)
|
||||
- [DS-513] Connection leak in SWORD authentication process
|
||||
- [DS-581] DIDL doesn't respect the hidden fields and the oai_dc metadata section is different than the simple oai_dc implementation
|
||||
- [DS-580] DIDL format include HTML element if the item has no files
|
||||
- [DS-574] DSpaceMETSIngester creates empty original bundle
|
||||
- [DS-573] NPE resuming submission for item with an empty bundle original
|
||||
|
||||
(Caryn Neiswender)
|
||||
- [DS-518] Duplicate listing of dependencies in dspace-sword/pom.xml
|
||||
|
||||
(Keith Gilbertson)
|
||||
- [DS-123] xmlui browse in empty collection displays "Now showing items 1-0" of 0 - incorrect numbering
|
||||
- [DS-508] Attachment spelled as attachement in DailyReportEmailer
|
||||
- [DS-539] Misspelled attribute in MODS/METS output
|
||||
|
||||
(Stuart Lewis)
|
||||
- [DS-242] Special groups shown for logged in user rather than for user being examined
|
||||
- [DS-506] embargo-lifter command missing from launcher.xml
|
||||
- [DS-516] DSRUN does not start Service Manager
|
||||
- [DS-526] ItemUpdate - script update
|
||||
- [DS-572] Batch metadata editor fails to notice change of item's owning collection
|
||||
|
||||
(Mark Wood)
|
||||
- [DS-469] DCDate.displayDate(false,*) displays only year
|
||||
|
||||
(Ivan Masar)
|
||||
- [DS-515] Czech localization of 1.5.2
|
||||
|
||||
(Ben Bosman)
|
||||
- [DS-579] Required fields in submissions display wrong error message
|
||||
- [DS-538] restricted items are being returned in OAI GetRecord method while using harvest.includerestricted.oai
|
||||
- [DS-493] Url in browser is incorrect after login
|
||||
|
||||
1.6.0 final
|
||||
===========
|
||||
|
||||
(Alexey Maslov)
|
||||
- [DS-289] OAI-PMH + OAI-ORE harvesting support
|
||||
|
||||
|
@@ -45,4 +45,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.checker.ChecksumChecker $@
|
||||
$BINDIR/dspace checker "$@"
|
@@ -47,7 +47,7 @@ BINDIR=`dirname $0`
|
||||
|
||||
echo "Cleaning the asset store"
|
||||
|
||||
$BINDIR/dsrun org.dspace.storage.bitstore.Cleanup "$@"
|
||||
$BINDIR/dspace cleanup "$@"
|
||||
|
||||
echo "Cleanup completed"
|
||||
|
||||
|
@@ -45,4 +45,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.administer.CreateAdministrator "$@"
|
||||
$BINDIR/dspace create-administrator "$@"
|
||||
|
@@ -39,10 +39,27 @@
|
||||
# DAMAGE.
|
||||
#
|
||||
###########################################################################
|
||||
#
|
||||
# This is a simple shell script for running a command-line DSpace tool.
|
||||
# It sets the CLASSPATH appropriately before invoking Java.
|
||||
|
||||
# Script for running the DSpace launcher.
|
||||
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
DSPACEDIR=`cd "$BINDIR/.." ; pwd`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.launcher.ScriptLauncher $@
|
||||
# Get the JARs in $DSPACEDIR/jsp/WEB-INF/lib, separated by ':'
|
||||
JARS=`echo $DSPACEDIR/lib/*.jar | sed 's/ /\:/g'`
|
||||
|
||||
# Class path for DSpace will be:
|
||||
# Any existing classpath
|
||||
# The JARs (WEB-INF/lib/*.jar)
|
||||
# The WEB-INF/classes directory
|
||||
FULLPATH=$CLASSPATH:$JARS:$DSPACEDIR/config
|
||||
|
||||
#Allow user to specify java options through JAVA_OPTS variable
|
||||
if [ "$JAVA_OPTS" = "" ]; then
|
||||
#Default Java to use 256MB of memory
|
||||
JAVA_OPTS=-Xmx256m
|
||||
fi
|
||||
|
||||
# Now invoke Java
|
||||
java $JAVA_OPTS -classpath $FULLPATH org.dspace.app.launcher.ScriptLauncher "$@"
|
||||
|
@@ -38,4 +38,37 @@
|
||||
@REM #
|
||||
@REM ###########################################################################
|
||||
|
||||
@call dsrun.bat org.dspace.app.launcher.ScriptLauncher %*
|
||||
@echo off
|
||||
|
||||
set CURRENT_DIR=%cd%
|
||||
|
||||
REM Guess DSpace directory: CD to directory script is in; CD to parent
|
||||
chdir /D "%~p0"
|
||||
chdir ..
|
||||
|
||||
REM Check we can find dspace.cfg. Quit with an error if not.
|
||||
if exist "config\dspace.cfg" goto okExec
|
||||
echo Cannot find %cd%\config\dspace.cfg
|
||||
goto end
|
||||
|
||||
:okExec
|
||||
echo Using DSpace installation in: %cd%
|
||||
|
||||
REM Build a CLASSPATH
|
||||
set DSPACE_CLASSPATH=%CLASSPATH%;config
|
||||
for %%f in (lib\*.jar) DO CALL bin\buildpath.bat %%f
|
||||
|
||||
REM If JAVA_OPTS specified, use those options
|
||||
REM Otherwise, default Java to using 256MB of memory
|
||||
if "%JAVA_OPTS%"=="" set JAVA_OPTS=-Xmx256m
|
||||
|
||||
REM Execute Java
|
||||
java %JAVA_OPTS% -classpath "%DSPACE_CLASSPATH%" org.dspace.app.launcher.ScriptLauncher %*
|
||||
|
||||
REM Clean up DSPACE_CLASSPATH variable
|
||||
set DSPACE_CLASSPATH=
|
||||
|
||||
:end
|
||||
|
||||
REM Back to original dir
|
||||
chdir /D %CURRENT_DIR%
|
@@ -42,15 +42,7 @@
|
||||
# This is a simple shell script for running retrieving the value of a dspace
|
||||
# property
|
||||
|
||||
USAGE="dsprop <property.name>"
|
||||
|
||||
# Check we have at least one command-line argument
|
||||
if [ "$#" != "1" ]; then
|
||||
echo $USAGE
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.core.ConfigurationManager -property "$1"
|
||||
$BINDIR/dspace dsprop -property "$1"
|
||||
|
@@ -43,7 +43,7 @@
|
||||
# This is a simple shell script for running a command-line DSpace tool.
|
||||
# It sets the CLASSPATH appropriately before invoking Java.
|
||||
|
||||
USAGE="dsrun <classname> [arg1 [arg2 ...]]"
|
||||
USAGE="dspace dsrun <classname> [arg1 [arg2 ...]]"
|
||||
|
||||
# Check we have at least one command-line argument
|
||||
if [ "$#" = "0" ]; then
|
||||
@@ -51,24 +51,5 @@ if [ "$#" = "0" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Assume we're in the bin subdirectory of the DSpace installation directory
|
||||
BINDIR=`dirname $0`
|
||||
DSPACEDIR=`cd "$BINDIR/.." ; pwd`
|
||||
|
||||
# Get the JARs in $DSPACEDIR/jsp/WEB-INF/lib, separated by ':'
|
||||
JARS=`echo $DSPACEDIR/lib/*.jar | sed 's/ /\:/g'`
|
||||
|
||||
# Class path for DSpace will be:
|
||||
# Any existing classpath
|
||||
# The JARs (WEB-INF/lib/*.jar)
|
||||
# The WEB-INF/classes directory
|
||||
FULLPATH=$CLASSPATH:$JARS:$DSPACEDIR/config
|
||||
|
||||
#Allow user to specify java options through JAVA_OPTS variable
|
||||
if [ "$JAVA_OPTS" = "" ]; then
|
||||
#Default Java to use 256MB of memory
|
||||
JAVA_OPTS=-Xmx256m
|
||||
fi
|
||||
|
||||
# Now invoke Java
|
||||
java $JAVA_OPTS -classpath $FULLPATH "$@"
|
||||
$BINDIR/dspace dsrun "$@"
|
||||
|
@@ -43,49 +43,4 @@
|
||||
REM This is a simple shell script for running a command-line DSpace tool.
|
||||
REM sets the CLASSPATH appropriately before invoking Java.
|
||||
|
||||
REM Remember startup dir
|
||||
|
||||
set CURRENT_DIR=%cd%
|
||||
|
||||
|
||||
REM Guess DSpace directory: CD to directory script is in; CD to parent
|
||||
|
||||
chdir /D "%~p0"
|
||||
chdir ..
|
||||
|
||||
REM Check we can find dspace.cfg. Quit with an error if not.
|
||||
|
||||
if exist "config\dspace.cfg" goto okExec
|
||||
echo Cannot find %cd%\config\dspace.cfg
|
||||
goto end
|
||||
|
||||
|
||||
:okExec
|
||||
|
||||
echo Using DSpace installation in: %cd%
|
||||
|
||||
REM Build a CLASSPATH
|
||||
|
||||
set DSPACE_CLASSPATH=%CLASSPATH%;config
|
||||
for %%f in (lib\*.jar) DO CALL bin\buildpath.bat %%f
|
||||
|
||||
REM If JAVA_OPTS specified, use those options
|
||||
REM Otherwise, default Java to using 256MB of memory
|
||||
|
||||
if "%JAVA_OPTS%"=="" set JAVA_OPTS=-Xmx256m
|
||||
|
||||
REM Execute Java
|
||||
|
||||
java %JAVA_OPTS% -classpath "%DSPACE_CLASSPATH%" %*
|
||||
|
||||
|
||||
REM Clean up DSPACE_CLASSPATH variable
|
||||
|
||||
set DSPACE_CLASSPATH=
|
||||
|
||||
|
||||
:end
|
||||
|
||||
REM Back to original dir
|
||||
|
||||
chdir /D %CURRENT_DIR%
|
||||
@call dspace.bat dsrun %*
|
@@ -45,4 +45,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.itemexport.ItemExport $@
|
||||
$BINDIR/dspace export "$@"
|
@@ -46,4 +46,4 @@
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
echo "Applying Media Filters"
|
||||
$BINDIR/dsrun org.dspace.app.mediafilter.MediaFilterManager $@
|
||||
$BINDIR/dspace filter-media "$@"
|
@@ -46,4 +46,4 @@
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
echo "Generating sitemaps"
|
||||
$BINDIR/dsrun org.dspace.app.sitemap.GenerateSitemaps $@
|
||||
$BINDIR/dspace generate-sitemaps "$@"
|
@@ -45,4 +45,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.itemimport.ItemImport $@
|
||||
$BINDIR/dspace import "$@"
|
@@ -45,9 +45,5 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
echo "Creating browse index"
|
||||
$BINDIR/dsrun org.dspace.browse.IndexBrowse -f -r
|
||||
$BINDIR/dsrun org.dspace.browse.ItemCounter
|
||||
|
||||
echo "Creating search index"
|
||||
$BINDIR/dsrun org.dspace.search.DSIndexer -b
|
||||
echo "Creating browse and search indexes"
|
||||
$BINDIR/dspace index-init
|
@@ -45,9 +45,5 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
echo "Creating browse index"
|
||||
$BINDIR/dsrun org.dspace.browse.IndexBrowse -i
|
||||
$BINDIR/dsrun org.dspace.browse.ItemCounter
|
||||
|
||||
echo "Creating search index"
|
||||
$BINDIR/dsrun org.dspace.search.DSIndexer
|
||||
echo "Creating browse and search indexes"
|
||||
$BINDIR/dspace index-update
|
@@ -45,4 +45,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.browse.ItemCounter $@
|
||||
$BINDIR/dspace itemcounter "$@"
|
@@ -45,4 +45,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.bulkedit.MetadataExport $@
|
||||
$BINDIR/dspace metadata-export "$@"
|
@@ -45,4 +45,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.bulkedit.MetadataImport $@
|
||||
$BINDIR/dspace metadata-import "$@"
|
@@ -45,4 +45,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.packager.Packager $@
|
||||
$BINDIR/dspace packager "$@"
|
@@ -46,4 +46,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.statistics.CreateStatReport -r stat-general
|
||||
$BINDIR/dspace stat-general
|
@@ -48,4 +48,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.statistics.CreateStatReport -r stat-initial
|
||||
$BINDIR/dspace stat-initial
|
@@ -47,4 +47,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.statistics.CreateStatReport -r stat-monthly
|
||||
$BINDIR/dspace stat-monthly
|
@@ -46,4 +46,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.statistics.CreateStatReport -r stat-report-general
|
||||
$BINDIR/dspace stat-report-general
|
@@ -48,4 +48,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.statistics.CreateStatReport -r stat-report-initial
|
||||
$BINDIR/dspace stat-report-initial
|
@@ -47,4 +47,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.app.statistics.CreateStatReport -r stat-report-monthly
|
||||
$BINDIR/dspace stat-report-monthly
|
@@ -45,4 +45,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.administer.StructBuilder $@
|
||||
$BINDIR/dspace structure-builder "$@"
|
@@ -46,4 +46,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.eperson.Subscribe $@
|
||||
$BINDIR/dspace sub-daily "$@"
|
@@ -46,4 +46,4 @@
|
||||
# Get the DSPACE/bin directory
|
||||
BINDIR=`dirname $0`
|
||||
|
||||
$BINDIR/dsrun org.dspace.handle.UpdateHandlePrefix $@
|
||||
$BINDIR/dspace update-handle-prefix "$@"
|
@@ -57,7 +57,7 @@ dc.relation.isversionof = <mods:relatedItem type="otherVersion">%s</mods:related
|
||||
dc.relation.replaces = <mods:relatedItem type="preceding">%s</mods:relatedItem> | text()
|
||||
dc.relation.requires = <mods:note type="requires">%s</mods:note> | text()
|
||||
dc.relation.uri = <mods:relatedItem><mods:location><mods:url>%s</mods:url></mods:location></mods:relatedItem> | mods:location/mods:url/text()
|
||||
dc.rights = <mods:accessCondition type="useAndReproducation">%s</mods:accessCondition> | text()
|
||||
dc.rights = <mods:accessCondition type="useAndReproduction">%s</mods:accessCondition> | text()
|
||||
dc.rights.uri = <mods:accessCondition xlink:simpleLink="%s">%s</mods:accessCondition> | @xlink:simpleLink|text()
|
||||
dc.source = <mods:relatedItem type="original">%s</mods:relatedItem> | text()
|
||||
dc.source.uri = <mods:relatedItem type="original" xlink:simpleLink="%s">%s</mods:relatedItem> | @xlink:simpleLink|text()
|
||||
|
@@ -56,7 +56,7 @@ relation.requires = <mods:note type="requires">%s</mods:note>
|
||||
relation.uri = <mods:relatedItem><mods:location><mods:url>%s</mods:url></mods:location></mods:relatedItem>
|
||||
relation = <mods:relatedItem><mods:title>%s</mods:title></mods:relatedItem>
|
||||
rights.uri = <mods:accessCondition xlink:simpleLink="%s">%s</mods:accessCondition>
|
||||
rights = <mods:accessCondition type="useAndReproducation">%s</mods:accessCondition>
|
||||
rights = <mods:accessCondition type="useAndReproduction">%s</mods:accessCondition>
|
||||
source.uri = <mods:relatedItem type="original" xlink:simpleLink="%s">%s</mods:relatedItem>
|
||||
source = <mods:relatedItem type="original">%s</mods:relatedItem>
|
||||
subject.classification = <mods:classification>%s</mods:classification>
|
||||
|
@@ -1959,6 +1959,8 @@ plugin.named.org.dspace.sword.SWORDIngester = \
|
||||
|
||||
# Crosswalk settings; the {name} value must correspond to a declated ingestion crosswalk
|
||||
# harvester.oai.metadataformats.{name} = {namespace},{optional display name}
|
||||
# The display name is only used in the xmlui for the jspui there are entries in the
|
||||
# Messages.properties in the form jsp.tools.edit-collection.form.label21.select.{name}
|
||||
harvester.oai.metadataformats.dc = http://www.openarchives.org/OAI/2.0/oai_dc/, Simple Dublin Core
|
||||
harvester.oai.metadataformats.qdc = http://purl.org/dc/terms/, Qualified Dublin Core
|
||||
harvester.oai.metadataformats.dim = http://www.dspace.org/xmlns/dspace/dim, DSpace Intermediate Metadata
|
||||
@@ -2034,7 +2036,12 @@ harvester.unknownSchema = fail
|
||||
#---------------------------------------------------------------#
|
||||
|
||||
##### Usage Logging #####
|
||||
solr.log.server = ${dspace.baseUrl}/solr/statistics
|
||||
# set this to be the port you run the dspace "solr" webapp
|
||||
# on, by default, we are assuming a test configuration with
|
||||
# tomcat still running on port 8080
|
||||
solr.log.server = http://localhost:8080/solr/statistics
|
||||
|
||||
# The location for the Geo Database retrieved on update/installation
|
||||
solr.dbfile = ${dspace.dir}/config/GeoLiteCity.dat
|
||||
|
||||
# If enabled the statistics system will look for an X-Forward header
|
||||
|
@@ -49,6 +49,22 @@
|
||||
</step>
|
||||
</command>
|
||||
|
||||
<command>
|
||||
<name>dsrun</name>
|
||||
<description>Run a class directly</description>
|
||||
<step>
|
||||
<class>dsrun</class>
|
||||
</step>
|
||||
</command>
|
||||
|
||||
<command>
|
||||
<name>embargo-lifter</name>
|
||||
<description>Embargo manager tool used to check, list and lift embargoes</description>
|
||||
<step>
|
||||
<class>org.dspace.embargo.EmbargoManager</class>
|
||||
</step>
|
||||
</command>
|
||||
|
||||
<command>
|
||||
<name>export</name>
|
||||
<description>Export items or collections</description>
|
||||
@@ -141,7 +157,7 @@
|
||||
<name>itemupdate</name>
|
||||
<description>Item update tool for altering metadata and bitstream content in items</description>
|
||||
<step>
|
||||
<class>org.dspace.app.itemimport.ItemUpdate</class>
|
||||
<class>org.dspace.app.itemupdate.ItemUpdate</class>
|
||||
</step>
|
||||
</command>
|
||||
|
||||
|
@@ -25,7 +25,7 @@
|
||||
<section remap="h3">
|
||||
<title>Themes</title>
|
||||
<para>A Theme is a collection of XSL stylesheets and supporting files like images, CSS styles, translations, and help documents. The XSL stylesheets are applied to the DRI Document to covert it into a readable format and give it structure and basic visual formatting in that format. The supporting files are used to provide the page with a specific look and feel, insert images and other media, translate the content, and perform other tasks. The currently used output format is XHTML and the supporting files are generally limited to CSS, images, and JavaScript. More output formats, like PDF or SVG, may be added in the future.</para>
|
||||
<para>A DSpace installation running Manakin may have several Themes associated with it. When applied to a page, a Theme determines most of the pageís look and feel. Different themes can be applied to different sets of DSpace pages allowing for both variety of styles between sets of pages and consistency within those sets. The xmlui.xconf configuration file determines which Themes are applied to which DSpace pages (see the <link linkend="docbook-configure.html-xmlui-configure">Configuration and Customization chapter</link> for more information on installing and configuring themes). Themes may be configured to apply to all pages of specific type, like browse-by-title, to all pages of a one particular community or collection or sets of communities and collections, and to any mix of the two. They can also be configured to apply to a singe arbitrary page or handle.</para>
|
||||
<para>A DSpace installation running Manakin may have several Themes associated with it. When applied to a page, a Theme determines most of the pageís look and feel. Different themes can be applied to different sets of DSpace pages allowing for both variety of styles between sets of pages and consistency within those sets. The xmlui.xconf configuration file determines which Themes are applied to which DSpace pages (see the <link linkend="docbook-xmlui.html">Chapter 7. Manakin [XMLUI] Configuration and Customization</link> for more information on installing and configuring themes). Themes may be configured to apply to all pages of specific type, like browse-by-title, to all pages of a one particular community or collection or sets of communities and collections, and to any mix of the two. They can also be configured to apply to a singe arbitrary page or handle.</para>
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title>Aspect Chains</title>
|
||||
|
@@ -1,5 +1,5 @@
|
||||
<?xml version='1.0' encoding='UTF-8'?>
|
||||
<chapter remap="h1">
|
||||
<chapter remap="h1">
|
||||
<title><anchor id="docbook-architecture.html"/>DSpace System Documentation: Architecture</title>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-architecture.html-overview" xreflabel="Overview"/>Overview</title>
|
||||
|
@@ -22,19 +22,19 @@
|
||||
<book>
|
||||
<bookinfo>
|
||||
<title>DSpace Manual</title>
|
||||
<subtitle>Release 1.6.0</subtitle>
|
||||
<subtitle>Release 1.6.1</subtitle>
|
||||
<author>
|
||||
<surname>The DuraSpace Foundation</surname>
|
||||
<surname>DuraSpace</surname>
|
||||
<affiliation>
|
||||
<address><email>webmaster@dspace.org</email></address>
|
||||
</affiliation>
|
||||
</author>
|
||||
<edition>1.6.0</edition>
|
||||
<pubdate>2010-03-02 11:45:00 EST</pubdate>
|
||||
<edition>1.6.1</edition>
|
||||
<pubdate>2010-05-21 12:00:00 EST</pubdate>
|
||||
<copyright>
|
||||
<year>2002-2010</year>
|
||||
<holder>
|
||||
<ulink url="http://www.duraspace.org/">The DuraSpace Foundation</ulink>
|
||||
<ulink url="http://www.duraspace.org/">DuraSpace</ulink>
|
||||
</holder>
|
||||
</copyright>
|
||||
<legalnotice>
|
||||
@@ -51,8 +51,8 @@
|
||||
</legalnotice>
|
||||
<revhistory>
|
||||
<revision>
|
||||
<revnumber>Version 1.6.0 </revnumber>
|
||||
<date>This text generated: 2010-03-02 11:45:00 EST EST</date>
|
||||
<revnumber>Version 1.6.1 </revnumber>
|
||||
<date>This text generated: 2010-05-21 12:00:00 EST EST</date>
|
||||
<authorinitials>JAT</authorinitials>
|
||||
</revision>
|
||||
</revhistory>
|
||||
@@ -63,8 +63,8 @@
|
||||
<preface>
|
||||
<title>Preface</title>
|
||||
<para/>
|
||||
<para>Welcome to Release 1.6.0. The committers have volunteered many hours to fix, re-write and contribute new software code for this release. New features have been added and documentation has been updated.</para>
|
||||
<para>Some of the new features include (not an exhaustive list):</para>
|
||||
<para>Welcome to Release 1.6.1. This is a "fix" release. The committers have volunteered many hours to fix, re-write and contribute new software code for this release. Documentation has been updated. No new features have been added to this release.</para>
|
||||
<para>The following is a list of the new features included (not an exhaustive list) for release 1.6.0 and are also contained in 1.6.1:</para>
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>SOLR Statistics.</para>
|
||||
@@ -91,10 +91,11 @@
|
||||
<para>Delegated Administration</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
<para>The following people have contributed to this release of DSpace: @mire, BioMed Central, Andrea Bollini, Ben Bosman, Flavio Botelho, Peter Dietz, Mark Diggory, Tim Donohue, Enovation Solutions, Ladd Hanson, Leonie Hayes, Claudia Juergen, Keller, Fabio Kepler, Yin Yin Latt, Stuart Lewis, Bram Luyten, Van Ly, Alexey Maslov, Gabriela Mircea, Hardik Mishra, Venessa Newton-Wade, OhioLINK, Ekaterina Pechekhonova, Toni Prieto, Richard Rodgers, Ricardo Saraiva, Andreas Schwander, Kim Shepherd, Elin Stangeland, Larry Stone, Graham Triggs, Jeffrey Trimble, Kevin Van de velde, Steve Williams and Mark Wood. Many of them could not do this work without the support (release time and financial) of their institutions that they are associated with. We offer thanks to those institutions for supporting their staff to take time to contribute to the DSpace project.</para>
|
||||
<para>Documentation for this release was overhauled by Jeffrey Trimble, the Documentation Gardener, with many other contributing suggestions, changes, edits, and additions. Special thanks to Bram Luyten for pulling his hair out for re-ordering Chapter 5 to match the order of the <literal>dspace.cfg</literal> file and for the Documentation Gardener who is still picking his own hair up from that re-ordering.</para>
|
||||
<para>Stuart Lewis is the Release Co-ordinator and kept all of the committers inline and fixed things when broken. Many thanks Stuart.</para>
|
||||
<para>Additional thanks to Tim Donohue from DuraSpace Foundation on keeping all of us focused on the work at hand, and calming us when we got excited and for the general support for the DSpace project.</para>
|
||||
<para>The following people have contributed to this release of DSpace: @mire, BioMed Central, Andrea Bollini, Ben Bosman, Flavio Botelho, Peter Dietz, Mark Diggory, Tim Donohue, Serhij Dubyk, Enovation Solutions, Javier Garrido, Keith Gilbertson, Ladd Hanson, Leonie Hayes, Paulo Jobim, Claudia Juergen, Keller, Fabio Kepler, Yin Yin Latt, Stuart Lewis, Bram Luyten, Van Ly, Ivan Masar, Alexey Maslov, Gabriela Mircea, Hardik Mishra, Caryn, Neiswender, Venessa Newton-Wade, OhioLINK, Ekaterina Pechekhonova, Dale Poulter, Toni Prieto, Richard Rodgers, Ricardo Saraiva, Andreas Schwander, Kim Shepherd, Elin Stangeland, Larry Stone, Keiji Suzuki, Robin Taylor, Graham Triggs, Jeffrey Trimble, Kevin Van de velde, Steve Williams and Mark Wood. Many of them could not do this work without the support (release time and financial) of their institutions that they are associated with. We offer thanks to those institutions for supporting their staff to take time to contribute to the DSpace project.</para>
|
||||
<para>We apologize to any committer left off this list. DSpace has such a large, arctive development community that we sometimes loose track of all our contributors. Our ongoing list of all known people/institutions that contribute to DSpace can be found on our DSpace Contributors Wiki page (http://wiki.dspace.org/confluence/display/DSPACE/DSpaceContributors). Acknowledgements to those left off will be made in future releases.</para>
|
||||
<para>The Documentation Gardener for this release was Jeffrey Trimble with input from everyone. All typos are his fault. </para>
|
||||
<para>Kim Shepherd is the Release Co-ordinator of this release.</para>
|
||||
<para>Additional thanks to Tim Donohue from DuraSpace on keeping all of us focused on the work at hand, and calming us when we got excited and for the general support for the DSpace project.</para>
|
||||
</preface>
|
||||
<toc/>
|
||||
&art01;
|
||||
|
@@ -40,7 +40,7 @@
|
||||
<para> A cache of content management API objects. Each time a content object is created (for example <literal>Item</literal> or <literal>Bitstream</literal>) it is stored in the <literal>Context</literal> object. If the object is then requested again, the cached copy is used. Apart from reducing database use, this addresses the problem of having two copies of the same object in memory in different states.</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
<para>The following information is also held in a context object, though it is the responsiblity of the application creating the context object to fill it out correctly:</para>
|
||||
<para>The following information is also held in a context object, though it is the responsibility of the application creating the context object to fill it out correctly:</para>
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para> The current authenticated user, if any</para>
|
||||
@@ -49,7 +49,7 @@
|
||||
<para> Any 'special groups' the user is a member of. For example, a user might automatically be part of a particular group based on the IP address they are accessing DSpace from, even though they don't have an e-person record. Such a group is called a 'special group'.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para> Any extra information from the application layer that should be added to log messages that are written within this context. For example, the Web UI adds a session ID, so that when the logs are analysed the actions of a particular user in a particular session can be tracked.</para>
|
||||
<para> Any extra information from the application layer that should be added to log messages that are written within this context. For example, the Web UI adds a session ID, so that when the logs are analyzed the actions of a particular user in a particular session can be tracked.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para> A flag indicating whether authorization should be circumvented. This should only be used in rare, specific circumstances. For example, when first installing the system, there are no authorized administrators who would be able to create an administrator account!</para>
|
||||
@@ -191,13 +191,13 @@
|
||||
</tbody>
|
||||
</tgroup>
|
||||
</informaltable>
|
||||
<para>The above format allows the logs to be easily parsed and analysed. The <literal>/dspace/bin/log-reporter</literal> script is a simple tool for analysing logs. Try:</para>
|
||||
<para>The above format allows the logs to be easily parsed and analyzed. The <literal>/dspace/bin/log-reporter</literal> script is a simple tool for analyzing logs. Try:</para>
|
||||
<para><literal>/dspace/bin/log-reporter --help</literal></para>
|
||||
<para>It's a good idea to 'nice' this log reporter to avoid an impact on server performance.</para>
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title>Utils</title>
|
||||
<para><literal>Utils</literal> comtains miscellaneous utility method that are required in a variety of places throughout the code, and thus have no particular 'home' in a subsystem.</para>
|
||||
<para><literal>Utils</literal> contains miscellaneous utility method that are required in a variety of places throughout the code, and thus have no particular 'home' in a subsystem.</para>
|
||||
</section>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
@@ -312,14 +312,14 @@ context.complete();</screen>
|
||||
<para>Instantiating a <literal>Bundle</literal> object causes the appropriate <literal>Bitstream</literal> objects (and hence <literal>BitstreamFormat</literal>s) to be instantiated.</para>
|
||||
<para>Instantiating an <literal>Item</literal> object causes the appropriate <literal>Bundle</literal> objects (etc.) and hence <literal>BitstreamFormat</literal>s to be instantiated. All the Dublin Core metadata associated with that item are also loaded into memory.</para>
|
||||
<para>The reasoning behind this is that for the vast majority of cases, anyone instantiating an item object is going to need information about the bundles and bitstreams within it, and this methodology allows that to be done in the most efficient way and is simple for the caller. For example, in the Web UI, the servlet (controller) needs to pass information about an item to the viewer (JSP), which needs to have all the information in-memory to display the item without further accesses to the database which may cause errors mid-display.</para>
|
||||
<para>You do not need to worry about multiple in-memory instantiations of the same object, or any inconsistenties that may result; the <literal>Context</literal> object keeps a cache of the instantiated objects. The <literal>find</literal> methods of classes in <literal>org.dspace.content</literal> will use a cached object if one exists.</para>
|
||||
<para>You do not need to worry about multiple in-memory instantiations of the same object, or any inconsistencies that may result; the <literal>Context</literal> object keeps a cache of the instantiated objects. The <literal>find</literal> methods of classes in <literal>org.dspace.content</literal> will use a cached object if one exists.</para>
|
||||
<para>It may be that in enough cases this automatic instantiation of contained objects reduces performance in situations where it is important; if this proves to be true the API may be changed in the future to include a <literal>loadContents</literal> method or somesuch, or perhaps a Boolean parameter indicating what to do will be added to the <literal>find</literal> methods.</para>
|
||||
<para>When a <literal>Context</literal> object is completed, aborted or garbage-collected, any objects instantiated using that context are invalidated and should not be used (in much the same way an AWT button is invalid if the window containing it is destroyed).</para>
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title><anchor id="docbook-business.html-dublincore" xreflabel="Dublin Core Metadata"/>Dublin Core Metadata</title>
|
||||
<para>The <literal>DCValue</literal> class is a simple container that represents a single Dublin Core element, optional qualifier, value and language. Note that since DSpace 1.4 the <literal>MetadataValue</literal> and associated classes are preferred (see <link linkend="docbook-business.html-otherschemas">Support for Other Metadata Schemas</link>). The other classes starting with <literal
|
||||
>DC</literal> are utility classes for handling types of data in Dublin Core, such as people's names and dates. As supplied, the DSpace registry of elements and qualifiers corresponds to the <ulink url="http://www.dublincore.org/documents/2002/09/24/library-application-profile/"
|
||||
<para>The <literal>DCValue</literal> class is a simple container that represents a single Dublin Core element, optional qualifier, value and language. Note that since DSpace 1.4 the <literal>MetadataValue</literal> and associated classes are preferred (see <link linkend="docbook-business.html-otherschemas"
|
||||
>Support for Other Metadata Schemas</link>). The other classes starting with <literal>DC</literal> are utility classes for handling types of data in Dublin Core, such as people's names and dates. As supplied, the DSpace registry of elements and qualifiers corresponds to the <ulink url="http://www.dublincore.org/documents/2002/09/24/library-application-profile/"
|
||||
>Library Application Profile</ulink> for Dublin Core. It should be noted that these utility classes assume that the values will be in a certain syntax, which will be true for all data generated within the DSpace system, but since Dublin Core does not always define strict syntax, this may not be true for Dublin Core originating outside DSpace.</para>
|
||||
<para>Below is the specific syntax that DSpace expects various fields to adhere to:</para>
|
||||
<informaltable frame="none">
|
||||
@@ -434,7 +434,7 @@ context.complete();</screen>
|
||||
<section remap="h3">
|
||||
<title><anchor id="docbook-business.html-otherschemas" xreflabel="Support for Other Metadata
|
||||
Schemas"/>Support for Other Metadata Schemas</title>
|
||||
<para>To support additional metadata schemas a new set of metadata classes have been added. These are backwards compatible with the DC classes and should be used rather than the DC specific classes whereever possible. Note that hierarchical metadata schemas are not currently supported, only flat schemas (such as DC) are able to be defined.</para>
|
||||
<para>To support additional metadata schemas a new set of metadata classes have been added. These are backwards compatible with the DC classes and should be used rather than the DC specific classes wherever possible. Note that hierarchical metadata schemas are not currently supported, only flat schemas (such as DC) are able to be defined.</para>
|
||||
<para>The <literal>MetadataField</literal> class describes a metadata field by schema, element and optional qualifier. The value of a <literal>MetadataField</literal> is described by a <literal>MetadataValue</literal> which is roughly equivalent to the older <literal>DCValue</literal> class. Finally the <literal>MetadataSchema</literal> class is used to describe supported schemas. The DC schema is supported by default. Refer to the javadoc for method details.</para>
|
||||
</section>
|
||||
<section remap="h3">
|
||||
@@ -476,7 +476,7 @@ Schemas"/>Support for Other Metadata Schemas</title>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-business.html-plugin" xreflabel="Plugin Manager"/>Plugin Manager</title>
|
||||
<para>The PluginManager is a very simple component container. It creates and organizes components (plugins), and helps select a plugin in the cases where there are many possible choices. It also gives some limited control over the lifecycle of a plugin.</para>
|
||||
<para>The PluginManager is a very simple component container. It creates and organizes components (plugins), and helps select a plugin in the cases where there are many possible choices. It also gives some limited control over the life cycle of a plugin.</para>
|
||||
<section remap="h3">
|
||||
<title>Concepts</title>
|
||||
<para>The following terms are important in understanding the rest of this section:</para>
|
||||
@@ -666,7 +666,7 @@ Schemas"/>Support for Other Metadata Schemas</title>
|
||||
<para>
|
||||
<literal>plugin.named.interface = classname = name [ , name.. ] [ classname = name.. ]</literal>
|
||||
</para>
|
||||
<para>The syntax of the configuration value is: classname, followed by an equal-sign and then at least one plugin name. Bind more names to the same implementation class by by adding them here, separated by commas. Names may include any character other than comma (,) and equal-sign (=).</para>
|
||||
<para>The syntax of the configuration value is: classname, followed by an equal-sign and then at least one plugin name. Bind more names to the same implementation class by adding them here, separated by commas. Names may include any character other than comma (,) and equal-sign (=).</para>
|
||||
<para>For example, this entry creates one plugin with the names GIF, JPEG, and image/png, and another with the name TeX:</para>
|
||||
<screen>plugin.named.org.dspace.app.mediafilter.MediaFilter = \
|
||||
org.dspace.app.mediafilter.JPEGFilter = GIF, JPEG, image/png \
|
||||
@@ -710,7 +710,7 @@ plugin.selfnamed.crosswalk.org.dspace.content.metadata.DisseminationCrosswalk =
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title><anchor id="docbook-business.html-confval" xreflabel="Validating the Configuration"/>Validating the Configuration</title>
|
||||
<para>The Plugin Manager is very sensitive to mistakes in the DSpace configuration. Subtle errors can have unexpected consequnces that are hard to detect: for example, if there are two "plugin.single" entries for the same interface, one of them will be silently ignored.</para>
|
||||
<para>The Plugin Manager is very sensitive to mistakes in the DSpace configuration. Subtle errors can have unexpected consequences that are hard to detect: for example, if there are two "plugin.single" entries for the same interface, one of them will be silently ignored.</para>
|
||||
<para>To validate the Plugin Manager configuration, call the <literal>PluginManager.checkConfiguration()</literal> method. It looks for the following mistakes:</para>
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
@@ -897,14 +897,14 @@ plugin.selfnamed.org.dspace.content.metadata.DisseminationCrosswalk = \
|
||||
<para>The <literal>org.dspace.administer</literal> package contains some classes for administering a DSpace system that are not generally needed by most applications.</para>
|
||||
<para>The <literal>CreateAdministrator</literal> class is a simple command-line tool, executed via <literal>/dspace/bin/create-administrator</literal>, that creates an administrator e-person with information entered from standard input. This is generally used only once when a DSpace system is initially installed, to create an initial administrator who can then use the Web administration UI to further set up the system. This script does not check for authorization, since it is typically run before there are any e-people to authorize! Since it must be run as a command-line tool on the server machine, generally this shouldn't cause a problem. A possibility is to have the script only operate when there are no e-people in the system already, though in general, someone with access to command-line scripts on your server is probably in a position to do what they want anyway!</para>
|
||||
<para>The <literal>DCType</literal> class is similar to the <literal>org.dspace.content.BitstreamFormat</literal> class. It represents an entry in the Dublin Core type registry, that is, a particular element and qualifier, or unqualified element. It is in the <literal>administer</literal> package because it is only generally required when manipulating the registry itself. Elements and qualifiers are specified as literals in <literal>org.dspace.content.Item</literal> methods and the <literal>org.dspace.content.DCValue</literal> class. Only administrators may modify the Dublin Core type registry.</para>
|
||||
<para>The <literal>org.dspace.administer.RegistryLoader</literal> class contains methods for initialising the Dublin Core type registry and bitstream format registry with entries in an XML file. Typically this is executed via the command line during the build process (see <literal>build.xml</literal> in the source.) To see examples of the XML formats, see the files in <literal>config/registries</literal> in the source directory. There is no XML schema, they aren't validated strictly when loaded in.</para>
|
||||
<para>The <literal>org.dspace.administer.RegistryLoader</literal> class contains methods for initializing the Dublin Core type registry and bitstream format registry with entries in an XML file. Typically this is executed via the command line during the build process (see <literal>build.xml</literal> in the source.) To see examples of the XML formats, see the files in <literal>config/registries</literal> in the source directory. There is no XML schema, they aren't validated strictly when loaded in.</para>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-business.html-eperson" xreflabel="E-person/Group Manager"/>E-person/Group Manager</title>
|
||||
<para>DSpace keeps track of registered users with the <literal>org.dspace.eperson.EPerson</literal> class. The class has methods to create and manipulate an <literal>EPerson</literal> such as get and set methods for first and last names, email, and password. (Actually, there is no <literal>getPassword()</literal> method--an MD5 hash of the password is stored, and can only be verified with the <literal>checkPassword()</literal> method.) There are find methods to find an EPerson by email (which is assumed to be unique,) or to find all EPeople in the system.</para>
|
||||
<para>DSpace keeps track of registered users with the <literal>org.dspace.eperson.EPerson</literal> class. The class has methods to create and manipulate an <literal>EPerson</literal> such as get and set methods for first and last names, email, and password. (Actually, there is no <literal>getPassword()</literal> method—an MD5 hash of the password is stored, and can only be verified with the <literal>checkPassword()</literal> method.) There are find methods to find an EPerson by email (which is assumed to be unique,) or to find all EPeople in the system.</para>
|
||||
<para>The <literal>EPerson</literal> object should probably be reworked to allow for easy expansion; the current EPerson object tracks pretty much only what MIT was interested in tracking - first and last names, email, phone. The access methods are hardcoded and should probably be replaced with methods to access arbitrary name/value pairs for institutions that wish to customize what EPerson information is stored.</para>
|
||||
<para>Groups are simply lists of <literal>EPerson</literal> objects. Other than membership, <literal>Group</literal> objects have only one other attribute: a name. Group names must be unique, so we have adopted naming conventions where the role of the group is its name, such as <literal>COLLECTION_100_ADD</literal>. Groups add and remove EPerson objects with <literal>addMember()</literal> and <literal>removeMember()</literal> methods. One important thing to know about groups is that they store their membership in memory until the <literal>update()</literal> method is called - so when modifying a group's membership don't forget to invoke <literal>update()</literal> or your changes will be lost! Since group membership is used heavily by the authorization system a fast <literal>isMember()</literal> method is also provided.</para>
|
||||
<para>Another kind of Group is also implemented in DSpace--special Groups. The <literal>Context</literal> object for each session carries around a List of Group IDs that the user is also a member of--currently the MITUser Group ID is added to the list of a user's special groups if certain IP address or certificate criteria are met.</para>
|
||||
<para>Another kind of Group is also implemented in DSpace—special Groups. The <literal>Context</literal> object for each session carries around a List of Group IDs that the user is also a member of—currently the MITUser Group ID is added to the list of a user's special groups if certain IP address or certificate criteria are met.</para>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-business.html-authorize" xreflabel="Authorization"/>Authorization</title>
|
||||
@@ -948,7 +948,7 @@ plugin.selfnamed.org.dspace.content.metadata.DisseminationCrosswalk = \
|
||||
</tgroup>
|
||||
</informaltable>
|
||||
<para>The authorization system is based on the classic 'police state' model of security; no action is allowed unless it is expressed in a policy. The policies are attached to resources (hence the name <literal>ResourcePolicy</literal>,) and detail who can perform that action. The resource can be any of the DSpace object types, listed in <literal>org.dspace.core.Constants</literal> (<literal>BITSTREAM</literal>, <literal>ITEM</literal>, <literal>COLLECTION</literal>, etc.) The 'who' is made up of EPerson groups. The actions are also in <literal>Constants.java</literal> (<literal>READ</literal>, <literal>WRITE</literal>, <literal>ADD</literal>, etc.) The only non-obvious actions are <literal>ADD</literal> and <literal>REMOVE</literal>, which are authorizations for container objects. To be able to create an Item, you must have <literal>ADD</literal> permission in a Collection, which contains Items. (Communities, Collections, Items, and Bundles are all container objects.)</para>
|
||||
<para>Currently most of the read policy checking is done with items--communities and collections are assumed to be openly readable, but items and their bitstreams are checked. Separate policy checks for items and their bitstreams enables policies that allow publicly readable items, but parts of their content may be restricted to certain groups.</para>
|
||||
<para>Currently most of the read policy checking is done with items—communities and collections are assumed to be openly readable, but items and their bitstreams are checked. Separate policy checks for items and their bitstreams enables policies that allow publicly readable items, but parts of their content may be restricted to certain groups.</para>
|
||||
<para>The <literal>AuthorizeManager</literal> class'
|
||||
<literal>authorizeAction(Context, object, action)</literal> is the primary source of all authorization in the system. It gets a list of all of the ResourcePolicies in the system that match the object and action. It then iterates through the policies, extracting the EPerson Group from each policy, and checks to see if the EPersonID from the Context is a member of any of those groups. If all of the policies are queried and no permission is found, then an <literal>AuthorizeException</literal> is thrown. An <literal>authorizeAction()</literal> method is also supplied that returns a boolean for applications that require higher performance.</para>
|
||||
<para>ResourcePolicies are very simple, and there are quite a lot of them. Each can only list a single group, a single action, and a single object. So each object will likely have several policies, and if multiple groups share permissions for actions on an object, each group will get its own policy. (It's a good thing they're small.)</para>
|
||||
@@ -958,7 +958,7 @@ plugin.selfnamed.org.dspace.content.metadata.DisseminationCrosswalk = \
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title>Miscellaneous Authorization Notes</title>
|
||||
<para>Where do items get their read policies? From the their collection's read policy. There once was a separate item read default policy in each collection, and perhaps there will be again since it appears that administrators are notoriously bad at defining collection's read policies. There is also code in place to enable policies that are timed--have a start and end date. However, the admin tools to enable these sorts of policies have not been written.</para>
|
||||
<para>Where do items get their read policies? From the their collection's read policy. There once was a separate item read default policy in each collection, and perhaps there will be again since it appears that administrators are notoriously bad at defining collection's read policies. There is also code in place to enable policies that are timed—have a start and end date. However, the admin tools to enable these sorts of policies have not been written.</para>
|
||||
</section>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
@@ -993,13 +993,13 @@ http://hdl.handle.net/1721.123/4567</screen>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-business.html-search" xreflabel="Search"/>Search</title>
|
||||
<para>DSpace's search code is a simple API which currently wraps the Lucene search engine. The first half of the search task is indexing, and <literal>org.dspace.search.DSIndexer</literal> is the indexing class, which contains <literal>indexContent()</literal> which if passed an <literal>Item</literal>, <literal>Community</literal>, or <literal>Collection</literal>, will add that content's fields to the index. The methods <literal>unIndexContent()</literal> and <literal>reIndexContent()</literal> remove and update content's index information. The <literal>DSIndexer</literal> class also has a <literal>main()</literal> method which will rebuild the index completely. This can be invoked by the <literal>dspace/bin/index-init</literal> (complete rebuild) or <literal>dspace/bin/index-update</literal> (update) script. The intent was for the <literal>main()</literal> method to be invoked on a regular basis to avoid index corruption, but we have had no problem with that so far.</para>
|
||||
<para>Which fields are indexed by <literal>DSIndexer</literal>? These fields are defined in dspace.cfg in the section "Fields to index for search" as name-value-pairs. The name must be unique in the form search.index.i (i is an arbitrary positive number). The value on the right side has a unique value again, which can be referenced in search-form (e.g. title, author). Then comes the metadata element which is indexed. '*' is a wildcard which includes all subelements. For example:</para>
|
||||
<para>Which fields are indexed by <literal>DSIndexer</literal>? These fields are defined in dspace.cfg in the section "Fields to index for search" as name-value-pairs. The name must be unique in the form search.index.i (i is an arbitrary positive number). The value on the right side has a unique value again, which can be referenced in search-form (e.g. title, author). Then comes the metadata element which is indexed. '*' is a wildcard which includes all sub elements. For example:</para>
|
||||
<para>
|
||||
<literal>search.index.4 = keyword:dc.subject.*</literal>
|
||||
</para>
|
||||
<para>tells the indexer to create a keyword index containing all dc.subject element values. Since the wildcard ('*') character was used in place of a qualifier, all subject metadata fields will be indexed (e.g. dc.subject.other, dc.subject.lcsh, etc)</para>
|
||||
<para>By default, the fields shown in the <literal>Indexed Fields</literal> section below are indexed. These are hardcoded in the DSIndexer class. If any search.index.i items are specified in <literal>dspace.cfg</literal> these are used rather than these hardcoded fields.</para>
|
||||
<para>The query class <literal>DSQuery</literal> contains the three flavors of <literal>doQuery()</literal> methods--one searches the DSpace site, and the other two restrict searches to Collections and Communities. The results from a query are returned as three lists of handles; each list represents a type of result. One list is a list of Items with matches, and the other two are Collections and Communities that match. This separation allows the UI to handle the types of results gracefully without resolving all of the handles first to see what kind of content the handle points to. The <literal>DSQuery</literal> class also has a <literal>main()</literal> method for debugging via command-line searches.</para>
|
||||
<para>The query class <literal>DSQuery</literal> contains the three flavors of <literal>doQuery()</literal> methods—one searches the DSpace site, and the other two restrict searches to Collections and Communities. The results from a query are returned as three lists of handles; each list represents a type of result. One list is a list of Items with matches, and the other two are Collections and Communities that match. This separation allows the UI to handle the types of results gracefully without resolving all of the handles first to see what kind of content the handle points to. The <literal>DSQuery</literal> class also has a <literal>main()</literal> method for debugging via command-line searches.</para>
|
||||
<section remap="h3">
|
||||
<title>Current Lucene Implementation</title>
|
||||
<para>Currently we have our own Analyzer and Tokenizer classes (<literal>DSAnalyzer</literal> and <literal>DSTokenizer</literal>) to customize our indexing. They invoke the stemming and stop word features within Lucene. We create an <literal>IndexReader</literal> for each query, which we now realize isn't the most efficient use of resources - we seem to run out of filehandles on really heavy loads. (A wildcard query can open many filehandles!) Since Lucene is thread-safe, a better future implementation would be to have a single Lucene IndexReader shared by all queries, and then is invalidated and re-opened when the index changes. Future API growth could include relevance scores (Lucene generates them, but we ignore them,) and abstractions for more advanced search concepts such as booleans.</para>
|
||||
@@ -1127,7 +1127,7 @@ http://hdl.handle.net/1721.123/4567</screen>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-business.html-browse" xreflabel="Browse API"/>Browse API</title>
|
||||
<para>The browse API maintains indices of dates, authors, titles and subjects, and allows callers to extract parts of these:</para>
|
||||
<para>The browse API maintains indexes of dates, authors, titles and subjects, and allows callers to extract parts of these:</para>
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<term><emphasis role="bold">Title</emphasis></term>
|
||||
@@ -1155,7 +1155,7 @@ Doe, John S.</screen>
|
||||
<para> Another issue is that two authors may have the same name, even within a single institution. If this is the case they may appear as one author in the index.</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
<para>These issues are typically resolved in libraries with <emphasis>authority control records</emphasis>, in which are kept a 'preferred' form of the author's name, with extra information (such as date of birth/death) in order to distinguish between authors of the same name. Maintaining such records is a huge task with many issues, particularly when metadata is received from faculty directly rather than trained library cataloguers. For these reasons, DSpace does not yet feature 'authority control' functionality.</para>
|
||||
<para>These issues are typically resolved in libraries with <emphasis>authority control records</emphasis>, in which are kept a 'preferred' form of the author's name, with extra information (such as date of birth/death) in order to distinguish between authors of the same name. Maintaining such records is a huge task with many issues, particularly when metadata is received from faculty directly rather than trained library catalogers. For these reasons, DSpace does not yet feature 'authority control' functionality.</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
<varlistentry>
|
||||
@@ -1183,7 +1183,7 @@ Doe, John S.</screen>
|
||||
<term><emphasis role="bold">Items by a Particular Author</emphasis></term>
|
||||
<listitem>
|
||||
<para> The browse API can perform is to extract items by a particular author. They do not have to be primary author of an item for that item to be extracted. You can specify a scope, too; that is, you can ask for items by author X in collection Y, for example.</para>
|
||||
<para>This particular flavour of browse is slightly simpler than the others. You cannot presently specify a particular subset of results to be returned. The API call will simply return all of the items by a particular author within a certain scope.</para>
|
||||
<para>This particular flavor of browse is slightly simpler than the others. You cannot presently specify a particular subset of results to be returned. The API call will simply return all of the items by a particular author within a certain scope.</para>
|
||||
<para>Note that the author of the item must <emphasis>exactly</emphasis> match the author passed in to the API; see the explanation about the caveats of the author index browsing to see why this is the case.</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
@@ -1196,7 +1196,7 @@ Doe, John S.</screen>
|
||||
</variablelist>
|
||||
<section remap="h3">
|
||||
<title>Using the API</title>
|
||||
<para>The API is generally invoked by creating a <literal>BrowseScope</literal> object, and setting the parameters for which particular part of an index you want to extract. This is then passed to the relevent <literal>Browse</literal> method call, which returns a <literal>BrowseInfo</literal> object which contains the results of the operation. The parameters set in the <literal>BrowseScope</literal> object are:</para>
|
||||
<para>The API is generally invoked by creating a <literal>BrowseScope</literal> object, and setting the parameters for which particular part of an index you want to extract. This is then passed to the relevant <literal>Browse</literal> method call, which returns a <literal>BrowseInfo</literal> object which contains the results of the operation. The parameters set in the <literal>BrowseScope</literal> object are:</para>
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>How many entries from the index you want</para>
|
||||
@@ -1237,28 +1237,28 @@ FOCUS> The Really Exciting Research Video
|
||||
<para>Note that in the case of title and date browses, <literal>Item</literal> objects are returned as opposed to actual titles. In these cases, you can specify the 'focus' to be a specific item, or a partial or full literal value. In the case of a literal value, if no entry in the index matches exactly, the closest match is used as the focus. It's quite reasonable to specify a focus of a single letter, for example.</para>
|
||||
<para>Being able to specify a specific item to start at is particularly important with dates, since many items may have the save issue date. Say 30 items in a collection have the issue date 2002. To be able to page through the index 20 items at a time, you need to be able to specify exactly which item's 2002 is the focus of the browse, otherwise each time you invoked the browse code, the results would start at the first item with the issue date 2002.</para>
|
||||
<para>Author browses return <literal>String</literal> objects with the actual author names. You can only specify the focus as a full or partial literal <literal>String</literal>.</para>
|
||||
<para>Another important point to note is that presently, the browse indices contain metadata for all items in the main archive, regardless of authorization policies. This means that all items in the archive will appear to all users when browsing. Of course, should the user attempt to access a non-public item, the usual authorization mechanism will apply. Whether this approach is ideal is under review; implementing the browse API such that the results retrieved reflect a user's level of authorization may be possible, but rather tricky.</para>
|
||||
<para>Another important point to note is that presently, the browse indexes contain metadata for all items in the main archive, regardless of authorization policies. This means that all items in the archive will appear to all users when browsing. Of course, should the user attempt to access a non-public item, the usual authorization mechanism will apply. Whether this approach is ideal is under review; implementing the browse API such that the results retrieved reflect a user's level of authorization may be possible, but rather tricky.</para>
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title>Index Maintenance</title>
|
||||
<para>The browse API contains calls to add and remove items from the index, and to regenerate the indices from scratch. In general the content management API invokes the necessary browse API calls to keep the browse indices in sync with what is in the archive, so most applications will not need to invoke those methods.</para>
|
||||
<para>The browse API contains calls to add and remove items from the index, and to regenerate the indexes from scratch. In general the content management API invokes the necessary browse API calls to keep the browse indexes in sync with what is in the archive, so most applications will not need to invoke those methods.</para>
|
||||
<para>If the browse index becomes inconsistent for some reason, the <literal>InitializeBrowse</literal> class is a command line tool (generally invoked using the <literal>/dspace/bin/dspace index-init</literal> command) that causes the indexes to be regenerated from scratch.</para>
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title>Caveats</title>
|
||||
<para>Presently, the browse API is not tremendously efficient. 'Indexing' takes the form of simply extracting the relevant Dublin Core value, normalising it (lower-casing and removing any leading article in the case of titles), and inserting that normalized value with the corresponding item ID in the appropriate browse database table. Database views of this table include collection and community IDs for browse operations with a limited scope. When a browse operation is performed, a simple <literal>SELECT</literal> query is performed, along the lines of:</para>
|
||||
<para>Presently, the browse API is not tremendously efficient. 'Indexing' takes the form of simply extracting the relevant Dublin Core value, normalizing it (lower-casing and removing any leading article in the case of titles), and inserting that normalized value with the corresponding item ID in the appropriate browse database table. Database views of this table include collection and community IDs for browse operations with a limited scope. When a browse operation is performed, a simple <literal>SELECT</literal> query is performed, along the lines of:</para>
|
||||
<screen>SELECT item_id FROM ItemsByTitle ORDER BY sort_title OFFSET 40 LIMIT 20</screen>
|
||||
<para>There are two main drawbacks to this: Firstly, <literal>LIMIT</literal> and <literal>OFFSET</literal> are PostgreSQL-specific keywords. Secondly, the database is still actually performing dynamic sorting of the titles, so the browse code as it stands will not scale particularly well. The code does cache <literal>BrowseInfo</literal> objects, so that common browse operations are performed quickly, but this is not an ideal solution.</para>
|
||||
</section>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-business.html-checker" xreflabel="Checksum checker"/>Checksum checker</title>
|
||||
<para>Checksum checker is used to verify every item within DSpace. While DSpace calculates and records the checksum of every file submitted to it, the checker can determine whterh the file has been changed. The idea being that the earlier you can identify a file has changed, the more likely you would be able to record it (assuming it was not a wanted change).</para>
|
||||
<para>Checksum checker is used to verify every item within DSpace. While DSpace calculates and records the checksum of every file submitted to it, the checker can determine whether the file has been changed. The idea being that the earlier you can identify a file has changed, the more likely you would be able to record it (assuming it was not a wanted change).</para>
|
||||
<para><literal>org.dspace.checker.CheckerCommand</literal> class, is the class for the checksum checker tool, which calculates checksums for each bitstream whose ID is in the <literal>most_recent_checksum</literal> table, and compares it against the last calculated checksum for that bitstream.</para>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-business.html-opensearch" xreflabel="OpenSearch Support"/>OpenSearch Support</title>
|
||||
<para>DSpace is able to support OpenSearch. For those not aquainted with the standard, a very brief introduction, with emphasis on what possibilities it holds for current use and future development.</para>
|
||||
<para>DSpace is able to support OpenSearch. For those not acquainted with the standard, a very brief introduction, with emphasis on what possibilities it holds for current use and future development.</para>
|
||||
<para>OpenSearch is a small set of conventions and documents for describing and using 'search engines', meaning any service that returns a set of results for a query. It is nearly ubiquitous—but also nearly invisible—in modern web sites with search capability. If you look at the page source of Wikipedia, Facebook, CNN, etc you will find buried a link element declaring OpenSearch support. It is very much a lowest-common-denominator abstraction (think Google box), but does provide a means to extend its expressive power. This first implementation for DSpace supports <emphasis>none</emphasis> of these extensions—many of which are of potential value—so it should be regarded as a foundation, not a finished solution. So the short answer is that DSpace appears as a 'search-engine' to OpenSearch-aware software.</para>
|
||||
<para>Another way to look at OpenSearch is as a RESTful web service for search, very much like SRW/U, but considerably simpler. This comparative loss of power is offset by the fact that it is widely supported by web tools and players: browsers understand it, as do large metasearch tools.</para>
|
||||
<para> </para>
|
||||
@@ -1275,12 +1275,16 @@ FOCUS> The Really Exciting Research Video
|
||||
<para>The default format returned is Atom 1.0, so you should see an Atom document containing your search results.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>You can extend the syntax witha few other parameters, as follows:</para>
|
||||
<para>You can extend the syntax with a few other parameters, as follows:</para>
|
||||
<para>
|
||||
<informaltable>
|
||||
<?dbhtml table-width="100%"?>
|
||||
<?dbfo table-width="100%"?>
|
||||
<tgroup cols="2"><colspec colname="c1" colwidth="30*" colsep="1"/><colspec colname="c2" colwidth="70*"/><spanspec spanname="notespan" namest="c1" nameend="c2" align="center"/><tbody>
|
||||
<tgroup cols="2">
|
||||
<colspec colname="c1" colwidth="30*" colsep="1"/>
|
||||
<colspec colname="c2" colwidth="70*"/>
|
||||
<spanspec spanname="notespan" namest="c1" nameend="c2" align="center"/>
|
||||
<tbody>
|
||||
<row>
|
||||
<entry>Parameter</entry>
|
||||
<entry>Values</entry>
|
||||
@@ -1291,7 +1295,7 @@ FOCUS> The Really Exciting Research Video
|
||||
</row>
|
||||
<row>
|
||||
<entry>scope</entry>
|
||||
<entry><handle>—search is restricted to a collection or communith with the indicated handle.</entry>
|
||||
<entry><handle>—search is restricted to a collection or community with the indicated handle.</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry>rpp</entry>
|
||||
@@ -1305,7 +1309,8 @@ FOCUS> The Really Exciting Research Video
|
||||
<entry>sort_by</entry>
|
||||
<entry>number indicating sorting criteria (same as DSpace advanced search values</entry>
|
||||
</row>
|
||||
</tbody></tgroup>
|
||||
</tbody>
|
||||
</tgroup>
|
||||
</informaltable>
|
||||
</para>
|
||||
</listitem>
|
||||
@@ -1317,7 +1322,45 @@ FOCUS> The Really Exciting Research Video
|
||||
<para>Configuration is throught the <literal>dspace.cfg file.</literal>See <link linkend="docbook-configure.html-opensearch">OpenSearch Support</link></para>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-business.html-embargo" xreflabel="embargo"/>Embargo</title>
|
||||
<para>The architecture of Embarge is documentated in the package javadocs. Run <literal>cd /[dspace-source]/dspace;mvn javadoc:javadoc</literal> and look in <literal>[dspace-source]/dspace-api/target/site/apidocs/index.html</literal>.</para>
|
||||
<title><anchor id="docbook-business.html-embargo" xreflabel="embargo"/>Embargo Support</title>
|
||||
<section remap="h3">
|
||||
<title>What is an Embargo?</title>
|
||||
<para>An embargo is a temporary access restriction placed on content, commencing at time of accession. It's scope or duration may vary, but the fact that it eventually expires is what distinguishes it from other content restrictions. For example, it is not unusual for content destined for DSpace to come with permanent restrictions on use or access based on license-driven or other IP-based requirements that limit access to institutionally affiliated users. Restrictions such as these are imposed and managed using standard administrative tools in DSpace, typically by attaching specific policies to Items or Collections, Bitstreams, etc. The embargo functionally introduced in 1.6, however, includes tools to automate the imposition and removal of restrictions in managed timeframes.</para>
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title>Embargo Model and Life-Cycle</title>
|
||||
<para>Functionally, the embargo system allows you to attach 'terms' to an item before it is placed into the repository, which express how the embargo should be applied. What do 'we mean by terms' here? They are really any expression that the system is capable of turning into (1) the time the embargo expires, and (2) a concrete set of access restrictions. Some examples:</para>
|
||||
<simplelist>
|
||||
<member>"2020-09-12" - an absolute date (i.e. the date embargo will be lifted)</member>
|
||||
<member>"6 months" - a time relative to when the item is accessioned</member>
|
||||
<member>"forever" - an indefinite, or open-ended embargo</member>
|
||||
<member>"local only until 2015" - both a time and an exception (public has no access until 2015, local users OK immediately)</member>
|
||||
<member>"Nature Publishing Group standard" - look-up to a policy somewhere (typically 6 months)</member>
|
||||
</simplelist>
|
||||
<para>These terms are 'interpreted' by the embargo system to yield a specific date on which the embargo can be removed or 'lifted', and a specific set of access policies. Obviously, some terms are easier to interpret than others (the absolute date really requires none at all), and the 'default' embargo logic understands only the most basic terms (the first and third examples above). But as we will see below, the embargo system provides you with the ability to add in your own 'interpreters' to cope with any terms expressions you wish to have. This date that is the result of the interpretation is stored with the item and the embargo system detects when that date has passed, and removes the embargo ("lifts it"), so the item bitstreams become available. Here is a more detailed life-cycle for an embargoed item:</para>
|
||||
<orderedlist numeration="upperalpha">
|
||||
<listitem>
|
||||
<para>Terms Assignment.</para>
|
||||
<para>The first step in placing an embargo on an item is to attach (assign) 'terms' to it. If these terms are missing, no embargo will be imposed. As we will see below, terms are carried in a configurable DSpace metadata field, so assigning terms just means assigning a value to a metadata field. This can be done in a web submission user interface form, in a SWORD deposit package, a batch import, etc. - anywhere metadata is passed to DSpace. The terms are not immediately acted upon, and may be revised, corrected, removed, etc, up until the next stage of the life-cycle. Thus a submitter could enter one value, and a collection editor replace it, and only the last value will be used. Since metadata fields are multivalued, theoretically there can be multiple terms values, but in the default implementation only one is recognized.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Terms interpretation/imposition.</para>
|
||||
<para>In DSpace terminology, when an item has exited the last of any workflow steps (or if none have been defined for it), it is said to be 'installed' into the repository. At this precise time, the 'interpretation' of the terms occurs, and a computed 'lift date' is assigned, which like the terms is recorded in a configurable metadata field. It is important to understand that this interpretation happens only once, (just like the installation), and cannot be revisited later. Thus, although an administrator can assign a new value to the metadata field holding the terms after the item has been installed, this will have no effect on the embargo, whose 'force' now resides entirely in the 'lift date' value. For this reason, you cannot embargo content already in your repository (at least using standard tools). The other action taken at installation time is the actual imposition of the embargo. The default behavior here is simply to remove the read policies on all the bundles and bitstreams except for the "LICENSE" or "METADATA" bundles. See the section on <emphasis>Extending Embargo Functionality</emphasis> for how to alter this behavior. Also note that since these policy changes occur before installation, there is no time during which embargoed content is 'exposed' (accessible by non-administrators). The terms interpretation and imposition together are called 'setting' the embargo, and the component that performs them both is called the embargo 'setter'.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Embargo Period.</para>
|
||||
<para>After an embargoed item has been installed, the policy restrictions remain in effect until removed. This is not an automatic process, however: a 'lifter' must be run periodically to look for items whose 'lift date' is past. Note that this means the effective removal of an embargo is <emphasis role="bold"
|
||||
>not</emphasis> the lift date, but the earliest date after the lift date that the lifter is run. Typically, a nightly cron-scheduled invocation of the lifter is more than adequate, given the granularity of embargo terms. Also note that during the embargo period, all metadata of the item remains visible. This default behavior can be changed. One final point to note is that the 'lift date', although it was computed and assigned during the previous stage, is in the end a regular metadata field. That means, if there are extraordinary circumstances that require an administrator (or collection editor—anyone with edit permissions on metadata) to change the lift date, they can do so. Thus, they can 'revise' the lift date without reference to the original terms. This date will be checked the next time the 'lifter' is run. One could immediately lift the embargo by setting the lift date to the current day, or change it to 'forever' to indefinitely postpone lifting.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Embargo Lift.</para>
|
||||
<para>When the lifter discovers an item whose lift date is in the past, it removes (lifts) the embargo. The default behavior of the lifter is to add the resource policies <emphasis>that would have been added</emphasis> had the embargo not been imposed. That is, it replicates the standard DSpace behavior, in which an item inherits it's policies from its owning collection. As with all other parts of the embargo system, you may replace or extend the default behavior of the lifter (see section V. below). You may wish, e.g. to send an email to an administrator or other interested parties, when an embargoed item becomes available.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Post Embargo.</para>
|
||||
<para>After the embargo has been lifted, the item ceases to respond to any of the embargo life-cycle events. The values of the metadata fields reflect essentially historical or provenance values. With the exception of the additional metadata fields, they are indistinguishable from items that were never subject to embargo.</para>
|
||||
</listitem>
|
||||
</orderedlist>
|
||||
</section>
|
||||
</section>
|
||||
</chapter>
|
||||
|
@@ -44,7 +44,7 @@ dspace.history = ${dspace.dir}/history</screen>
|
||||
<section remap="h3">
|
||||
<title><anchor id="docbook-configure.html-general-update" xreflabel="Update Reminder"/>Update Reminder</title>
|
||||
<subtitle>Things you should know about editing <literal>dspace.cfg</literal> files.</subtitle>
|
||||
<para>It is important to rememeber that there are <emphasis role="bold"> two <literal>dspace.cfg</literal> files after an installation of DSpace.</emphasis></para>
|
||||
<para>It is important to remember that there are <emphasis role="bold"> two <literal>dspace.cfg</literal> files after an installation of DSpace.</emphasis></para>
|
||||
<orderedlist>
|
||||
<listitem>
|
||||
<para>The "source" file that is found in <literal>[dspace-source]/dspace/config/dspace.cfg</literal></para>
|
||||
@@ -1642,7 +1642,7 @@ solr.spiderips.urls</screen>
|
||||
</row>
|
||||
<row>
|
||||
<entry align="right">Informational Note:</entry>
|
||||
<entry>If no other language is explicitly stated in the <literal>inputforms.xml</literal>, the default language will be attributed to the metadata values.</entry>
|
||||
<entry>If no other language is explicitly stated in the <literal>input-forms.xml</literal>, the default language will be attributed to the metadata values.</entry>
|
||||
</row>
|
||||
</tbody>
|
||||
</tgroup>
|
||||
@@ -1943,7 +1943,7 @@ assetstore.dir.2 = /third/assetstore</screen>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
<para>Should the be any conflict, like '2' referring to a local directory and to a set of SRB parameters, the program will select the local directory.</para>
|
||||
<para>If SRB is chosen from the first install of DSpace, it is suggested that 'assetstore.dir' (no integer appended) be retained to reference a local directory (as above under File Storage) because build.xml uses this value to do a mkdir. In this case, 'assetstore.incoming' can be set to 1 (i.e. uncomment the line in File Storage above) and the 'assetstore.dir' will not be used.</para>
|
||||
<para>If SRB is chosen from the first install of DSpace, it is suggested that 'assetstore.dir' (no integer appended) be retained to reference a local directory (as above under File Storage) because build.xml uses this value to do a <literal>mkdir</literal>. In this case, 'assetstore.incoming' can be set to 1 (i.e. uncomment the line in File Storage above) and the 'assetstore.dir' will not be used.</para>
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title><anchor id="docbook-configure.html-logging" xreflabel="Logging"/>Logging Configuration</title>
|
||||
@@ -4039,7 +4039,7 @@ Community|Collection|Item|Bundle+Add|Create|Modify|Modify_Metadata|Delete|Remove
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title><anchor id="docbook-configure.htmtl-embargo" xreflabel="Embargo"/>Embargo</title>
|
||||
<para>New in DSpace 1.6 is a feature to impose Embargos on thesis and dissertations.</para>
|
||||
<para>DSpace embargoes utilize standard metadata fields to hold both the 'terms' and the 'lift date'. Which fields you use are configurable, and no specific metadata element is dedicated or predefined for use in embargo. Rather, you specify exactly what field you want the embargo system to examine when it needs to find the terms or assign the lift date.</para>
|
||||
<informaltable>
|
||||
<?dbhtml table-width="100%"?>
|
||||
<?dbfo table-width="100%"?>
|
||||
@@ -4136,6 +4136,158 @@ Community|Collection|Item|Bundle+Add|Create|Modify|Modify_Metadata|Delete|Remove
|
||||
</tbody>
|
||||
</tgroup>
|
||||
</informaltable>
|
||||
<para>Key Recommendations:</para>
|
||||
<orderedlist>
|
||||
<listitem>
|
||||
<para> If using existing metadata fields, avoid any that are automatically managed by DSpace. For example, fields like '<literal>date.issued</literal>' or '<literal>date.accessioned</literal>' are normally automatically assigned, and thus must not be recruited for embargo use.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Do not place the field for '<literal>lift date</literal>' in submission screens. This can potentially confuse submitters because they may feel that they can directly assign values to it. As noted in the life-cycle above, this is erroneous: the lift date gets assigned by the embargo system based on the terms. Any pre-existing value will be over-written. But see next recommendation for an exception.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>As the life-cycle discussion above makes clear, after the terms are applied, that field is no longer actionable in the embargo system. Conversely, the 'lift date' field is not actionable *until* the application. Thus you may want to consider configuring both the 'terms' and 'lift date' to use the same metadata field. In this way, during workflow you would see only the terms, and after item installation, only the lift date. If you wish the metadata to retain the terms for any reason, use two distinct fields instead.</para>
|
||||
</listitem>
|
||||
</orderedlist>
|
||||
<section>
|
||||
<title>Detailed Operation</title>
|
||||
<para>After the fields defined for terms and lift date have been assigned in <literal>dspace.cfg</literal>, and created and configured wherever they will be used, you can begin to embargo items simply by entering data (dates, if using the default setter) in the terms field. They will automatically be embargoed as they exit workflow. For the embargo to be lifted on any item, however, a new administrative procedure must be added: the 'embargo lifter' must be invoked on a regular basis. This task examines all embargoed items, and if their 'lift date' has passed, it removes the access restrictions on the item. Good practice dictates automating this procedure using cron jobs or the like, rather than manually running it. The lifter is available as a target of the 1.6 DSpace launcher: see Section 8.</para>
|
||||
</section>
|
||||
<section>
|
||||
<title>Extending Embargo Functionality</title>
|
||||
<para>The 1.6 Embargo system supplies a default 'interpreter/imposition' class (the 'Setter') as well as a 'Lifter', but they are fairly rudimentary in several aspects.</para>
|
||||
<orderedlist numeration="upperalpha">
|
||||
<listitem>
|
||||
<para>Setter.</para>
|
||||
<para>The default setter recognizes only two expressions of terms: either a literal, non-relative date in the fixed format 'yyyy-mm-dd' (known as ISO 8601), or a special string used for open-ended embargo (the default configured value for this is 'forever', but this can be changed in dspace.cfg to 'toujours', 'unendlich', etc). It will perform a minimal sanity check that the date is not in the past. Similarly, the default setter will only remove all read policies as noted above, rather than applying more nuanced rules (e.g allow access to certain IP groups, deny the rest). Fortunately, the setter class itself is configurable and you can 'plug in' any behavior you like, provided it is written in java and conforms to the setter interface. The dspace.cfg property:</para>
|
||||
<screen># implementation of embargo setter plugin - replace with local implementation if applicable
|
||||
plugin.single.org.dspace.embargo.EmbargoSetter = org.dspace.embargo.DefaultEmbargoSetter</screen>
|
||||
<para>controls which setter to use.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Lifter.</para>
|
||||
<para>The default lifter behavior as described above—essentially applying the collection policy rules to the item—might also not be sufficient for all purposes. It also can be replaced with another class:</para>
|
||||
<screen># implementation of embargo lifter plugin--replace with local implementation if applicable
|
||||
plugin.single.org.dspace.embargo.EmbargoLifter = org.dspace.embargo.DefaultEmbargoLifter</screen>
|
||||
</listitem>
|
||||
</orderedlist>
|
||||
</section>
|
||||
<section>
|
||||
<title>Step-by-Step Setup Examples</title>
|
||||
<orderedlist numeration="upperalpha">
|
||||
<listitem>
|
||||
<para>Simple Dates.</para>
|
||||
<para>If you want to enter simple calendar dates for when an embargo will expire, follow these steps.</para>
|
||||
<orderedlist>
|
||||
<listitem>
|
||||
<para>Select a metadata field. Let's use <literal>dc.description.embargo</literal>. This field does not exist in in the default DSpace metadata directory, so login as an administrator, go the metadata registry page, select the 'dc' schema, then add the metadata field.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Expose the metadata field. Edit <literal>[dspace]/config/input-forms.xml</literal> . If you have only one form—usually 'traditional', add it there. If you have multiple forms, add it only to the forms linked to collections for which embargo applies:</para>
|
||||
<screen><form name="traditional">
|
||||
<page number="1">
|
||||
…
|
||||
<field>
|
||||
<dc-schema>dc</dc-schema>
|
||||
<dc-element>description</dc-element>
|
||||
<dc-qualifier>embargo</dc-qualifier>
|
||||
<repeatable>false</repeatable>
|
||||
<label>Embargo Date</label>
|
||||
<input-type>onebox</input-type>
|
||||
<hint>If required, enter date 'yyyy-mm-dd' when embargo expires or 'forever'.</hint>
|
||||
<required></required>
|
||||
</field>
|
||||
</screen>
|
||||
<para>Note: if you want to require embargo terms for every item, put a phrase in the <required> element. Example:</para>
|
||||
<para><literal><required>You must enter an embargo date</required></literal></para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Configure Embargo. Edit <literal>[dspace]/config/dspace.cfg</literal>. Find the Embargo properties and set these two:</para>
|
||||
<screen># DC metadata field to hold the user-supplied embargo terms
|
||||
embargo.field.terms = dc.description.embargo
|
||||
|
||||
# DC metadata field to hold computed "lift date" of embargo
|
||||
embargo.field.lift = dc.description.embargo</screen>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Restart DSpace application. This will pick up these changes. Now just enter future dates (if applicable) in web submission and the items will be placed under embargo. You can enter years ('2020'), years and months ('2020-12'), or also days ('2020-12-15'). </para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Periodically run the lifter. Run the task:</para>
|
||||
<para><literal>[dspace]/bin/dspace embargo-lifter</literal></para>
|
||||
<para>You will want to run this task in a cron-scheduled or other repeating way. Item embargoes will be lifted as their dates pass.</para>
|
||||
</listitem>
|
||||
</orderedlist>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Period Sets.</para>
|
||||
<para>If you wish to use a fixed set of time periods (e.g. 90 days, 6 months and 1 year) as embargo terms, follow these steps, which involve using a custom 'setter'.</para>
|
||||
<orderedlist>
|
||||
<listitem>
|
||||
<para>Select two metadata fields. Let's use '<literal>dc.embargo.terms</literal>' and '<literal>dc.embargo.lift</literal>'. These fields do not exist in the default DSpace metadata registry. Login as an administrator, go the metadata registry page, select the 'dc' schema, then add the metadata fields.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Expose the 'term' metadata field. The lift field will be assigned by the embargo system, so it should not be exposed directly. Edit <literal>[dspace]/config/input-forms.xml</literal> . If you have only one form (usually 'traditional') add it there. If you have multiple forms, add it only to the form(s) linked to collection(s) for which embargo applies. First, add the new field to the 'form definition':</para>
|
||||
<screen><form name="traditional">
|
||||
<page number="1">
|
||||
…
|
||||
<field>
|
||||
<dc-schema>dc</dc-schema>
|
||||
<dc-element>embargo</dc-element>
|
||||
<dc-qualifier>terms</dc-qualifier>
|
||||
<repeatable>false</repeatable>
|
||||
<label>Embargo Terms</label>
|
||||
<input-type value-pairs-name="embargo_terms">dropdown</input-type>
|
||||
<hint>If required, select embargo terms.</hint>
|
||||
<required></required>
|
||||
</field></screen>
|
||||
<para>Note: If you want to require embargo terms for every item, put a phrase in the <literal><required></literal> element, e.g.</para>
|
||||
<para><literal><required>You must select embargo terms</required></literal></para>
|
||||
<para>Observe that we have referenced a new value-pair list: "embargo_terms'. We must now define that as well (only once even if references by multiple forms):</para>
|
||||
<screen><form-value-pairs>
|
||||
…
|
||||
<value-pairs value-pairs-name="embargo_terms" dc-term="embargo.terms">
|
||||
<pair>
|
||||
<displayed-value>90 days</displayed-value>
|
||||
<stored-value>90 days</stored-value>
|
||||
</pair>
|
||||
<pair>
|
||||
<displayed-value>6 months</displayed-value>
|
||||
<stored-value>6 months</stored-value>
|
||||
</pair>
|
||||
<pair>
|
||||
<displayed-value>1 year</displayed-value>
|
||||
<stored-value>1 year</stored-value>
|
||||
</pair>
|
||||
</value-pairs>
|
||||
</screen>
|
||||
<para>Note: if desired, you could localize the language of the displayed value.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Configure Embargo. Edit /dspace/config/dspace.cfg. Find the Embargo properties and set the following properties:</para>
|
||||
<screen> # DC metadata field to hold the user-supplied embargo terms
|
||||
embargo.field.terms = dc.embargo.terms
|
||||
|
||||
# DC metadata field to hold computed "lift date" of embargo
|
||||
embargo.field.lift = dc.embargo.lift
|
||||
|
||||
# implementation of embargo setter plugin - replace with local implementation if applicable
|
||||
plugin.single.org.dspace.embargo.EmbargoSetter = org.dspace.embargo.DayTableEmbargoSetter</screen>
|
||||
<para>Now add a new property called '<literal>embargo.terms.days</literal>' as follows:</para>
|
||||
<screen> # DC metadata field to hold computed "lift date" of embargo
|
||||
embargo.terms.days = 90 days:90, 6 months:180, 1 year:365</screen>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>This step is the same as Step A.4 above, except that instead of entering a date, the submitter will select a value form a drop-down list.</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>Periodically run the lifter. Run the task:</para>
|
||||
<para><literal>[dspace]/bin/dspace embargo-lifter</literal></para>
|
||||
<para>You will want to run this task in a cron-scheduled or other repeating way. Item embargoes will be lifted as their dates pass.</para>
|
||||
</listitem>
|
||||
</orderedlist>
|
||||
</listitem>
|
||||
</orderedlist>
|
||||
</section>
|
||||
</section>
|
||||
<section remap="h3">
|
||||
<title><anchor id="docbook-configure.html-checksum" xreflabel="Checksum Checker Settings"/>Checksum Checker Settings</title>
|
||||
@@ -7227,7 +7379,7 @@ webui.itemlist.<sort or index name>.columns</screen>
|
||||
<row>
|
||||
<entry align="right">Informational Note:</entry>
|
||||
<entry>If you would like to use Google analytics to track general website statistics then use the following parameter to provide your analytics key. First sign up for an account at <ulink url="http://analytics.google.com"
|
||||
>http://analytics.google.com</ulink>, then create an entry for your repositories website. Google Analytics will give you a snipit of javascript code to place on your site, inside that snip it is your google analytics key usually found in the line: _uacct = "UA-XXXXXXX-X" Take this key (just the UA-XXXXXX-X part) and place it here in this parameter.</entry>
|
||||
>http://analytics.google.com</ulink>, then create an entry for your repositories website. Google Analytics will give you a snippet of javascript code to place on your site, inside that snip it is your google analytics key usually found in the line: _uacct = "UA-XXXXXXX-X" Take this key (just the UA-XXXXXX-X part) and place it here in this parameter.</entry>
|
||||
</row>
|
||||
<row>
|
||||
<?dbfo row-height="5mm"?>
|
||||
@@ -7784,7 +7936,7 @@ hdl.handle.net, handle.test.edu</screen>
|
||||
</section>
|
||||
<section remap="h4">
|
||||
<title>Bitstream Format Registry</title>
|
||||
<para>The bitstream formats recognized by the system and levels of support are similarly stored in the bitstream format registry. This can also be edited at install-time via <literal>[dspace]/config/registries/bitstream-formats.xml</literal> or by the administation Web UI. The contents of the bitstream format registry are entirely up to you, though the system requires that the following two formats are present:</para>
|
||||
<para>The bitstream formats recognized by the system and levels of support are similarly stored in the bitstream format registry. This can also be edited at install-time via <literal>[dspace]/config/registries/bitstream-formats.xml</literal> or by the administration Web UI. The contents of the bitstream format registry are entirely up to you, though the system requires that the following two formats are present:</para>
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>
|
||||
@@ -8315,7 +8467,7 @@ sword.accept-packaging.[handle].METSDSpaceSIP.q = 1.0</screen>
|
||||
</row>
|
||||
<row>
|
||||
<entry align="right">Informational Note:</entry>
|
||||
<entry>Should the server identify the sword version in a deposti response. It is recommended to leave this unchanged.</entry>
|
||||
<entry>Should the server identify the sword version in a deposit response. It is recommended to leave this unchanged.</entry>
|
||||
</row>
|
||||
<row>
|
||||
<?dbfo row-height="5mm"?>
|
||||
@@ -8332,7 +8484,7 @@ sword.accept-packaging.[handle].METSDSpaceSIP.q = 1.0</screen>
|
||||
</row>
|
||||
<row>
|
||||
<entry align="right">Informational Note:</entry>
|
||||
<entry>Should mediated deposit via sowrd be supported. If enabled, this will allow users to deposit content packages on behalf of other users.</entry>
|
||||
<entry>Should mediated deposit via sword be supported. If enabled, this will allow users to deposit content packages on behalf of other users.</entry>
|
||||
</row>
|
||||
<row>
|
||||
<?dbfo row-height="5mm"?>
|
||||
|
@@ -1,6 +1,140 @@
|
||||
<?xml version='1.0' encoding='UTF-8'?>
|
||||
<chapter remap="h1">
|
||||
<title><anchor id="docbook-history.html"/>DSpace System Documentation: Version History</title>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-history.html-version1_61" xreflabel="Changes in DSpace 1.6.0"/>Changes in DSpace 1.6.1</title>
|
||||
<section remap="h3">
|
||||
<title>Bug Fixes</title>
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>DS-295 - CC License being assigned incorrect Mime Type during submission</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-239 - java.net.MalformedURLException: unknow protocol: resource</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-242 - Special groups shown for logged in user rather than for user being examined</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-430 - Embargo</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-469 - <literal>DCDate.displayDate(false,*)</literal> displays only year</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-471 - Accessing site-level 'mets.xml' in XMLUI doesn't work properly for handle prefixes with periods (e.g. 2010.1)</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-493 - Url in browser is incorrect after login</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-497 - Date month and day get default values when user returns to describe form</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-500 - Ukrainian for DSpace 1.6.0</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-501 - Kubrick Theme - NaN in Item Browse</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-506 - embargo-lifter command missing from <literal>launcher.xml</literal></para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-507 - Log Converter difference between docs (log-converter) and launcher (stats-log-converter)</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-508 - Attachment spelled as attachement in DailyReportEmailer</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-509 - Retrieving country names in SOLR can return ArrayIndexOutOfBounds when country code is unchecked</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-513 - Connection leak in SWORD authentication process</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-518 - Duplicate listing of dependencies in dspace-sword/pom.xml</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-523 - Reordering of 1.5 -> 1.6 upgrade steps in DSpace manual</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-526 - ItemUpdate - script and manual updates</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-527 - Withdrawn items not shown as deleted in OAI</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-534 - Documentation for 'schema' attribute in metadata xml files</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-537 - Malformed Japanese option values in the authority lookup window</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-538 - restricted items are being returned in OAI GetRecord method while using harvest.includerestricted.oai</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-539 - Misspelled attribute in MODS/METS output</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-542 - verbose output for stats-log-importer displays spurious city/country from previous committed entry</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-543 - Harvest not internationalized</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-544 - Removal of mapped items can lead to NPE</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-547 - Value for Recent Submissions is not workin in the XMLUI</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-548 - Removing repeatable values in DescribeStep does not properly test for authority control</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-551 - Export directories <literal>dspace.cfg</literal> and <literal>build.xml</literal> out of sync</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-556 - Add Xalan to SOLR <literal>pom.xml</literal> as dependency</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-557 - LC Authority Names - Lookup Feature - names without dates</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-558 - Error in update sequence script 1.5 to 1.6 Oracle</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-565 - Fixed for Empty description column in Itemview Page - General-Handler.xsl</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-566 - Fixed for side bar menu dropping when there is license text in collection - DIM-Handler.xsl</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-571 - Upgrade DSpace Services to next release</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-572 - Batch metadata editor fails to notice change of item's owning collection</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-573 - NPE resuming submission for item with an empty bundle original</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-574 - DSpaceMETSIngester creates empty original bundle</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-577 - Use modified Cocoon Servlet Service Impl in place of existing to support proper Cocoon Block addition</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-579 - Required fields in submissions display wrong error message</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-580 - DIDL format include HTML element if the item has no files</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-581 - DIDL doesn't respect the hidden fields and the oai_dc metadata section is different than the simple oai_dc implementation</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</section>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-history.html-version1_6" xreflabel="Changes in DSpace 1.6.0"/>Changes in DSpace 1.6.0</title>
|
||||
<section remap="h3">
|
||||
@@ -65,7 +199,7 @@
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</section>
|
||||
<section>
|
||||
<section remap="h3">
|
||||
<title>General Improvments</title>
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
@@ -500,7 +634,8 @@
|
||||
<para>DS-474 - handle.canonical.prefix undocumented</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-475 - create a new group</para></listitem>
|
||||
<para>DS-475 - create a new group</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>DS-477 - LDAPHierarchicalAuthentication fails when the LDAP returns mixed case email address</para>
|
||||
</listitem>
|
||||
@@ -509,14 +644,14 @@
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</section>
|
||||
</section>
|
||||
<section remap="h2">
|
||||
<title><anchor id="docbook-history.html-version1_5_2" xreflabel="Changes in DSpace 1.5.2"/>Changes in DSpace 1.5.2</title>
|
||||
<section remap="h3">
|
||||
<title>General Improvements</title>
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>The History System has been removed since DSpace 1.5. The <literal>[dspace]/history</literal> directory and it's contents can be completely removed if you so choose as it is non functional.
|
||||
</para>
|
||||
<para>The History System has been removed since DSpace 1.5. The <literal>[dspace]/history</literal> directory and it's contents can be completely removed if you so choose as it is non functional. </para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</section>
|
||||
@@ -2015,8 +2150,4 @@
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
</chapter>
|
||||
|
||||
|
||||
</chapter>
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user