Link to home
Start Free TrialLog in
Avatar of PearlJamFanatic
PearlJamFanatic

asked on

passing enum to a method

enum MyEnum1{BUYOPEN, XYZ, ABC};
enum MyEnum2{SCALEOUTTARGET, BCD, EFG};

localDataSeries=getDataSeries();
for (int I=0;i<100;i++){
localDataSeries.setBoolean(i, MyEnum1.BUYOPEN, true);	
localDataSeries.setDouble(i, MyEnum2.SCALEOUTTARGET, 2210.05);
localDataSeries.setInt(i, MyEnum2.BCD, 10);
}
//many more values within localDataseries set using the enums key
.
.
.
}

Open in new window


Is there a way to reset localDataSeries values (that were set using the enum keys) to null in a mass update way? for example like this
 
		 public void resetDataseriesvalues(DataSeries ds, Enum key){
				 for (int i=0;i<key.values().length;i++)
					 for (int j=0;j<ds.size();j++)
					 ds.setValue(j, key.values()[i],null);
			 }

Open in new window

resetDataseriesvalues() is not working.
Avatar of PearlJamFanatic
PearlJamFanatic

ASKER

is CEHJ taking a day off? :)
ASKER CERTIFIED SOLUTION
Avatar of mccarl
mccarl
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
thx, I havent't tested this yet.
You're welcome, let us know if you still have questions!