This plugin can set all the properties of a class for you.
You just need to select a variable and press Ctrl + Shift + 7.
Example:
public class Foo{
byte byte1;
Byte byte2;
short short1;
Short short2;
int int1;
Integer int2;
long long1;
Long long2;
float float1;
Float float2;
double double1;
Double double2;
BigInteger biginteger;
BigDecimal bigDecimal;
boolean boolean1;
Boolean boolean2;
char char1;
Character char2;
String string;
Date date;
List coisas;
Set coisas2;
String[] strings1;
Set<String> strings2;
List<String> strings3;
Map<String, String> map1;
}
public void test(){
Foo thing = new Foo();
//if you select the variable 'thing' and press Ctrl+Shift+7 these
lines will appear
thing.setByte1(Byte.valueOf(1 + ""));
thing.setByte2(Byte.valueOf(1 + ""));
thing.setShort1(Short.valueOf(1 + ""));
thing.setShort2(Short.valueOf(1 + ""));
thing.setInt1(Integer.valueOf(1 + ""));
thing.setInt2(Integer.valueOf(1 + ""));
thing.setLong1(Long.valueOf(1 + ""));
thing.setLong2(Long.valueOf(1 + ""));
thing.setFloat1(Float.valueOf(1 + ""));
thing.setFloat2(Float.valueOf(1 + ""));
thing.setDouble1(Double.valueOf(1 + ""));
thing.setDouble2(Double.valueOf(1 + ""));
thing.setBiginteger(new BigInteger(1 + ""));
thing.setBigDecimal(new BigDecimal(1 + ""));
thing.setBoolean1(true);
thing.setBoolean2(true);
thing.setChar1('1');
thing.setChar2('1');
thing.setString("1");
thing.setDate(new Date());
thing.setCoisas(List.of(1));
thing.setCoisas2(Set.of(1));
thing.setStrings1(new String[]{"1"});
thing.setStrings2(Set.of("1"));
thing.setStrings3(List.of("1"));
thing.setMap1(Map.of("1","1"));
}
Categories: General Purpose Tools, Tools
Tags: SetProperties, Set Properties
Additional Details
Eclipse Versions: 2023-12 (4.30), 2023-09 (4.29), 2023-06 (4.28), 2023-03 (4.27), 2022-12 (4.26), 2022-09 (4.25), 2022-06 (4.24), 2022-03 (4.23), 2021-12 (4.22), 2021-09 (4.21), 2021-06 (4.20), 2021-03 (4.19), 2020-12 (4.18), 2020-09 (4.17), 2020-06 (4.16), 2020-03 (4.15), 2019-12 (4.14), 2019-09 (4.13), 2019-06 (4.12), 2019-03 (4.11), 2018-12 (4.10), 2018-09 (4.9), Photon (4.8), Oxygen (4.7), Neon (4.6), Mars (4.5), Luna (4.4), Kepler (4.3), Juno (4.2, 3.8), Previous to Juno (<=4.1), 2024-03 (4.31), 2024-06 (4.32), 2024-09 (4.33)
Platform Support: Windows, Mac, Linux/GTK
Organization Name: Dante Carvalho Costa
Development Status: Production/Stable
Date Created: Wednesday, February 1, 2023 - 12:43
License: MIT
Date Updated: Friday, December 8, 2023 - 09:59
Submitted by: dante carvalho costa
Date | Ranking | Installs | Clickthroughs |
---|---|---|---|
October 2024 | 432/551 | 2 | 2 |
September 2024 | 437/642 | 11 | 6 |
August 2024 | 393/641 | 13 | 11 |
July 2024 | 393/663 | 15 | 9 |
June 2024 | 442/681 | 11 | 9 |
May 2024 | 373/682 | 21 | 8 |
April 2024 | 449/687 | 12 | 7 |
March 2024 | 421/694 | 17 | 4 |
February 2024 | 390/687 | 20 | 5 |
January 2024 | 513/691 | 6 | 10 |
December 2023 | 416/671 | 16 | 15 |
November 2023 | 538/686 | 6 | 11 |