Changeset 6770
- Timestamp:
- 2004-02-10T18:07:32+13:00 (20 years ago)
- Location:
- trunk/gli/src/org/greenstone/gatherer
- Files:
-
- 34 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gli/src/org/greenstone/gatherer/Gatherer.java
r6634 r6770 139 139 } 140 140 141 /** Constructor. Make the three main modules, c_man, f_man and g_man, and any other necessary classes such as Dictionary. 141 public Gatherer() { 142 this.self = this; 143 } 144 145 /** Run method. Make the three main modules, c_man, f_man and g_man, and any other necessary classes such as Dictionary. 142 146 * @param size The desired size of the Gatherer window as a <strong>Dimension</strong>. 143 147 * @param gsdl_path The path to the gsdl directory, gathered from the startup arguments, and presented as a <strong>String</strong>. … … 145 149 * @param debug_enabled <i>true</i> to print verbose debug messages to "debug.txt", <i>false</i> otherwise. 146 150 * @param perl_path The path to the PERL compiler as a <strong>String</strong>. Necessary for windows platform versions. 151 * @param no_load <i>true</i> to prevent the previously opened collection from reopening. 147 152 * @param splash A reference to the splash screen. 148 * @param no_load <i>true</i> to prevent the previously opened collection from reopening. 153 * @param open_collection 154 * @param mirroring_enabled 155 * @param wget_version_str 156 * @param wget_path 149 157 * @see java.io.FileOutputStream 150 158 * @see java.io.PrintStream … … 161 169 * @see org.greenstone.gatherer.gui.Splash 162 170 */ 163 public Gatherer() {164 this.self = this;165 }166 167 171 public void run(Dimension size, String gsdl_path, String exec_path, boolean debug_enabled, String perl_path, boolean no_load, Splash splash, String open_collection, boolean mirroring_enabled, String wget_version_str, String wget_path) { 168 172 … … 441 445 442 446 /** Used to 'spawn' a new child application when a file is double clicked. 443 * @param command The command to run in the child process to start the application, garnered from the registry of a default associations file, and presented as a <strong>String</strong>. 444 * @see java.util.Vector 447 * @param file The file to open 445 448 * @see org.greenstone.gatherer.Gatherer.ExternalApplication 446 449 */ … … 457 460 } 458 461 462 /** Used to 'spawn' a new browser application or reset an existing one when the preview button is clicked 463 * @param url The url to open the browser at 464 * @see org.greenstone.gatherer.Gatherer.BrowserApplication 465 */ 459 466 public void spawnBrowser(String url) { 460 467 String command = assoc_man.getBrowserCommand(url); … … 775 782 776 783 /** Loads the configuration file if one exists. Otherwise it creates a new one. Currently uses serialization. 777 * @param size The desired size of the Gatherer window as a <strong>Dimension</strong>.778 784 * @param gsdl_path The path to the gsdl directory, gathered from the startup arguments, and presented as a <strong>String</strong>. 779 785 * @param exec_path The path to the library executable, gathered from the startup arguments, and presented as a <strong>String</strong>. 780 786 * @param perl_path The path to the PERL compiler as a <strong>String</strong>. Necessary for windows platform versions. 787 * @param mirroring_enabled 788 * @param wget_version_str 789 * @param wget_path 781 790 * @see java.io.FileInputStream 782 791 * @see java.io.ObjectInputStream -
trunk/gli/src/org/greenstone/gatherer/WGet.java
r6637 r6770 245 245 246 246 /** Creates a new mirroring job on the queue given the target url and the destination (private, public). All other details are harvested from the config file, but these two must be captured from the GUI's current state. 247 * @param no_parents 248 * @param other_hosts 249 * @param page_requisites 247 250 * @param url a URL which points to the root url for the mirroring 248 * @param model the GTreeModel that any new records should be added to251 * @param depth 249 252 * @param destination the destination file as a String 250 253 * @see org.greenstone.gatherer.Configuration -
trunk/gli/src/org/greenstone/gatherer/cdm/Argument.java
r6389 r6770 246 246 * @see org.greenstone.gatherer.msm.ElementWrapper 247 247 * @see org.greenstone.gatherer.msm.MetadataSetManager#getElement(String) 248 * @see org.greenstone.gatherer.msm.MSMUtils#getValue( Element)248 * @see org.greenstone.gatherer.msm.MSMUtils#getValue(Node) 249 249 */ 250 250 public String getValue() { … … 271 271 * @see org.greenstone.gatherer.msm.ElementWrapper 272 272 * @see org.greenstone.gatherer.msm.MetadataSetManager#getElement(String) 273 * @see org.greenstone.gatherer.msm.MSMUtils#getValue( Element)273 * @see org.greenstone.gatherer.msm.MSMUtils#getValue(Node) 274 274 */ 275 275 public ArrayList getValues() { -
trunk/gli/src/org/greenstone/gatherer/cdm/ArgumentConfiguration.java
r6389 r6770 835 835 * @param two A <strong>JButton</strong> whose enabled state is determined by the listener, or <i>null</i> if no button. 836 836 * @param list A <strong>JList</strong> whose enabled state is determined by the listener, or <i>null</i> if no list. 837 * @param list A <strong>JComponent</strong> whose enabled state is determined by the listener, or <i>null</i> if no component.837 * @param target A <strong>JComponent</strong> whose enabled state is determined by the listener, or <i>null</i> if no component. 838 838 */ 839 839 public EnabledListener(JButton one, JButton two, JList list, JComponent target) { … … 943 943 } 944 944 /** Tests two possible ListOption objects for equality. Uses the result from compareTo(). 945 * @param The <strong>Object</strong> which may be equal.945 * @param object The <strong>Object</strong> which may be equal. 946 946 * @return <i>true</i> if the objects are equal, <i>false</i> otherwise. 947 947 */ -
trunk/gli/src/org/greenstone/gatherer/cdm/Classifier.java
r5863 r6770 133 133 /** Constructor. 134 134 * @param name The name of this classifier as a <strong>String</strong>. 135 * @param desc A description of this classifier as a <strong>String</strong>.135 * @param description A description of this classifier as a <strong>String</strong>. 136 136 * @param super_classifier The super class of this classifier, as a <strong>Classifier</strong>. 137 137 */ … … 167 167 /** The assigned classifier constructor. 168 168 * @param element the DOM Element this classifier is based upon 169 * @param base_classifier the Classifier from the stored library showing details about this classifier, may be null170 169 */ 171 170 public DOMProxyListEntry create(Element element) { … … 360 359 361 360 /** Method to set the value of desc. 362 * @param desc The new value of desc as a <strong>String</strong>.361 * @param description The new value of desc as a <strong>String</strong>. 363 362 */ 364 363 public void setDescription(String description) { -
trunk/gli/src/org/greenstone/gatherer/cdm/CollectionConfiguration.java
r6539 r6770 67 67 68 68 /** Find the best insertion position for the given DOM Element. This should try to match command tag, and if found should then try to group by name or type (eg CollectionMeta), or append to end is no such grouping exists (eg PlugIns). Failing a command match it will check against the command order for the best insertion location. 69 * @param element the command Element to be inserted69 * @param target_element the command Element to be inserted 70 70 * @return the Element which the given command should be inserted before, or null to append to end of list 71 71 */ -
trunk/gli/src/org/greenstone/gatherer/cdm/CollectionMeta.java
r6539 r6770 166 166 167 167 /** Change the value of value. 168 * @param value the new value as a String.168 * @param raw_value the new value as a String. 169 169 */ 170 170 public void setValue(String raw_value) { -
trunk/gli/src/org/greenstone/gatherer/cdm/DOMProxyListModel.java
r5756 r6770 75 75 /** Used to add an element into the underlying dom, and fire the appropriate repaint events. 76 76 * @param index the index where the element should be inserted (relative of the other elements in this proxy list) 77 * @param e lement the Elementto be inserted77 * @param entry the <strong>DOMProxyListEntry</strong> to be inserted 78 78 */ 79 79 public synchronized void add(int index, DOMProxyListEntry entry) { -
trunk/gli/src/org/greenstone/gatherer/cdm/Index.java
r6539 r6770 244 244 245 245 /** Method to set the level of this index which can only be used for the default index. 246 * @param level the new level as an int246 * @param new_level the new level as an int 247 247 */ 248 248 public void setLevel(int new_level) { -
trunk/gli/src/org/greenstone/gatherer/cdm/IndexManager.java
r6539 r6770 1391 1391 * @param event a DocumentEvent containing information about the text removed 1392 1392 */ 1393 public void removeUpdate(DocumentEvent e ) {1393 public void removeUpdate(DocumentEvent event) { 1394 1394 validateAddButton(); 1395 1395 } … … 1453 1453 * @param event a DocumentEvent containing information about the text removed 1454 1454 */ 1455 public void removeUpdate(DocumentEvent e ) {1455 public void removeUpdate(DocumentEvent event) { 1456 1456 validateAddButton(); 1457 1457 } -
trunk/gli/src/org/greenstone/gatherer/cdm/LanguageManager.java
r6539 r6770 168 168 /** Method to retrieve a certain language object by its code. 169 169 * @param code The two letter code of a language, as a <strong>String</strong>. 170 * @param assigned_only If <i>true</i> only those languages currently having indexes built for them are checked, otherwise the known languages buffer is checked.171 170 * @return The <strong>Language</strong> that matches the given code, or <i>null</i> if no such language exists. 172 171 */ -
trunk/gli/src/org/greenstone/gatherer/cdm/PlugIn.java
r5863 r6770 135 135 /** The assigned plugin constructor. 136 136 * @param element the DOM Element this plugin is based upon 137 * @param base_plugin the PlugIn from the stored library showing details about this plugin, may be null138 137 */ 139 138 public DOMProxyListEntry create(Element element) { … … 315 314 316 315 /** Method to set the value of desc. 317 * @param desc The new value of desc as a <strong>String</strong>.316 * @param description The new value of desc as a <strong>String</strong>. 318 317 */ 319 318 public void setDescription(String description) { -
trunk/gli/src/org/greenstone/gatherer/cdm/SearchTypeManager.java
r6318 r6770 443 443 * @param event a DocumentEvent containing information about the text removed 444 444 */ 445 public void removeUpdate(DocumentEvent e ) {445 public void removeUpdate(DocumentEvent event) { 446 446 validateAddButton(); 447 447 } -
trunk/gli/src/org/greenstone/gatherer/cdm/Subcollection.java
r5590 r6770 142 142 143 143 /** Method to get the value of name. 144 * @ paramString The value of name as a <strong>String</string>.144 * @return String The value of name as a <strong>String</string>. 145 145 */ 146 146 public String getName() { … … 180 180 181 181 /** Method to get the value of include. 182 * @ paramboolean true if this is an inclusion filter, false otherwise182 * @return boolean true if this is an inclusion filter, false otherwise 183 183 */ 184 184 public boolean isInclusive() { -
trunk/gli/src/org/greenstone/gatherer/cdm/SubcollectionIndexManager.java
r6389 r6770 152 152 153 153 /** Method to remove all of the subindexes that contain a certain subcollection. 154 * @param sub the Subcollection that has been removed154 * @param subcollection the Subcollection that has been removed 155 155 * @see org.greenstone.gatherer.cdm.Subcollection 156 156 * @see org.greenstone.gatherer.cdm.SubcollectionIndex … … 170 170 171 171 /** Method to set the default subcollection index. 172 * @param subcollection The <strong>Subcollection</strong> to use as the default index.172 * @param index The <strong>SubcollectionIndex</strong> to use as the default index. 173 173 * @see org.greenstone.gatherer.Gatherer 174 174 * @see org.greenstone.gatherer.collection.CollectionManager 175 * @see org.greenstone.gatherer.cdm.SubcollectionIndex 175 176 */ 176 177 public void setDefaultSubcollectionIndex(SubcollectionIndex index) { -
trunk/gli/src/org/greenstone/gatherer/collection/CollectionManager.java
r6662 r6770 1169 1169 } 1170 1170 /** Remove a previously assigned special directory mapping. 1171 * @param name The symbolic name ofthe special directory mapping to remove as a <strong>String</strong>.1171 * @param target The <string>FileNode</strong> representing the special directory mapping to remove as a <strong>String</strong>. 1172 1172 * @return The <strong>File</strong> of the mapping removed. 1173 * @see org.greenstone.gatherer.file.FileNode 1173 1174 */ 1174 1175 public File removeDirectoryMapping(FileNode target) { -
trunk/gli/src/org/greenstone/gatherer/collection/Job.java
r6637 r6770 161 161 162 162 /** Called by the WGet native code to inform us of a new download starting. 163 * @param url The url that is being downloaded, as a String.163 * @param raw_url The url that is being downloaded, as a String. 164 164 */ 165 165 public void addDownload(String raw_url) { … … 176 176 * to decide if it already knows about this url, and if not to 177 177 * update its progress bar. 178 * @param url The url in question as a String.178 * @param raw_url The url in question as a String. 179 179 * @param type Whether the link is an internal or external link. 180 180 * @return A boolean indicating if the url was added. -
trunk/gli/src/org/greenstone/gatherer/collection/SaveCollectionTask.java
r6385 r6770 70 70 static final private int RESTORE_COLLECTION = 9; 71 71 /** Constructor. 72 * @param name The filename of the collection we are saving as. 72 * @param collection The <strong>Collection</strong> we are saving. 73 * @see org.greenstone.gatherer.collection.Collection 73 74 */ 74 75 public SaveCollectionTask(Collection collection) { -
trunk/gli/src/org/greenstone/gatherer/file/FileQueue.java
r6539 r6770 667 667 668 668 /** Register the button that will be responsible for stopping executing file actions. 669 * @param button a JButton669 * @param stop_button a JButton 670 670 */ 671 671 public void registerStopButton(JButton stop_button) { -
trunk/gli/src/org/greenstone/gatherer/gui/FileAssociationDialog.java
r6748 r6770 82 82 83 83 /** Create a new file association dialog. 84 * @param manager A reference to the <strong>FileAssociationManager</strong> so we can determine what extensions are already associated.84 * @param file_association_manager A reference to the <strong>FileAssociationManager</strong> so we can determine what extensions are already associated. 85 85 */ 86 86 public FileAssociationDialog(FileAssociationManager file_association_manager) { -
trunk/gli/src/org/greenstone/gatherer/gui/GProgressBar.java
r6637 r6770 194 194 * assigned to track the download. 195 195 * @param url The url String of the file that is being downloaded. 196 * @param size The size of the file as an Int.197 196 */ 198 197 public void addDownload(String url) { -
trunk/gli/src/org/greenstone/gatherer/gui/GUIManager.java
r6665 r6770 136 136 /**Constructor. Enable window events and arranges all other components. 137 137 * @param size The intial <strong>Dimension</strong> of the screen. 138 * @param graphic The default <strong>GraphicsConfiguration</strong> for this platform.139 138 */ 140 139 public GUIManager(Dimension size) { -
trunk/gli/src/org/greenstone/gatherer/gui/ModalDialog.java
r6666 r6770 95 95 /** Constructor. 96 96 * @param parent the Frame which is the owener of this dialog. 97 * @param title the String to use as the title for this dialog.97 * @param modal whether this dialog is modal or not 98 98 */ 99 99 public ModalDialog(Frame parent, boolean modal) { -
trunk/gli/src/org/greenstone/gatherer/msm/LegacyCollectionImporter.java
r6093 r6770 108 108 109 109 /** Processes the files in the import tree, editing metadata.xml files so they contain namespaced element names. 110 * @param collection_folder the base folder of this collection, needed for storing importing profiles111 110 * @param file the current file we are inspecting 112 111 */ -
trunk/gli/src/org/greenstone/gatherer/msm/MSMAction.java
r5785 r6770 60 60 * @param action An <i>int</i> representing what action needs to be taken in subsequent access of the given set and source element. 61 61 * @param target A <strong>String</strong> representing the fully qualified name of the target element. 62 * @param hfile If this action was created from the hfile parsing stage, does the element require a replacement to change its alias value into a real one. Note that this profile item may be created for fully namespaced elements as well, to ensure aliases are always remapped.63 62 */ 64 63 public MSMAction(int action, String target) { -
trunk/gli/src/org/greenstone/gatherer/msm/MSMPrompt.java
r6539 r6770 659 659 /** Prompts the user to choose how to import a metadata element. Gives the option of renaming the element to a certain value of a certain set, or adding to a selected set. 660 660 * @param name The name of the original metadata as a String. 661 * @param set The set previously choosen as the default set for this metadata (which it doesn't match somehow).662 661 * @return An ElementWrapper around the element that it has been matched to. 663 662 * @see org.greenstone.gatherer.msm.MSMPrompt.MSMDialog -
trunk/gli/src/org/greenstone/gatherer/msm/MSMUtils.java
r6622 r6770 224 224 /** Method to compare two metadata elements (of type Element, which is bound to get more than a bit confusing) for equality. This test may only check the structural (ie pretty much unchanging) consistancy, or may include the AssignedValue tree as well (which will be different for each collection I'd imagine). 225 225 * @param a_set The <strong>MetadataSet</strong> a comes from. 226 * @param a An <strong>Element</strong>.226 * @param ae An <strong>Element</strong>. 227 227 * @param b_set The <strong>MetadataSet</strong> b comes from. 228 * @param b The <strong>Element</strong> to compare it to.228 * @param be The <strong>Element</strong> to compare it to. 229 229 * @param values <i>true</i> if the AssignedValues tree should also be compared, <i>false</i> otherwise. 230 230 * @return <i>true</i> if the elements are equal, <i>false</i> otherwise. -
trunk/gli/src/org/greenstone/gatherer/msm/MetadataComboBoxModel.java
r5589 r6770 44 44 import org.w3c.dom.*; 45 45 46 /** A combobox model that contains information from an array of NodeLists. */ 46 /** A combobox model that contains information from the metadata set manager. 47 * @see org.greenstone.gatherer.msm.MetadataSetManager*/ 47 48 public class MetadataComboBoxModel 48 49 extends DefaultComboBoxModel … … 50 51 private MetadataSetManager msm = null; 51 52 /** Constructor. 52 * @param nodelists The <strong>NodeList[]</strong> this model is proxied to.53 * @param msm The <strong>MetadataSetManager</strong> this model is proxied to. 53 54 */ 54 55 public MetadataComboBoxModel(MetadataSetManager msm) { -
trunk/gli/src/org/greenstone/gatherer/msm/MetadataSet.java
r6568 r6770 552 552 * @see org.greenstone.gatherer.Configuration#getLanguage() 553 553 * @see org.greenstone.gatherer.Gatherer#config 554 * @see org.greenstone.gatherer.msm.MSMUtils#getValue( Element)554 * @see org.greenstone.gatherer.msm.MSMUtils#getValue(Node) 555 555 * @see org.greenstone.gatherer.util.StaticStrings#CODE_ATTRIBUTE 556 556 * @see org.greenstone.gatherer.util.StaticStrings#SETLANGUAGE_ELEMENT -
trunk/gli/src/org/greenstone/gatherer/msm/MetadataSetManager.java
r6394 r6770 100 100 101 101 /** Attach a piece of metadata to a record or records, ensuring the value tree is built properly, and correct messaging fired. 102 * @param id 102 103 * @param records A FileNode[] of records, or directories, to add the specified metadata to. 103 104 * @param element The metadata element, contained within an ElementWrapper to base metadata on. 104 * @param value The value to assign to the metadata as a String.105 * @param value_str The value to assign to the metadata as a String. 105 106 */ 106 107 public Metadata addMetadata(long id, FileNode records[], ElementWrapper element, String value_str) { … … 169 170 } 170 171 171 /** Add a value tree to a given metadata element. 172 * @param element The ElementWrapper containing the element you wish to add a value tree for. 173 * @param value_tree The root Element of the value tree. 172 /** Add a value tree to a given metadata element represented as a GValueModel 173 * @param model The <strong>GValueTree</strong> model 174 174 */ 175 175 public void addValueTree(GValueModel model) { … … 686 686 } 687 687 /** This method takes two metadata sets, the current one and a new one, and merges them. This merge takes place at an element level falling to lower levels as necessary (using <i>mergeMDE()</i> to merge elements and <i>mergeMDV()</i> to merge value trees. 688 * @param mds_cur rentThe currently loaded MetadataSet.688 * @param mds_cur The currently loaded MetadataSet. 689 689 * @param mds_new A new MetadataSet you wish to merge in. 690 690 * @return A boolean with value <i>true</i> indicating if the merge was successful, otherwise <i>false</i> if errors were detected. … … 1041 1041 1042 1042 /** Update a piece of metadata connected to a record or records, ensuring the value tree is built properly, and correct messaging fired. 1043 * @param id 1044 * @param old_metadata The metadata element, 1043 1045 * @param records A FileNode[] of records, or directories, to add the specified metadata to. 1044 * @param element The metadata element, contained within an ElementWrapper to base metadata on. 1045 * @param value The value to assign to the metadata as a String. 1046 * @param value_str The value to assign to the metadata as a String. 1046 1047 * @param action The default action to take in the prompt. 1047 1048 * @param file_level If true then the metadata can be replaced normally, if false then we should actually use an add method instead. … … 1092 1093 * @param data the new Metadata. 1093 1094 * @param action the default action as an int. May require user interaction. 1094 * @param fire_event <i>true</i> if this action should fire a metadata changed event, <i>false</i> if we are calling this as an affect of a previous event. (Don't want an infinitely recursive loop, do we).1095 1095 * @param multiple_selection <i>true</i> if more than one file or folder was selected. 1096 1096 * @return an int specifying the current action. Thus changes in lower parts of the tree continue to effect other disjoint subtrees. … … 1194 1194 * @param data the <strong>Metadata</strong> you wish removed from the tree. 1195 1195 * @param action an <i>int</i> specifying the wanted prompting action. 1196 * @param fire_event <i>true</i> if this action should fire metadata changed events.1197 1196 * @param multiple_selection the number of records in the selection, as an <i>int</i>. Used to determine prompt controls. 1198 1197 * @return an <i>int</i> specifying the current action. Thus changes in lower parts of the tree continue to effect other disjoint subtrees. -
trunk/gli/src/org/greenstone/gatherer/msm/parsers/GreenstoneMetadataParser.java
r6539 r6770 688 688 extends LinkedHashMap { 689 689 /** Retrieve the CollectCFG object that matches the given collection file path. 690 * @param collect ion_file The <strong>File</strong> that references the collection's directory.690 * @param collect_cfg_file The <strong>File</strong> that references the collection's directory. 691 691 * @return The <strong>CollectCFG</strong> that belongs to this collection, or <i>null</i> if no such file exists (so we probably aren't in a collection!). 692 692 */ -
trunk/gli/src/org/greenstone/gatherer/util/ArrayTools.java
r6171 r6770 458 458 } 459 459 /** Compare two files for equality, in terms of their file paths. 460 * @param obj ectThe <strong>Object</strong> representing the file we are about to compare ourselves to.460 * @param obj The <strong>Object</strong> representing the file we are about to compare ourselves to. 461 461 * @return <i>true</i> if we equal the given file, <i>false</i> otherwise. 462 462 */ -
trunk/gli/src/org/greenstone/gatherer/util/Utility.java
r6637 r6770 465 465 466 466 /** Method which constructs the archive directory given a certain collection. 467 * @param col_dir The location of the collection directory as a <strong>String</strong>. 467 * @param gsdl_path The location of the greenstone installation as a <strong>String</strong>. 468 * @param col_name The collection name 468 469 * @return The location of the given collections archive directory, also as a <strong>String</strong>. 469 470 */ … … 884 885 } 885 886 /** Method to strip new lines and extra spaces from a string. Used to restore text that has been mangled into width formatted blocks by the DOM parser. 886 * @param raw The <strong>Strong</strong> containing the mangled text.887 * @param raw_str The <strong>Strong</strong> containing the mangled text. 887 888 * @return A <strong>String</strong> with new lines and extra spaces removed. 888 889 */ -
trunk/gli/src/org/greenstone/gatherer/valuetree/GValueModel.java
r6069 r6770 147 147 148 148 /** Retrieve a value node given its hierarchical reference or value. 149 * @param index The hierarchy index or value as a <strong>String</strong>.149 * @param index_str The hierarchy index or value as a <strong>String</strong>. 150 150 */ 151 151 public GValueNode getValue(String index_str) {
Note:
See TracChangeset
for help on using the changeset viewer.