String (final GrFileStub stub) { for (StubElement child : stub.getChildrenStubs()) { if (child instanceof GrPackageDefinitionStub) { return ((GrPackageDefinitionStub)child).getPackageName(); } } return null; }