|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.tranche.project.ArbitraryProjectBuildingTool
public class ArbitraryProjectBuildingTool
Create an arbitrary project from existing files on the network.
| Constructor Summary | |
|---|---|
ArbitraryProjectBuildingTool(java.security.cert.X509Certificate cert,
java.security.PrivateKey key,
java.lang.String directoryName)
Instantiate. |
|
| Method Summary | |
|---|---|
boolean |
addDataSet(BigHash hash)
Add an entire data. |
boolean |
addFileFromProject(BigHash projectHash,
BigHash fileHash)
Adds a file chunkHash to the project chunkHash. |
boolean |
addFileFromProject(BigHash projectHash,
ProjectFilePart pfp)
Add a file that should be added to the project. |
boolean |
addIndividualFile(BigHash hash)
Add a file that should be added to the project. |
void |
addServerToUse(java.lang.String host)
Add a server to use. |
java.lang.String |
getDescription()
The description for the new proejct. |
java.lang.String |
getTitle()
This title for the new project. |
static boolean |
isPrintServerPerformanceSummary()
|
static void |
main(java.lang.String[] args)
|
BigHash |
run()
After setting all the files, run to create the project from existing files on the network. |
void |
setDescription(java.lang.String description)
The description for the new proejct. |
static void |
setIsPrintServerPerformanceSummary(boolean aIsPrintServerPerformanceSummary)
|
void |
setTitle(java.lang.String title)
This title for the new project. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ArbitraryProjectBuildingTool(java.security.cert.X509Certificate cert,
java.security.PrivateKey key,
java.lang.String directoryName)
Instantiate.
cert - Certificate of user who can write to networkkey - Key for user who can write to networkdirectoryName - The name to be used for the directory holding all the files. (Title and description can be set using setters, and are different.)| Method Detail |
|---|
public static boolean isPrintServerPerformanceSummary()
public static void setIsPrintServerPerformanceSummary(boolean aIsPrintServerPerformanceSummary)
public static void main(java.lang.String[] args)
args -
public boolean addFileFromProject(BigHash projectHash,
ProjectFilePart pfp)
Add a file that should be added to the project. This file should exist already on network.
projectHash - pfp - An existing ProjectFilePart. Could use chunkHash, but if already have this, can save a little time.
public boolean addFileFromProject(BigHash projectHash,
BigHash fileHash)
Adds a file chunkHash to the project chunkHash.
projectHash - fileHash -
public boolean addIndividualFile(BigHash hash)
Add a file that should be added to the project. This file should exist already on network and must not be part of a data set.
chunkHash - The BigHash for the file. Will go to network to get MetaData for file. If have ProjectFilePart, use instead to save time.
public boolean addDataSet(BigHash hash)
Add an entire data. This tool will include all its files with other files you specify.
The data set should exist on the network.
hash - The BigHash for the data set.
public BigHash run()
throws java.lang.Exception
After setting all the files, run to create the project from existing files on the network.
java.lang.Exception - Any exception will stop the tool. This partially ensures the integrity of the project. Note that can succeed even if data chunks are missing. If ProjectFilePart objects were directly added, could succeed even with missing meta data.public java.lang.String getTitle()
This title for the new project.
public void setTitle(java.lang.String title)
This title for the new project.
title - public java.lang.String getDescription()
The description for the new proejct.
public void setDescription(java.lang.String description)
The description for the new proejct.
description - public void addServerToUse(java.lang.String host)
Add a server to use.
If no server urls added, will use core servers for network.
If servers added, will use those instead.
Uses same contract as AddFileTool.
host -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||