< prev index next >

src/hotspot/share/oops/klass.hpp

Print this page
rev 49172 : 8197405: Improve messages of AbstractMethodErrors and IncompatibleClassChangeErrors.
Reviewed-by: coleenp, dholmes, mdoerr, njian


 529   // Size of klass in word size.
 530   virtual int size() const = 0;
 531 #if INCLUDE_SERVICES
 532   virtual void collect_statistics(KlassSizeStats *sz) const;
 533 #endif
 534 
 535   // Returns the Java name for a class (Resource allocated)
 536   // For arrays, this returns the name of the element with a leading '['.
 537   // For classes, this returns the name with the package separators
 538   //     turned into '.'s.
 539   const char* external_name() const;
 540   // Returns the name for a class (Resource allocated) as the class
 541   // would appear in a signature.
 542   // For arrays, this returns the name of the element with a leading '['.
 543   // For classes, this returns the name with a leading 'L' and a trailing ';'
 544   //     and the package separators as '/'.
 545   virtual const char* signature_name() const;
 546 
 547   const char* class_loader_and_module_name() const;
 548 



 549   // type testing operations
 550 #ifdef ASSERT
 551  protected:
 552   virtual bool is_instance_klass_slow()     const { return false; }
 553   virtual bool is_array_klass_slow()        const { return false; }
 554   virtual bool is_objArray_klass_slow()     const { return false; }
 555   virtual bool is_typeArray_klass_slow()    const { return false; }
 556 #endif // ASSERT
 557  public:
 558 
 559   // Fast non-virtual versions
 560   #ifndef ASSERT
 561   #define assert_same_query(xval, xcheck) xval
 562   #else
 563  private:
 564   static bool assert_same_query(bool xval, bool xslow) {
 565     assert(xval == xslow, "slow and fast queries agree");
 566     return xval;
 567   }
 568  public:




 529   // Size of klass in word size.
 530   virtual int size() const = 0;
 531 #if INCLUDE_SERVICES
 532   virtual void collect_statistics(KlassSizeStats *sz) const;
 533 #endif
 534 
 535   // Returns the Java name for a class (Resource allocated)
 536   // For arrays, this returns the name of the element with a leading '['.
 537   // For classes, this returns the name with the package separators
 538   //     turned into '.'s.
 539   const char* external_name() const;
 540   // Returns the name for a class (Resource allocated) as the class
 541   // would appear in a signature.
 542   // For arrays, this returns the name of the element with a leading '['.
 543   // For classes, this returns the name with a leading 'L' and a trailing ';'
 544   //     and the package separators as '/'.
 545   virtual const char* signature_name() const;
 546 
 547   const char* class_loader_and_module_name() const;
 548 
 549   // Returns "interface", "abstract class" or "class".
 550   const char* external_kind() const;
 551 
 552   // type testing operations
 553 #ifdef ASSERT
 554  protected:
 555   virtual bool is_instance_klass_slow()     const { return false; }
 556   virtual bool is_array_klass_slow()        const { return false; }
 557   virtual bool is_objArray_klass_slow()     const { return false; }
 558   virtual bool is_typeArray_klass_slow()    const { return false; }
 559 #endif // ASSERT
 560  public:
 561 
 562   // Fast non-virtual versions
 563   #ifndef ASSERT
 564   #define assert_same_query(xval, xcheck) xval
 565   #else
 566  private:
 567   static bool assert_same_query(bool xval, bool xslow) {
 568     assert(xval == xslow, "slow and fast queries agree");
 569     return xval;
 570   }
 571  public:


< prev index next >