< prev index next >

src/hotspot/share/memory/filemap.hpp

Print this page




  39 //  read-only space
  40 //  misc data (block offset table, string table, symbols, dictionary, etc.)
  41 //  tag(666)
  42 
  43 static const int JVM_IDENT_MAX = 256;
  44 
  45 class SharedClassPathEntry {
  46 protected:
  47   bool   _is_dir;
  48   time_t _timestamp;          // jar/jimage timestamp,  0 if is directory or other
  49   long   _filesize;           // jar/jimage file size, -1 if is directory, -2 if other
  50   Array<char>* _name;
  51   Array<u1>*   _manifest;
  52   bool _is_signed;
  53 
  54 public:
  55   void init(const char* name, TRAPS);
  56   void metaspace_pointers_do(MetaspaceClosure* it);
  57   bool validate(bool is_class_path = true);
  58 
  59   // The _timestamp only gets set for jar files and "modules" jimage.
  60   bool is_jar_or_bootimage() {
  61     return _timestamp != 0;
  62   }
  63   bool is_dir() { return _is_dir; }
  64   bool is_modules_image() { return ClassLoader::is_modules_image(name()); }
  65   time_t timestamp() const { return _timestamp; }
  66   long   filesize()  const { return _filesize; }
  67   const char* name() const { return _name->data(); }
  68   const char* manifest() const {
  69     return (_manifest == NULL) ? NULL : (const char*)_manifest->data();
  70   }
  71   int manifest_size() const {
  72     return (_manifest == NULL) ? 0 : _manifest->length();
  73   }
  74   void set_manifest(Array<u1>* manifest) {
  75     _manifest = manifest;
  76   }
  77   void set_is_signed(bool s) {
  78     _is_signed = s;
  79   }
  80   bool is_signed() {




  39 //  read-only space
  40 //  misc data (block offset table, string table, symbols, dictionary, etc.)
  41 //  tag(666)
  42 
  43 static const int JVM_IDENT_MAX = 256;
  44 
  45 class SharedClassPathEntry {
  46 protected:
  47   bool   _is_dir;
  48   time_t _timestamp;          // jar/jimage timestamp,  0 if is directory or other
  49   long   _filesize;           // jar/jimage file size, -1 if is directory, -2 if other
  50   Array<char>* _name;
  51   Array<u1>*   _manifest;
  52   bool _is_signed;
  53 
  54 public:
  55   void init(const char* name, TRAPS);
  56   void metaspace_pointers_do(MetaspaceClosure* it);
  57   bool validate(bool is_class_path = true);
  58 
  59   // The _timestamp only gets set for jar files.
  60   bool has_timestamp() {
  61     return _timestamp != 0;
  62   }
  63   bool is_dir() { return _is_dir; }
  64   bool is_modules_image() { return ClassLoader::is_modules_image(name()); }
  65   time_t timestamp() const { return _timestamp; }
  66   long   filesize()  const { return _filesize; }
  67   const char* name() const { return _name->data(); }
  68   const char* manifest() const {
  69     return (_manifest == NULL) ? NULL : (const char*)_manifest->data();
  70   }
  71   int manifest_size() const {
  72     return (_manifest == NULL) ? 0 : _manifest->length();
  73   }
  74   void set_manifest(Array<u1>* manifest) {
  75     _manifest = manifest;
  76   }
  77   void set_is_signed(bool s) {
  78     _is_signed = s;
  79   }
  80   bool is_signed() {


< prev index next >