|
LanguageResource |
|
1 /* 2 * LanguageResource.java 3 * 4 * Copyright (c) 1998-2001, The University of Sheffield. 5 * 6 * This file is part of GATE (see http://gate.ac.uk/), and is free 7 * software, licenced under the GNU Library General Public License, 8 * Version 2, June 1991 (in the distribution as file licence.html, 9 * and also available at http://gate.ac.uk/gate/licence.html). 10 * 11 * Hamish Cunningham, 11/Feb/2000 12 * 13 * $Id: LanguageResource.java,v 1.10 2001/11/13 17:09:57 marin Exp $ 14 */ 15 16 package gate; 17 18 import java.util.*; 19 import java.io.*; 20 21 import gate.util.*; 22 import gate.persist.*; 23 import gate.security.SecurityException; 24 25 /** Models all sorts of language resources. 26 */ 27 public interface LanguageResource extends Resource 28 { 29 /** Get the data store that this LR lives in. Null for transient LRs. */ 30 public DataStore getDataStore(); 31 32 /** Set the data store that this LR lives in. */ 33 public void setDataStore(DataStore dataStore) throws PersistenceException; 34 35 /** Returns the persistence id of this LR, if it has been stored in 36 * a datastore. Null otherwise. 37 */ 38 public Object getLRPersistenceId(); 39 40 /** Sets the persistence id of this LR. To be used only in the 41 * Factory and DataStore code. 42 */ 43 public void setLRPersistenceId(Object lrID); 44 45 /** Save: synchonise the in-memory image of the LR with the persistent 46 * image. 47 */ 48 public void sync() throws PersistenceException,SecurityException; 49 50 } // interface LanguageResource 51
|
LanguageResource |
|