Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #37442
| Path | csiph.com!weretis.net!feeder4.news.weretis.net!news.albasani.net!.POSTED!not-for-mail |
|---|---|
| From | j4n bur53 <janburse@fastmail.fm> |
| Newsgroups | comp.lang.java.programmer |
| Subject | Re: Are Outer Classes Loaded Lazily? |
| Date | Thu, 21 Sep 2017 09:29:59 +0200 |
| Organization | albasani.net |
| Lines | 19 |
| Message-ID | <opvppn$ki7$1@news.albasani.net> (permalink) |
| References | <opu86b$k29$1@news.albasani.net> <opunhc$c73$1@dont-email.me> <opusvk$5se$1@news.albasani.net> <86b111bd-47de-45c4-8132-d3a5b67ce4f4@googlegroups.com> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=UTF-8; format=flowed |
| Content-Transfer-Encoding | 7bit |
| X-Trace | news.albasani.net n2Tie64+cbFZSM0h9zwjj31jYJTYJJ65cF3CMZpA6PtwfYB+NCdRFKqUdEiBVBfhuhZcTWId+0fEVMg2yJ2i6g== |
| NNTP-Posting-Date | Thu, 21 Sep 2017 07:29:59 +0000 (UTC) |
| Injection-Info | news.albasani.net; logging-data="Q2ePUtdEy7P/HRVtVeUWJ+aqPNfTtgDnPt1EpGWFzPfV6qlGcLdAHN3t0kBtpC0AJr3R1gQZHCotQBfWph1sOoQTX6GlNy2gMuV5ZPvribd6n+EwhtiX+R87YIXvq6t6"; mail-complaints-to="abuse@albasani.net" |
| User-Agent | Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:51.0) Gecko/20100101 Firefox/51.0 SeaMonkey/2.48 |
| In-Reply-To | <86b111bd-47de-45c4-8132-d3a5b67ce4f4@googlegroups.com> |
| Cancel-Lock | sha1:bUCdLobFEbys/LO6WMvMV377tuY= |
| Xref | csiph.com comp.lang.java.programmer:37442 |
Show key headers only | View raw
But not all class properties. For example the super class
is loaded before the class. So this API method of Class:
getSuperclass()
is not lazy. Now question is whether for named nested
classes, that are static (or non-static without references
to the outer class), whether this method, is lazy or not:
getDeclaringClass()
lewbloch@gmail.com schrieb:
> Pretty much all classes in Java are lazily loaded and lazily initialized.
>
> Since an inner class by definition in Java is non-static, I don't know how you could get the inner class without initializing the outer, but I have yet to peruse the JLS to explore that.
>
> For static nested classes it makes sense that getting the enclosing class would load the class, but since that's not one of the actions that initializes a class it would be improper for that to initialize the outer class.
>
Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Are Outer Classes Loaded Lazily? j4n bur53 <janburse@fastmail.fm> - 2017-09-20 19:23 +0200
Re: Are Outer Classes Loaded Lazily? Eric Sosman <esosman@comcast-dot-net.invalid> - 2017-09-20 17:45 -0400
Re: Are Outer Classes Loaded Lazily? j4n bur53 <janburse@fastmail.fm> - 2017-09-21 01:18 +0200
Re: Are Outer Classes Loaded Lazily? lewbloch@gmail.com - 2017-09-20 17:28 -0700
Re: Are Outer Classes Loaded Lazily? j4n bur53 <janburse@fastmail.fm> - 2017-09-21 09:29 +0200
Re: Are Outer Classes Loaded Lazily? j4n bur53 <janburse@fastmail.fm> - 2017-09-21 09:40 +0200
Re: Are Outer Classes Loaded Lazily? lewbloch@gmail.com - 2017-09-21 11:44 -0700
Re: Are Outer Classes Loaded Lazily? Marcel Mueller <news.5.maazl@spamgourmet.org> - 2017-09-21 21:18 +0200
Re: Are Outer Classes Loaded Lazily? Eric Sosman <esosman@comcast-dot-net.invalid> - 2017-09-21 16:20 -0400
Re: Are Outer Classes Loaded Lazily? j4n bur53 <janburse@fastmail.fm> - 2017-09-22 11:12 +0200
Re: Are Outer Classes Loaded Lazily? Joshua Cranmer 🐧 <Pidgeot18@verizon.invalid> - 2017-09-22 15:55 -0400
Re: Are Outer Classes Loaded Lazily? j4n bur53 <janburse@fastmail.fm> - 2017-09-23 18:33 +0200
Re: Are Outer Classes Loaded Lazily? lewbloch@gmail.com - 2017-09-22 13:48 -0700
Re: Are Outer Classes Loaded Lazily? Joshua Cranmer 🐧 <Pidgeot18@verizon.invalid> - 2017-09-22 23:46 -0400
Re: Are Outer Classes Loaded Lazily? lewbloch@gmail.com - 2017-09-25 13:23 -0700
Re: Are Outer Classes Loaded Lazily? j4n bur53 <janburse@fastmail.fm> - 2017-09-24 17:39 +0200
Re: Are Outer Classes Loaded Lazily? Eric Sosman <esosman@comcast-dot-net.invalid> - 2017-09-25 07:38 -0400
Re: Are Outer Classes Loaded Lazily? lewbloch@gmail.com - 2017-09-25 13:25 -0700
csiph-web