//# 0 errors, 45 messages
//#
/*
    //#staticpageview.java:1:1: class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#staticpageview.java:1:1: method: net.sourceforge.pebble.web.view.impl.StaticPageView.net.sourceforge.pebble.web.view.impl.StaticPageView__static_init
 * Copyright (c) 2003-2006, Simon Brown
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 *   - Redistributions of source code must retain the above copyright
 *     notice, this list of conditions and the following disclaimer.
 *
 *   - Redistributions in binary form must reproduce the above copyright
 *     notice, this list of conditions and the following disclaimer in
 *     the documentation and/or other materials provided with the
 *     distribution.
 *
 *   - Neither the name of Pebble nor the names of its contributors may
 *     be used to endorse or promote products derived from this software
 *     without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGE.
 */
package net.sourceforge.pebble.web.view.impl;

import net.sourceforge.pebble.Constants;
import net.sourceforge.pebble.api.decorator.ContentDecoratorContext;
import net.sourceforge.pebble.domain.StaticPage;
import net.sourceforge.pebble.web.view.HtmlView;


/**
 * Represents a page containing a single static page.
 *
 * @author    Simon Brown
 */
public class StaticPageView extends HtmlView {
    //#staticpageview.java:45: method: void net.sourceforge.pebble.web.view.impl.StaticPageView.net.sourceforge.pebble.web.view.impl.StaticPageView()
    //#staticpageview.java:45: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.web.view.HtmlView()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: void net.sourceforge.pebble.web.view.impl.StaticPageView()
    //#    unanalyzed callee: void net.sourceforge.pebble.web.view.HtmlView()
    //#input(void net.sourceforge.pebble.web.view.impl.StaticPageView()): this
    //#staticpageview.java:45: end of method: void net.sourceforge.pebble.web.view.impl.StaticPageView.net.sourceforge.pebble.web.view.impl.StaticPageView()

  public void prepare() {
    ContentDecoratorContext context = new ContentDecoratorContext();
    //#staticpageview.java:48: method: void net.sourceforge.pebble.web.view.impl.StaticPageView.prepare()
    //#staticpageview.java:48: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.api.decorator.ContentDecoratorContext()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: void prepare()
    //#    unanalyzed callee: void net.sourceforge.pebble.api.decorator.ContentDecoratorContext()
    //#input(void prepare()): this
    //#presumption(void prepare()): net.sourceforge.pebble.domain.Blog:getContentDecoratorChain(...)@53 != null
    //#presumption(void prepare()): net.sourceforge.pebble.domain.StaticPage:getBlog(...)@53 != null
    //#presumption(void prepare()): net.sourceforge.pebble.web.model.Model:get(...)@52 != null
    //#presumption(void prepare()): net.sourceforge.pebble.web.view.impl.StaticPageView:getModel(...)@52 != null
    context.setView(ContentDecoratorContext.DETAIL_VIEW);
    //#staticpageview.java:49: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.api.decorator.ContentDecoratorContext:setView(int)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: void prepare()
    //#    unanalyzed callee: void net.sourceforge.pebble.api.decorator.ContentDecoratorContext:setView(int)
    context.setMedia(ContentDecoratorContext.HTML_PAGE);
    //#staticpageview.java:50: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.api.decorator.ContentDecoratorContext:setMedia(int)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: void prepare()
    //#    unanalyzed callee: void net.sourceforge.pebble.api.decorator.ContentDecoratorContext:setMedia(int)

    StaticPage staticPage = (StaticPage)getModel().get(Constants.STATIC_PAGE_KEY);
    //#staticpageview.java:52: Warning: method not available
    //#    -- call on Model net.sourceforge.pebble.web.view.impl.StaticPageView:getModel()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: void prepare()
    //#    unanalyzed callee: Model net.sourceforge.pebble.web.view.impl.StaticPageView:getModel()
    //#staticpageview.java:52: Warning: method not available
    //#    -- call on Object net.sourceforge.pebble.web.model.Model:get(String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: void prepare()
    //#    unanalyzed callee: Object net.sourceforge.pebble.web.model.Model:get(String)
    staticPage.getBlog().getContentDecoratorChain().decorate(context, staticPage);
    //#staticpageview.java:53: Warning: method not available
    //#    -- call on Blog net.sourceforge.pebble.domain.StaticPage:getBlog()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: void prepare()
    //#    unanalyzed callee: Blog net.sourceforge.pebble.domain.StaticPage:getBlog()
    //#staticpageview.java:53: Warning: method not available
    //#    -- call on ContentDecoratorChain net.sourceforge.pebble.domain.Blog:getContentDecoratorChain()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: void prepare()
    //#    unanalyzed callee: ContentDecoratorChain net.sourceforge.pebble.domain.Blog:getContentDecoratorChain()
    //#staticpageview.java:53: Warning: method not available
    //#    -- call on void net.sourceforge.pebble.decorator.ContentDecoratorChain:decorate(ContentDecoratorContext, StaticPage)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: void prepare()
    //#    unanalyzed callee: void net.sourceforge.pebble.decorator.ContentDecoratorChain:decorate(ContentDecoratorContext, StaticPage)
  }
    //#staticpageview.java:54: end of method: void net.sourceforge.pebble.web.view.impl.StaticPageView.prepare()

