Hello, if you make use of the code below then you will able to get the information about the custom event in java:
Code:
public class CustomClass
{
private int first;
public delegate void ChangingHandler (object obj, CustomClassArgs customClassArg);
public event ChangingHandler handler;
public CustomClass(int n)
{
this.first=n;
}
public void setOne(int p)
{
this.first=p;
if (p<5)
{
CustomClassArgs customClassArg=new CustomClassArgs("Class is below, first value is : "+this.first);
handler(this,customClassArg);
}
}
public string strCheck() {
return this.first.ToString();
}
}
Bookmarks