// // DirObject.java // // WELD Java Client Persistent Object Management Package // Copyright Francis Chan (fchan@ic.eecs.berkeley.edu), 1997 // University of California, Berkeley // // // This program is in the public domain. // Permission to use, copy, modify, and distribute this software // and its documentation for NON-COMMERCIAL purposes and // without fee is hereby granted, as long as credit is given. import java.util.Vector; import java.io.StreamTokenizer; /** * * DirObject Class * * This is a class which represents a node of the directory * structure of a remote data server * * @version 1.1 Feb 1997 * @author Francis Chan */ public class DirObject extends PersistentObject{ public static final String objectClassName = "DirObject"; public static final int numField = 1; public static final int numObjField = 0; /** * The name of the directory */ private String name; /** * Vector that contains the contents' info */ public Vector contentsInfo; //private Vector objVector; /** * Constructor for DirObject */ public DirObject(String name){ this.name = name; netObjSetup(numField, numObjField, objectClassName); } /** * Returns the name of the directory (object) */ public String getName(){ return name; } /** * * Delete * * Removes all references of the PersistentObject in the system * (The object is not explicitly deleted (i.e. space freed)) * */ public void delete() { PersistentObject pObj; DirObject dObj; for (int i=0; i