Buggy code:
public abstract class Component implements Serializable , IEventRequestListener { public class ComponentModelChange extends Change { private IModel model ; public ComponentModelChange ( IModel model ) { } public void undo ( ) { } } protected class VisibilityChange extends Change { private final Component component ; private final boolean isVisible ; VisibilityChange ( final Component component ) { } public void undo ( ) { } } protected static final short FLAG_RESERVED1 = 256 ; protected static final short FLAG_RESERVED2 = 512 ; protected static final short FLAG_RESERVED3 = 1024 ; protected static final short FLAG_RESERVED4 = 2048 ; private static final short FLAG_AUTO = 1 ; private static final short FLAG_ESCAPE_MODEL_STRINGS = 2 ; private static final short FLAG_HAS_ROOT_MODEL = 4 ; private static final short FLAG_VERSIONED = 8 ; private static final short FLAG_VISIBLE = 16 ; private static final short FLAG_RENDER_BODY_ONLY = 32 ; private static Log log = LogFactory . getLog ( Component . class ) ; private AttributeModifier attributeModifiers = null ; private short flags = ( ( Component . FLAG_VISIBLE ) | ( Component . FLAG_ESCAPE_MODEL_STRINGS ) ) | ( Component . FLAG_VERSIONED ) ; private String id ; private IModel model ; private MarkupContainer parent ; private Map eventRequestHandlers ; public static interface IVisitor { public static final Object CONTINUE_TRAVERSAL = null ; public static final Object STOP_TRAVERSAL = new Object ( ) ; public Object component ( Component component ) { } } public Component ( final String id ) { } public Component ( final String id , final IModel model ) { } public final Component add ( final AttributeModifier modifier ) { } public final void debug ( final String message ) { } public final void error ( final String message ) { } public final void fatal ( final String message ) { } public final MarkupContainer findParent ( final Class c ) { } public final MarkupContainer findParentWithAssociatedMarkup ( ) { } public final Application getApplication ( ) { <START_BUG> return getSession ( ) . getApplication ( ) ; <END_BUG> } public final ApplicationPages getApplicationPages ( ) { } public final ApplicationSettings getApplicationSettings ( ) { } public final String getClassRelativePath ( ) { } public IConverter getConverter ( ) { } public final boolean getEscapeModelStrings ( ) { } public final FeedbackMessage getFeedbackMessage ( ) { } public final String getId ( ) { } public final Locale getLocale ( ) { } public final Localizer getLocalizer ( ) { } public IModel getModel ( ) { } public final Object getModelObject ( ) { } public final String getModelObjectAsString ( ) { } public final Page getPage ( ) { } public final IPageFactory getPageFactory ( ) { } public final String getPageRelativePath ( ) { } public final MarkupContainer getParent ( ) { } public final String getPath ( ) { } public final Request getRequest ( ) { } public final RequestCycle getRequestCycle ( ) { } public final Resource getResource ( ) { } public final Response getResponse ( ) { } public final Session getSession ( ) { } public final String getString ( final String key ) { } public final String getString ( final String key , final IModel model ) { } public final String getString ( final String key , final IModel model , final String defaultValue ) { } public final String getStyle ( ) { } public String getVariation ( ) { } public final boolean hasErrorMessage ( ) { } public final boolean hasFeedbackMessage ( ) { } public final void info ( final String message ) { } public final boolean isAncestorOf ( final Component component ) { } public boolean isVersioned ( ) { } public final boolean isVisibleInHierarchy ( ) { } public boolean isVisible ( ) { } public final void modelChanged ( ) { } public final void modelChanging ( ) { } public final Page newPage ( final Class c ) { } public final Page newPage ( final Class c , final PageParameters parameters ) { } public final void remove ( ) { } public final void render ( ) { } public final void rendered ( ) { } public final boolean sameRootModel ( final Component component ) { } public final boolean sameRootModel ( final IModel model ) { } public void setModel ( final IModel model ) { } public final void setModelObject ( final Object object ) { } protected final boolean getRenderBodyOnly ( ) { } public final void setResponsePage ( final Page page ) { } public final void setResponsePage ( final Class cls ) { } public final void setResponsePage ( final Class cls , PageParameters parameters ) { } public final void setRedirect ( final boolean redirect ) { } public final void setRenderBodyOnly ( final boolean renderTag ) { } public final Component setEscapeModelStrings ( final boolean escapeMarkup ) { } public void setVersioned ( boolean versioned ) { } public final Component setVisible ( final boolean visible ) { } public String toString ( ) { } public String toString ( final boolean detailed ) { } public final String urlFor ( final Class listenerInterface ) { } public final void warn ( final String message ) { } public final void add ( IEventRequestHandler eventRequestHandler ) { } public void onEventRequest ( ) { } protected final void addStateChange ( Change change ) { } protected final void checkComponentTag ( final ComponentTag tag , final String name ) { } protected final void checkComponentTagAttribute ( final ComponentTag tag , final String key , final String value ) { } protected void detachModel ( ) { } protected final String exceptionMessage ( final String message ) { } protected MarkupStream findMarkupStream ( ) { } protected final Page findPage ( ) { } protected final IEventRequestHandler [ ] getEventRequestHandlers ( ) { } protected final boolean getFlag ( final short flag ) { }

Fix:
return Application . get ( ) ;