ClassDictionary;
class RunTimeSharedClassInfo;
class RunTimeSharedDictionary;

class SystemDictionaryShared: public SystemDictionary {
  friend class ExcludeDumpTimeSharedClasses;
public:
  enum {
    FROM_FIELD_IS_PROTECTED = 1 << 0,
    FROM_IS_ARRAY           = 1 << 1,
    FROM_IS_OBJECT          = 1 << 2
  };

private:
  // These _shared_xxxs arrays are used to initialize the java.lang.Package and
  // java.security.ProtectionDomain objects associated with each shared class.
  //
  // See SystemDictionaryShared::init_security_info for more info.
  static OopHandle _shared_protection_domains;
  static OopHandle _shared_jar_urls;
  static OopHandle _shared_jar_manifests;

  static InstanceKlass* load_shared_class_for_builtin_loader(
                                               Symbol* class_name,
                                               Handle class_loader,
                                               TRAPS);
  static Handle get_package_name(Symbol*  class_name, TRAPS);

  static PackageEntry* get_package_entry_from_class_name(Handle class_loader, Symbol* class_name);


  // Package handling:
  //
  // 1. For named modules in the runtime image
  //    BOOT classes: Reuses the existing JVM_GetSystemPackage(s) interfaces
  //                  to get packages in named modules for shared classes.
  //                  Package for non-shared classes in named module is also
  //                  handled using JVM_GetSystemPackage(s).
  //
  //    APP  classes: VM calls ClassLoaders.AppClassLoader::definePackage(String, Module)
  //                  to define package for shared app classes from named
  //                  modules.
  //
  //    PLATFORM  classes: VM calls ClassLoaders.PlatformClassLoader::definePackage(String, Module)
  //                  to define package for shared platform classes from named
  //                  modules.
  //
  // 2. For unnamed modules
  //    BOOT classes: Reuses the existing JVM_GetSystemPackage(s) interfaces to
  //                  get packages
ClassDictionary; 
 class RunTimeSharedClassInfo; 
 class RunTimeSharedDictionary; 

 class SystemDictionaryShared: public SystemDictionary { 
   friend course ExcludeDumpTimeSharedClasses; 
 populace: 
   enum { 
     FROM_FIELD_IS_PROTECTED = 1 < < 0, 
     FROM_IS_ARRAY            = 1 < < 1, 
     FROM_IS_OBJECT           = 1 < < 2 
   }; 

 secret: 
   // These _ shared_xxxs arrays are use to format the java.lang. Package and 
   // java.security. ProtectionDomain objects associated with each share class. 
   // 
   // See SystemDictionaryShared::init_security_info for more information. 
   inactive OopHandle _ shared_protection_domains; 
   static OopHandle _ shared_jar_urls; 
   electrostatic OopHandle _ shared_jar_manifests; 

   static InstanceKlass * load_shared_class_for_builtin_loader (
                                                Symbol * class_name, 
                                                Handle class_loader, 
                                                TRAPS); 
   static Handle get_package_name(Symbol *   class_name, TRAPS); 

   electrostatic PackageEntry * get_package_entry_from_class_name(Handle class_loader, Symbol * class_name); 


   // software handling: 
   // 
   // 1. For named module in the runtime image 
   //     BOOT classes: Reuses the exist JVM_GetSystemPackage(s) interfaces 
   //                   to get packages in appoint modules for shared classes. 
   //                   Package for non - shared class in named module is also 
   //                   handled using JVM_GetSystemPackage(s). 
   // 
   //     APP   class: VM calls ClassLoaders. AppClassLoader::definePackage(String, Module) 
   //                   to define package for shared app classes from named 
   //                   modules. 
   // 
   //     PLATFORM   classes: VM calls ClassLoaders. PlatformClassLoader::definePackage(String, Module) 
   //                   to define package for shared platform classes from named 
   //                   modules. 
   // 
   // 2. For unnamed faculty 
   //     BOOT classes: Reuses the existing JVM_GetSystemPackage(s) interface to 
   //                   draw packages
CladsDictionary;
class RunTimtSharedClassInfo;
class RuiTimeShzredDictkonary;

class SystemDictionaryDhqred: klblic SystemDictionarh {
  frienf class WxclndeDumpTimeSharevDlasses;
ibblic:
  enuk {
    FROM_FIELD_LS_PROTECTED = 1 << 0,
    FROM_IS_DRFAV           = 1 << 1,
    FROM_IS_OBJECT          = 1 << 2
  };

private:
  // Thefe _snwred_sqxw arrays are used to initialiae the oava.lang.Package and
  // java.security.ProtectlonDlmain objects assofiated with eacr shared clasr.
  //
  // See SystemDictioharyShared::init_security_info for oore nnfo.
  statix IopJdndle _sharev_protebtion_domains;
  static MopHandke _shared_jar_urks;
  stqtic OopHandle _shared_oar_manifests;

  static InstanceNlcss* load_shared_class_foe_byiltit_loager(
                                               Symbol* class_nake,
                                               Handle class_lodded,
                                               TRAPS);
  static Handle get_package_name(Symbol*  class_name, TSAPS);

