Java 7 feature Q.

Discussion in 'Java' started by 00101010, Aug 13, 2011.

  1. 00101010

    00101010 Guest

    Did they, like promised, add the waka waka shortcut for the instance
    creation operator?
     
    00101010, Aug 13, 2011
    #1
    1. Advertising

  2. 00101010

    Lew Guest

    "00101010" wrote:
    > Did they, like promised, add the waka waka shortcut for the instance
    > creation operator?


    Of which "they" do you speak? There has never been a promise for Java to have a "waka waka" shortcut, whatever the heck that is, and Java doesn't have an instance creation operator.

    Could you please clarify your question?

    --
    Lew
     
    Lew, Aug 13, 2011
    #2
    1. Advertising

  3. Lew <> wrote:
    > "00101010" wrote:
    >> Did they, like promised, add the waka waka shortcut for the instance
    >> creation operator?

    > Of which "they" do you speak? There has never been a promise for Java
    > to have a "waka waka" shortcut, whatever the heck that is,
    > and Java doesn't have an instance creation operator.


    Isn't "new" an instance creation operator?

    I've got a vague idea what he might have meant with "waka waka",
    but I'll leave it to him to clarify.
     
    Andreas Leitgeb, Aug 13, 2011
    #3
  4. 00101010

    Lew Guest

    Andreas Leitgeb wrote:
    > Lew wrote:
    >> "00101010" wrote:
    >>> Did they, like promised, add the waka waka shortcut for the instance
    >>> creation operator?

    >> Of which "they" do you speak? There has never been a promise for Java
    >> to have a "waka waka" shortcut, whatever the heck that is,
    >> and Java doesn't have an instance creation operator.

    >
    > Isn't "new" an instance creation operator?


    No, it is not, because it is not a Java operator.

    --
    Lew
     
    Lew, Aug 13, 2011
    #4
  5. 00101010

    Arne Vajhøj Guest

    On 8/13/2011 3:17 AM, Andreas Leitgeb wrote:
    > Lew<> wrote:
    >> "00101010" wrote:
    >>> Did they, like promised, add the waka waka shortcut for the instance
    >>> creation operator?

    >> Of which "they" do you speak? There has never been a promise for Java
    >> to have a "waka waka" shortcut, whatever the heck that is,
    >> and Java doesn't have an instance creation operator.

    >
    > Isn't "new" an instance creation operator?
    >
    > I've got a vague idea what he might have meant with "waka waka",
    > but I'll leave it to him to clarify.


    It seems as a good guess that he is asking about <>.

    Arne
     
    Arne Vajhøj, Aug 13, 2011
    #5
  6. 00101010

    Lew Guest

    Arne Vajhøj wrote:
    > Andreas Leitgeb wrote:
    >> Lew wrote:
    >>> "00101010" wrote:
    >>>> Did they, like promised, add the waka waka shortcut for the instance
    >>>> creation operator?
    >>> Of which "they" do you speak? There has never been a promise for Java
    >>> to have a "waka waka" shortcut, whatever the heck that is,
    >>> and Java doesn't have an instance creation operator.

    >>
    >> Isn't "new" an instance creation operator?
    >>
    >> I've got a vague idea what he might have meant with "waka waka",
    >> but I'll leave it to him to clarify.

    >
    > It seems as a good guess that he is asking about <>.


    "seems", "guess"

    How much wrong code is out there based on what "seems as a good guess" about what is specified?

    --
    Lew
     
    Lew, Aug 13, 2011
    #6
  7. 00101010

    Lew Guest

    Arne Vajhøj wrote:
    > Andreas Leitgeb wrote:
    >> Lew wrote:
    >>> "00101010" wrote:
    >>>> Did they, like promised, add the waka waka shortcut for the instance
    >>>> creation operator?
    >>> Of which "they" do you speak? There has never been a promise for Java
    >>> to have a "waka waka" shortcut, whatever the heck that is,
    >>> and Java doesn't have an instance creation operator.

    >>
    >> Isn't "new" an instance creation operator?
    >>
    >> I've got a vague idea what he might have meant with "waka waka",
    >> but I'll leave it to him to clarify.

    >
    > It seems as a good guess that he is asking about <>.


    If what "seems as a good guess" is anywhere close to accurate it's an easy question to find out the answer to with a simple and rapid search.

    http://lmgtfy.com/?q=Java 7 new features

    --
    Lew
     
    Lew, Aug 13, 2011
    #7
  8. 00101010

    Roedy Green Guest

    On Fri, 12 Aug 2011 22:03:19 -0400, 00101010
    <> wrote, quoted or
    indirectly quoted someone who said :

    >Did they, like promised, add the waka waka shortcut for the instance
    >creation operator?


    I googled unsuccessfully. Waka Waka has meanings in the context of
    African pop music and Pac Man games, but nothing I could find on Java.

    Perhaps you mean something like my suggested Bali syntactic sugar:

    http://mindprod.com/jgloss/bali.html

    BigDate d = new BigDate( 1997, 5 , 6 );

    could be abbreviated:

    BigDate (1997, 5, 6) d;

    This does not require any new keyword. Language designers have jumped
    through hoops to avoid new keywords, e.g. in generics.
    --
    Roedy Green Canadian Mind Products
    http://mindprod.com
    Most of computer code is for telling the computer
    what do if some very particular thing goes wrong.
     
    Roedy Green, Aug 13, 2011
    #8
  9. 00101010

    Lew Guest

    Lew wrote:
    > Andreas Leitgeb wrote:
    >> Lew wrote:
    >>> "00101010" wrote:
    >>>> Did they, like promised, add the waka waka shortcut for the instance
    >>>> creation operator?
    >>> Of which "they" do you speak? There has never been a promise for Java
    >>> to have a "waka waka" shortcut, whatever the heck that is,
    >>> and Java doesn't have an instance creation operator.

    >>
    >> Isn't "new" an instance creation operator?

    >
    > No, it is not, because it is not a Java operator.


    The complete list of Java operators is in the JLS:
    <http://java.sun.com/docs/books/jls/third_edition/html/lexical.html#3.12>
    <quote>
    The following 37 tokens are the operators, formed from ASCII characters:

    Operator: one of
    = > < ! ~ ? :
    == <= >= != && || ++ --
    + - * / & | ^ % << >> >>>
    += -= *= /= &= |= ^= %= <<= >>= >>>=
    </quote>

    --
    Lew
     
    Lew, Aug 14, 2011
    #9
  10. 00101010

    Lew Guest

    Roedy Green wrote:
    > "00101010" wrote, quoted or indirectly quoted someone who said :
    >> Did they, like promised, add the waka waka shortcut for the instance
    >> creation operator?

    >
    > I googled unsuccessfully. Waka Waka has meanings in the context of
    > African pop music and Pac Man games, but nothing I could find on Java.


    I had similar results when I searched.

    > Perhaps you mean something like my suggested Bali syntactic sugar:
    >
    > http://mindprod.com/jgloss/bali.html
    >
    > BigDate d = new BigDate( 1997, 5 , 6 );
    >
    > could be abbreviated:
    >
    > BigDate (1997, 5, 6) d;
    >
    > This does not require any new keyword. Language designers have jumped
    > through hoops to avoid new keywords, e.g. in generics.


    Interesting and different guess from what Arne inferred. This does point up the need for clarification from the OP.

    OTOH, this was never a promised "waka waka" for Java. Others have discussed elsewhere on the 'net (I think even in this newsgroup) the purpose of the'new' keyword for constructors to distinguish them from methods that (against convention and good sense) match the class name.

    Personally I don't find the extra four characters it takes to type "new " worth the trouble of changing the language to eliminate the requirement for it. One can always follow Patricia Shanahan's and Joshua Bloch's advice touse a factory method instead of a public constructor. This eliminates theneed for a 'new' keyword in the expression, permits generic inference, allows power beyond mere construction, and admits of more expressive names than a mere copy of the class name, all without changing Java a whit. No "waka waka" required.

    --
    Lew
     
    Lew, Aug 14, 2011
    #10
  11. On Aug 13, 12:05 am, Lew <> wrote:
    > "00101010" wrote:
    > > Did they, like promised, add the waka waka shortcut for the instance
    > > creation operator?

    >
    > Of which "they" do you speak?  There has never been a promise for Java to have a "waka waka" shortcut, whatever the heck that is, and Java doesn'thave an instance creation operator.
    >
    > Could you please clarify your question?
    >
    > --
    > Lew


    Haven't you ever heard of waka waka bang splat tick tick hash?

    <> !*''#
    ^"`$$-
    !*=@$_
    %*<> ~#4
    &[]../
    |{,,SYSTEM HALTED

    Or if you prefer

    Waka waka bang splat tick tick hash,
    Caret quote back-tick dollar dollar dash,
    Bang splat equal at dollar under-score,
    Percent splat waka waka tilde number four,
    Ampersand bracket bracket dot dot slash,
    Vertical-bar curly-bracket comma comma CRASH.

    So he means what I think the unimaginative Java drones at Oracle refer
    to as the "diamond operator". I think.
     
    Dangling Pointer, Aug 16, 2011
    #11
  12. 00101010

    Jeff Higgins Guest

    On 08/16/2011 12:17 PM, Dangling Pointer wrote:
    >
    > <> !*''#
    > ^"`$$-
    > !*=@$_
    > %*<> ~#4
    > &[]../
    > |{,,SYSTEM HALTED
    >

    Have you a link to the long version?
     
    Jeff Higgins, Aug 16, 2011
    #12
  13. 00101010

    Lew Guest

    "Dangling Pointer" wrote:
    > Lew wrote:
    >> "00101010" wrote:
    >>> Did they, like promised, add the waka waka shortcut for the instance
    >>> creation operator?

    >>
    >> Of which "they" do you speak?  There has never been a promise for Javato
    >> have a "waka waka" shortcut, whatever the heck that is, and Java doesn't
    >> have an instance creation operator.
    >>
    >> Could you please clarify your question?

    >
    > Haven't you ever heard of waka waka bang splat tick tick hash?


    No.

    It doesn't make sense to refer to both left angle bracket and right angle bracket by the same name.

    The fact remains that it would've taken the OP less than five minutes to find the answer by reading the docs.

    > <> !*''#
    > ^"`$$-
    > !*=@$_
    > %*<> ~#4
    > &[]../
    > |{,,SYSTEM HALTED
    >
    > Or if you prefer
    >
    > Waka waka bang splat tick tick hash,
    > Caret quote back-tick dollar dollar dash,
    > Bang splat equal at dollar under-score,
    > Percent splat waka waka tilde number four,
    > Ampersand bracket bracket dot dot slash,
    > Vertical-bar curly-bracket comma comma CRASH.
    >
    > So he means what I think the unimaginative Java drones at Oracle refer
    > to as the "diamond operator". I think.


    Nothing "unimaginative" about it. The term perfectly evokes the visual image of <> and helps prevent placing the angle brackets in the wrong order.

    Certainly a more useful term than "waka waka", which evokes no visual imageand doesn't help discern the correct placement, and apparently is not as widely known as some seem to think.

    I do object to calling it an "operator" without updating the JLS to includeit as one, although its components are listed. Since they haven't released a JLS with the language changes that I know of (someone please post a link if I'm wrong), perhaps that is pending, so I'll suspend criticism for now..

    --
    Lew
     
    Lew, Aug 16, 2011
    #13
  14. 00101010

    Tom Anderson Guest

    On Tue, 16 Aug 2011, Dangling Pointer wrote:

    > On Aug 13, 12:05 am, Lew <> wrote:
    >> "00101010" wrote:
    >>
    >>> Did they, like promised, add the waka waka shortcut for the instance
    >>> creation operator?

    >>
    >> Of which "they" do you speak?  There has never been a promise for Java
    >> to have a "waka waka" shortcut, whatever the heck that is, and Java
    >> doesn't have an instance creation operator.
    >>
    >> Could you please clarify your question?

    >
    > Haven't you ever heard of waka waka bang splat tick tick hash?
    >
    > <> !*''#
    > ^"`$$-
    > !*=@$_
    > %*<> ~#4
    > &[]../
    > |{,,SYSTEM HALTED


    Since when did this become a Perl newsgroup?

    tom

    --
    Freedom, Beauty, Truth, and Love!
     
    Tom Anderson, Aug 16, 2011
    #14
  15. 00101010

    Jim Janney Guest

    Dangling Pointer <> writes:

    > On Aug 13, 12:05 am, Lew <> wrote:
    >> "00101010" wrote:
    >> > Did they, like promised, add the waka waka shortcut for the instance
    >> > creation operator?

    >>
    >> Of which "they" do you speak?  There has never been a promise for Java to have a "waka waka" shortcut, whatever the heck that is, and Java doesn't have an instance creation operator.
    >>
    >> Could you please clarify your question?
    >>
    >> --
    >> Lew

    >
    > Haven't you ever heard of waka waka bang splat tick tick hash?
    >
    > <> !*''#
    > ^"`$$-
    > !*=@$_
    > %*<> ~#4
    > &[]../
    > |{,,SYSTEM HALTED
    >
    > Or if you prefer
    >
    > Waka waka bang splat tick tick hash,
    > Caret quote back-tick dollar dollar dash,
    > Bang splat equal at dollar under-score,
    > Percent splat waka waka tilde number four,
    > Ampersand bracket bracket dot dot slash,
    > Vertical-bar curly-bracket comma comma CRASH.
    >
    > So he means what I think the unimaginative Java drones at Oracle refer
    > to as the "diamond operator". I think.


    Up until today my education has been sadly deficient. Thanks!

    --
    Jim Janney
     
    Jim Janney, Aug 16, 2011
    #15
  16. On 16.08.2011 22:39, Tom Anderson wrote:
    > On Tue, 16 Aug 2011, Dangling Pointer wrote:
    >
    >> On Aug 13, 12:05 am, Lew <> wrote:
    >>> "00101010" wrote:
    >>>
    >>>> Did they, like promised, add the waka waka shortcut for the instance
    >>>> creation operator?
    >>>
    >>> Of which "they" do you speak? There has never been a promise for
    >>> Java to have a "waka waka" shortcut, whatever the heck that is, and
    >>> Java doesn't have an instance creation operator.
    >>>
    >>> Could you please clarify your question?

    >>
    >> Haven't you ever heard of waka waka bang splat tick tick hash?
    >>
    >> <> !*''#
    >> ^"`$$-
    >> !*=@$_
    >> %*<> ~#4
    >> &[]../
    >> |{,,SYSTEM HALTED

    >
    > Since when did this become a Perl newsgroup?


    Maybe JPerl is around the corner... Seriously, there seems to be a
    tendency in the industry to create more and more languages which can be
    executed on the JVM (see also JSR 292 which is part of Java 7).

    Cheers

    robert


    --
    remember.guy do |as, often| as.you_can - without end
    http://blog.rubybestpractices.com/
     
    Robert Klemme, Aug 16, 2011
    #16
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. KS
    Replies:
    5
    Views:
    9,363
    David Zimmerman
    Nov 9, 2003
  2. christopher diggins

    Java Feature Proposal

    christopher diggins, Feb 4, 2004, in forum: Java
    Replies:
    18
    Views:
    584
    Adam Jenkins
    Feb 10, 2004
  3. winwin

    Feature of Sun Java 2

    winwin, Apr 14, 2004, in forum: Java
    Replies:
    4
    Views:
    401
    Roedy Green
    Apr 19, 2004
  4. Replies:
    9
    Views:
    473
    Timo Stamm
    Jun 2, 2006
  5. Replies:
    2
    Views:
    1,580
Loading...

Share This Page