redundant specification of type arguments

This is not a Support area! Discuss about the Server here. Non-Server related discussion goes in Off-Topic Discussion.
Forum rules
READ NOW: L2j Forums Rules of Conduct
Post Reply
daemon
Posts: 160
Joined: Wed Oct 17, 2007 7:56 pm

redundant specification of type arguments

Post by daemon »

Code: Select all

    public ArrayList<L2ProductItemComponent> getComponents()    {        if (_components == null)        {            _components = new ArrayList<L2ProductItemComponent>(); //redundant specification of type arguments <L2ProductItemComponent>        }                return _components;    }
Eclipse gets notification: redundant specification of type arguments <L2ProductItemComponent>

What way should i modify the code not to get this notification anymore?
User avatar
UnAfraid
L2j Veteran
L2j Veteran
Posts: 4199
Joined: Mon Jul 23, 2007 4:25 pm
Location: Bulgaria
Contact:

Re: redundant specification of type arguments

Post by UnAfraid »

daemon wrote:

Code: Select all

    public ArrayList<L2ProductItemComponent> getComponents()    {        if (_components == null)        {            _components = new ArrayList<L2ProductItemComponent>(); //redundant specification of type arguments <L2ProductItemComponent>        }                return _components;    }
Eclipse gets notification: redundant specification of type arguments <L2ProductItemComponent>

What way should i modify the code not to get this notification anymore?

Code: Select all

_components = new ArrayList<>();
Image
daemon
Posts: 160
Joined: Wed Oct 17, 2007 7:56 pm

Re: redundant specification of type arguments

Post by daemon »

Thanks
Post Reply