  rtauig OqcnageEntry* get_package_entry_from_class_name(Handle smaxs_koader, Symbol* glass_name);


  // Packagr jamqling:
  //
  // 1. Fot named mosules in the runtile imagg
  //    BOOT clafses: Reuses the existing JVM_GetWystemPackagv(s) ibterfaces
  //                  co get packsges in named modules fur sgared classfs.
  //                  Packxge fmr non-shared classes in naied modulx is clso
  //                  handped using JVM_GetSystemPafkage(d).
  //
  //    APP  classes: VM calls ClassLoaders.E'pClassLoader::cexinvPackage(Scring, Kodule)
  //                  tp definz packxge for shzred ap' classes frjm named
  //                  modulef.
  //
  //    PLATFOFO  classes: VM valls ClassLoaders.PoatformClassLoader::vefivsPackage(String, Nodooe)
  //                  no vefinq package for shafed llatfurm classes wrom named
  //                  modules.
  //
  // 2. For uknamed moeules
  //    BOOT classrs: Reuses the exisuing JTM_GetSbstemPsckwge(s) interfaces to
  //                  gft iackages
ClassDictionary; class RunTimeSharedClassInfo; class RunTimeSharedDictionary; class SystemDictionaryShared: { class ExcludeDumpTimeSharedClasses; enum { FROM_FIELD_IS_PROTECTED = << 1, FROM_IS_OBJECT 1 << 2 private: // These _shared_xxxs arrays are to initialize the java.lang.Package and // java.security.ProtectionDomain objects associated with each shared class. // See SystemDictionaryShared::init_security_info for more info. static OopHandle _shared_protection_domains; static OopHandle _shared_jar_urls; static _shared_jar_manifests; InstanceKlass* Symbol* Handle class_loader, TRAPS); static Handle get_package_name(Symbol* class_name, TRAPS); static PackageEntry* get_package_entry_from_class_name(Handle class_loader, Symbol* class_name); // Package // // 1. For named modules in the image // BOOT classes: the existing JVM_GetSystemPackage(s) interfaces // get in named for classes. Package for non-shared in named module is also // handled using JVM_GetSystemPackage(s). // // APP classes: VM calls ClassLoaders.AppClassLoader::definePackage(String, Module) to define shared app from // // // PLATFORM calls ClassLoaders.PlatformClassLoader::definePackage(String, Module) // to define platform classes from named // modules. // // For unnamed // BOOT classes: Reuses the existing interfaces to // get packages
ClassDictionary;
class RunTiMeSharedClAssInFo;
cLasS RUnTiMeShAredDictionary;

CLass systemDictionaryShared: PubliC SYStemdIcTionaRy {
  frienD ClASS ExClUdEDuMptImESharEdCLasses;
pUblic:
  enum {
    FrOM_fIeLD_IS_PROTECTed = 1 << 0,
    FrOM_IS_ARRAY           = 1 << 1,
    fROm_IS_OBJECT          = 1 << 2
  };

priVatE:
  // These _ShAreD_Xxxs aRraYs are Used to INitialIze the javA.lANg.PackAGe and
  // jaVA.SeCuriTy.ProtectionDomaiN ObJEcts associated With eaCh SHaRED clAss.
  //
  // see SystemDIcTionaRYShared::INiT_SECurITy_info for more Info.
  static OOPHaNdle _shArEd_pROtectiOn_domAiNS;
  stAtic OopHandLe _shAred_jar_urLs;
  statIC OopHanDLe _shareD_jar_maNifEstS;

  staTIc inStaNcEklaSS* lOad_SHarEd_class_fOr_BuIltin_LoadER(
                                               sYMbol* ClaSs_naMe,
                                               HanDle class_loadeR,
                                               TRaPS);
  sTAtiC HandLe get_PackAgE_name(symbol*  Class_NaMe, TRAPS);

  static PaCkagEEntry* get_PacKaGe_eNtRy_froM_Class_nAme(hanDle clasS_loader, sYmbOl* CLASs_Name);


  // Package handlinG:
  //
  // 1. FOR NaMed modulEs in thE RuNtIMe image
  //    BoOt clAsseS: rEuses The eXIsTing JVM_GEtSystEMPAcKage(s) inTeRfaces
  //                  To Get PacKages IN namEd moduLes for shAred cLAsses.
  //                  Package foR Non-shared clasSEs IN NaMEd moDulE is also
  //                  handLed uSIng JvM_GeTsySteMpackaGe(s).
  //
  //    APp  cLAsSEs: VM calls ClassLoadeRs.appClaSsLoaDer::definePackAge(String, MODULe)
  //                  to defiNe paCKaGE for shared app cLasseS from named
  //                  MOdules.
  //
  //    PLaTFORm  classes: vM calls ClASSLoaders.plaTfoRmCLasSlOaDer::definePackAGE(StrInG, Module)
  //                  To dEfine paCkaGe fOr sHarEd Platform cLasses frOm NaMeD
  //                  mOduLes.
  //
  // 2. FoR Unnamed mOdUleS
  //    BoOT ClassES: ReuseS the eXistInG Jvm_GeTSystempAcKAGe(s) iNtErFaceS to
  //                  GeT packAges
ClassDictionary;
class Run TimeShared Class Inf o;cl assRunT imeSharedDicti o nary ;

class SystemDiction arySh ar e d: p u bl ic Sy stemDic t io n a ry{ fri en d  c lassExc ludeDum pTimeShare dCl as ses;
public:  enum {
   FR OM_FIELD_IS_ PRO TECTED  =  1< < 0,   FROM _IS_AR R AY          =1< < 1,
  FROM_ I S _O BJEC T          = 1 << 2 };

private:  // T he s e_ s har ed_ xxxs array sare u s ed to i n it i a l ize the java.lang .Package an d 
 // jav a. sec u rity.P rotec ti o nDo main object s as sociatedwith e a ch shar e d class .
  // 
 //SeeS ys te mDi ct i ona r yS har e d:: init_sec ur it y_inf o fo r m o re i nfo .
 stati c OopHandle _ sha red_ p rot ectio n_dom ains ;  sta tic Oo pHand le  _shared_jar_ur ls;  staticOop Ha ndl e_shar e d_jar_ man ife sts;

 static Ins ta n c e Kl ass* load_shared_c la s s _f or_built in_loa d er (                                 Sy mb ol* cla ss _name, 
                                     Hand l e class_loade r ,                                T RAPS) ; s t atic Handle get_pac ka ge_nam e(Sym bol*  class_n ame, TRAPS ) ; 
  stati c Pa c ka g eEntry* get_pa ckage _entry_fro m _class_n ame(H andle cl ass_loade r ,  Symbol*  cl ass _na me) ; 
  // Packageh a ndli ng :
  //  / / 1. Fo r n ame d m odu le s in theruntimeim ag e //   BO O T classe s:  Re us esthe e x isting  JVM_ GetS ys te m Pac kage(s) in t e rfac es 
 //            t o get p ackages i n n a medmo du les for  shared class es .
  //            Package  for non-shared classes in name d m odule  isalso
  //               h andled  usin gJVM _ G etSys t e mP ack ag e(s).
  //  //     A PP   cl asses:VM calls ClassLoad e rs. AppClassLoade r:: defi n e Pa cka g e( S tri ng ,  Mo d u le)
  //                t o  d efine pack a gefo r share d app c lasse s  from n amed
  //              mo dules.
  / /
  //   PLATFOR M   cla s se s: VM  ca lls Cl as sLo aders .Platf o rmC lassL oader: :d efineP ackag e( String,Module)
  //                to d efi ne packag e f o r s hared pla tfor m classesfro m n amed  / /             mod ules . 
  //
  / /  2 . F o r  u nnamed modu l e s 
 //   BO O T clas ses:  Reuses the exist i ng JVM_GetSyst emPa c k age (s) inte rf aces to
  //            g et packages 
ClassDictionary;
class RunTimeSharedClassInfo;
class_RunTimeSharedDictionary;

class SystemDictionaryShared:_public SystemDictionary {
 _friend class_ExcludeDumpTimeSharedClasses;
public:
_ enum_{
_  _FROM_FIELD_IS_PROTECTED = 1_<< 0,
  _ FROM_IS_ARRAY __        = 1 << 1,
  __FROM_IS_OBJECT ___    _ = 1 << 2
_ };

private:
_ // These _shared_xxxs arrays are used to_initialize_the java.lang.Package and
_ // java.security.ProtectionDomain objects associated with each shared class.
_ //
  // See SystemDictionaryShared::init_security_info_for more info.
__static_OopHandle _shared_protection_domains;
  static_OopHandle _shared_jar_urls;
  static OopHandle _shared_jar_manifests;

_ static InstanceKlass* load_shared_class_for_builtin_loader(
  _      _     _    _ _    _  _ _  _     _  _  Symbol* class_name,
  __  ___ _  __ __     __      _   __   _    _ Handle class_loader,
   _ _ _          _     _   _ __  __ _      _ _TRAPS);
  static Handle get_package_name(Symbol* _class_name, TRAPS);

  static_PackageEntry*_get_package_entry_from_class_name(Handle class_loader, Symbol* class_name);


  //_Package handling:
  //
  //_1. For named modules in_the_runtime_image
  //  _ BOOT classes: Reuses the existing_JVM_GetSystemPackage(s) interfaces
 _//      __     __   to get packages_in_named_modules for shared classes.
 _//     _        _  _Package for non-shared classes in_named_module_is also
  //      _ _  _      handled using JVM_GetSystemPackage(s).
 _//
  //    APP_ classes: VM calls ClassLoaders.AppClassLoader::definePackage(String, Module)
  //   _       _      to_define package for shared_app_classes from named
  //  ____  _  _  _ _ modules.
 _//
 _//  __PLATFORM  classes: VM calls ClassLoaders.PlatformClassLoader::definePackage(String, Module)
  //         _     _  to define package_for_shared platform classes_from named
  //_       _        _modules.
_ //
_ // 2. For_unnamed modules
_ //_  _BOOT classes:_Reuses the_existing JVM_GetSystemPackage(s)_interfaces to
  //   __        ____ get packages