我的部分代码如下;illegal start of type
由于不断出现错误(在if
语句的行上),我无法编译。我能做些什么来改变它?
public class Job
{
boolean jobsCompleted = false;
Job firstJob = getCurrentJob();
String jobName = firstJob.getName();
int jobDuration = firstJob.getDuration();
if (!myJob.isEmpty()&& jobDuration > 0 && jobDuration <= myTotalDuration)
//this is where i am getting the error, highlighting red before the 'if' statement.