491 // Size of klass in word size.
492 virtual int size() const = 0;
493 #if INCLUDE_SERVICES
494 virtual void collect_statistics(KlassSizeStats *sz) const;
495 #endif
496
497 // Returns the Java name for a class (Resource allocated)
498 // For arrays, this returns the name of the element with a leading '['.
499 // For classes, this returns the name with the package separators
500 // turned into '.'s.
501 const char* external_name() const;
502 // Returns the name for a class (Resource allocated) as the class
503 // would appear in a signature.
504 // For arrays, this returns the name of the element with a leading '['.
505 // For classes, this returns the name with a leading 'L' and a trailing ';'
506 // and the package separators as '/'.
507 virtual const char* signature_name() const;
508
509 const char* class_loader_and_module_name() const;
510
511 // type testing operations
512 #ifdef ASSERT
513 protected:
514 virtual bool is_instance_klass_slow() const { return false; }
515 virtual bool is_array_klass_slow() const { return false; }
516 virtual bool is_objArray_klass_slow() const { return false; }
517 virtual bool is_typeArray_klass_slow() const { return false; }
518 #endif // ASSERT
519 public:
520
521 // Fast non-virtual versions
522 #ifndef ASSERT
523 #define assert_same_query(xval, xcheck) xval
524 #else
525 private:
526 static bool assert_same_query(bool xval, bool xslow) {
527 assert(xval == xslow, "slow and fast queries agree");
528 return xval;
529 }
530 public:
|
491 // Size of klass in word size.
492 virtual int size() const = 0;
493 #if INCLUDE_SERVICES
494 virtual void collect_statistics(KlassSizeStats *sz) const;
495 #endif
496
497 // Returns the Java name for a class (Resource allocated)
498 // For arrays, this returns the name of the element with a leading '['.
499 // For classes, this returns the name with the package separators
500 // turned into '.'s.
501 const char* external_name() const;
502 // Returns the name for a class (Resource allocated) as the class
503 // would appear in a signature.
504 // For arrays, this returns the name of the element with a leading '['.
505 // For classes, this returns the name with a leading 'L' and a trailing ';'
506 // and the package separators as '/'.
507 virtual const char* signature_name() const;
508
509 const char* class_loader_and_module_name() const;
510
511 // Returns "interface", "abstract class" or "class".
512 const char* external_kind() const;
513
514 // type testing operations
515 #ifdef ASSERT
516 protected:
517 virtual bool is_instance_klass_slow() const { return false; }
518 virtual bool is_array_klass_slow() const { return false; }
519 virtual bool is_objArray_klass_slow() const { return false; }
520 virtual bool is_typeArray_klass_slow() const { return false; }
521 #endif // ASSERT
522 public:
523
524 // Fast non-virtual versions
525 #ifndef ASSERT
526 #define assert_same_query(xval, xcheck) xval
527 #else
528 private:
529 static bool assert_same_query(bool xval, bool xslow) {
530 assert(xval == xslow, "slow and fast queries agree");
531 return xval;
532 }
533 public:
|