  /**
   * Gets the title of this view.
   *
   * @return the title as a String
   */
  public String getTitle() {
    StaticPage staticPage = (StaticPage)getModel().get(Constants.STATIC_PAGE_KEY);
    //#staticpageview.java:62: method: String net.sourceforge.pebble.web.view.impl.StaticPageView.getTitle()
    //#staticpageview.java:62: Warning: method not available
    //#    -- call on Model net.sourceforge.pebble.web.view.impl.StaticPageView:getModel()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: String getTitle()
    //#    unanalyzed callee: Model net.sourceforge.pebble.web.view.impl.StaticPageView:getModel()
    //#staticpageview.java:62: Warning: method not available
    //#    -- call on Object net.sourceforge.pebble.web.model.Model:get(String)
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: String getTitle()
    //#    unanalyzed callee: Object net.sourceforge.pebble.web.model.Model:get(String)
    //#input(String getTitle()): this
    //#output(String getTitle()): return_value
    //#presumption(String getTitle()): net.sourceforge.pebble.web.model.Model:get(...)@62 != null
    //#presumption(String getTitle()): net.sourceforge.pebble.web.view.impl.StaticPageView:getModel(...)@62 != null
    //#post(String getTitle()): init'ed(return_value)
    return staticPage.getTitle();
    //#staticpageview.java:63: Warning: method not available
    //#    -- call on String net.sourceforge.pebble.domain.StaticPage:getTitle()
    //#    severity: INFORMATIONAL
    //#    class: net.sourceforge.pebble.web.view.impl.StaticPageView
    //#    method: String getTitle()
    //#    unanalyzed callee: String net.sourceforge.pebble.domain.StaticPage:getTitle()
    //#staticpageview.java:63: end of method: String net.sourceforge.pebble.web.view.impl.StaticPageView.getTitle()
  }

  /**
   * Gets the URI that this view represents.
   *
   * @return the URI as a String
   */
  public String getUri() {
    return "/WEB-INF/jsp/staticPage.jsp";
    //#staticpageview.java:72: method: String net.sourceforge.pebble.web.view.impl.StaticPageView.getUri()
    //#output(String getUri()): return_value
    //#post(String getUri()): return_value == &".WEB-INF.jsp.staticPage.jsp"
    //#staticpageview.java:72: end of method: String net.sourceforge.pebble.web.view.impl.StaticPageView.getUri()
  }

}    //#output(net.sourceforge.pebble.web.view.impl.StaticPageView__static_init): __Descendant_Table[net/sourceforge/pebble/web/view/impl/StaticPageView]
    //#output(net.sourceforge.pebble.web.view.impl.StaticPageView__static_init): __Dispatch_Table.getTitle()Ljava/lang/String;
    //#output(net.sourceforge.pebble.web.view.impl.StaticPageView__static_init): __Dispatch_Table.getUri()Ljava/lang/String;
    //#output(net.sourceforge.pebble.web.view.impl.StaticPageView__static_init): __Dispatch_Table.prepare()V
    //#post(net.sourceforge.pebble.web.view.impl.StaticPageView__static_init): __Descendant_Table[net/sourceforge/pebble/web/view/impl/StaticPageView] == &__Dispatch_Table
    //#post(net.sourceforge.pebble.web.view.impl.StaticPageView__static_init): __Dispatch_Table.getTitle()Ljava/lang/String; == &getTitle
    //#post(net.sourceforge.pebble.web.view.impl.StaticPageView__static_init): __Dispatch_Table.getUri()Ljava/lang/String; == &getUri
    //#post(net.sourceforge.pebble.web.view.impl.StaticPageView__static_init): __Dispatch_Table.prepare()V == &prepare
    //#staticpageview.java:: end of method: net.sourceforge.pebble.web.view.impl.StaticPageView.net.sourceforge.pebble.web.view.impl.StaticPageView__static_init
    //#staticpageview.java:: end of class: net.sourceforge.pebble.web.view.impl.StaticPageView
