Compiler Error J0051

Undefined package 'identifier'

The compiler detected a package name declaration, but was unable to locate the package definition. This error usually occurs when a syntactical error exists in an import statement. This error may also occur when the package cannot be found or does not exist.

The following example illustrates this error:

import java.lang.bogus.*;
// error: ‘bogus’ not a valid package name

public class Simple {
   
   // do something meaningful
   
}