The following document contains the results of PMD's CPD 3.9.
| File | Line |
|---|---|
| org/abstracthorizon/proximity/storage/local/ReadOnlyFileSystemStorage.java | 252 |
| org/abstracthorizon/proximity/storage/local/WritableFileSystemStorage.java | 175 |
}
/*
* (non-Javadoc)
*
* @see org.abstracthorizon.proximity.storage.local.ReadOnlyFileSystemStorage#recreateMetadata(java.util.Map)
*/
public void recreateMetadata( Map extraProps )
throws StorageException
{
// issue #44, we will not delete existing metadata,
// instead, we will force to "recreate" those the properties factory
// eventually appending it with new ones.
int processed = 0;
Stack stack = new Stack();
List dir = listItems( ItemProperties.PATH_ROOT );
stack.push( dir );
while ( !stack.isEmpty() )
{
dir = (List) stack.pop();
for ( Iterator i = dir.iterator(); i.hasNext(); )
{
ItemProperties ip = (ItemProperties) i.next();
if ( ip.isDirectory() )
{
List subdir = listItems( ip.getPath() );
stack.push( subdir );
}
else
{
logger.debug( "**** {}", ip.getPath() );
File target = new File( getStorageBaseDir(), ip.getPath() );
ItemProperties nip = getProxiedItemPropertiesFactory().expandItemProperties(
ip.getPath(),
target,
false );
if ( ip.getMetadata( DefaultExpiringProxyingRepositoryLogic.METADATA_EXPIRES ) != null ) | |