< prev index next >

src/hotspot/share/oops/klass.hpp

Print this page

552   bool is_subclass_of(const Klass* k) const;
553 
554   // subtype check: true if is_subclass_of, or if k is interface and receiver implements it
555   bool is_subtype_of(Klass* k) const;
556 
557 public:
558   // Find LCA in class hierarchy
559   Klass *LCA( Klass *k );
560 
561   // Check whether reflection/jni/jvm code is allowed to instantiate this class;
562   // if not, throw either an Error or an Exception.
563   virtual void check_valid_for_instantiation(bool throwError, TRAPS);
564 
565   // array copying
566   virtual void  copy_array(arrayOop s, int src_pos, arrayOop d, int dst_pos, int length, TRAPS);
567 
568   // tells if the class should be initialized
569   virtual bool should_be_initialized() const    { return false; }
570   // initializes the klass
571   virtual void initialize(TRAPS);

572   virtual Klass* find_field(Symbol* name, Symbol* signature, fieldDescriptor* fd) const;
573   virtual Method* uncached_lookup_method(const Symbol* name, const Symbol* signature,
574                                          OverpassLookupMode overpass_mode,
575                                          PrivateLookupMode = PrivateLookupMode::find) const;
576  public:
577   Method* lookup_method(const Symbol* name, const Symbol* signature) const {
578     return uncached_lookup_method(name, signature, OverpassLookupMode::find);
579   }
580 
581   // array class with specific rank
582   virtual ArrayKlass* array_klass(int rank, TRAPS) = 0;
583 
584   // array class with this klass as element type
585   virtual ArrayKlass* array_klass(TRAPS) = 0;
586 
587   // These will return null instead of allocating on the heap:
588   virtual ArrayKlass* array_klass_or_null(int rank) = 0;
589   virtual ArrayKlass* array_klass_or_null() = 0;
590 
591   virtual oop protection_domain() const = 0;

552   bool is_subclass_of(const Klass* k) const;
553 
554   // subtype check: true if is_subclass_of, or if k is interface and receiver implements it
555   bool is_subtype_of(Klass* k) const;
556 
557 public:
558   // Find LCA in class hierarchy
559   Klass *LCA( Klass *k );
560 
561   // Check whether reflection/jni/jvm code is allowed to instantiate this class;
562   // if not, throw either an Error or an Exception.
563   virtual void check_valid_for_instantiation(bool throwError, TRAPS);
564 
565   // array copying
566   virtual void  copy_array(arrayOop s, int src_pos, arrayOop d, int dst_pos, int length, TRAPS);
567 
568   // tells if the class should be initialized
569   virtual bool should_be_initialized() const    { return false; }
570   // initializes the klass
571   virtual void initialize(TRAPS);
572   virtual void initialize_preemptable(TRAPS);
573   virtual Klass* find_field(Symbol* name, Symbol* signature, fieldDescriptor* fd) const;
574   virtual Method* uncached_lookup_method(const Symbol* name, const Symbol* signature,
575                                          OverpassLookupMode overpass_mode,
576                                          PrivateLookupMode = PrivateLookupMode::find) const;
577  public:
578   Method* lookup_method(const Symbol* name, const Symbol* signature) const {
579     return uncached_lookup_method(name, signature, OverpassLookupMode::find);
580   }
581 
582   // array class with specific rank
583   virtual ArrayKlass* array_klass(int rank, TRAPS) = 0;
584 
585   // array class with this klass as element type
586   virtual ArrayKlass* array_klass(TRAPS) = 0;
587 
588   // These will return null instead of allocating on the heap:
589   virtual ArrayKlass* array_klass_or_null(int rank) = 0;
590   virtual ArrayKlass* array_klass_or_null() = 0;
591 
592   virtual oop protection_domain() const = 0;
< prev index next >