Coverage Report - org.seasar.uruma.renderer.Renderer
 
Classes in this File Line Coverage Branch Coverage Complexity
Renderer
N/A
N/A
1
 
 1  
 /*
 2  
  * Copyright 2004-2008 the Seasar Foundation and the Others.
 3  
  *
 4  
  * Licensed under the Apache License, Version 2.0 (the "License");
 5  
  * you may not use this file except in compliance with the License.
 6  
  * You may obtain a copy of the License at
 7  
  *
 8  
  *     http://www.apache.org/licenses/LICENSE-2.0
 9  
  *
 10  
  * Unless required by applicable law or agreed to in writing, software
 11  
  * distributed under the License is distributed on an "AS IS" BASIS,
 12  
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, 
 13  
  * either express or implied. See the License for the specific language
 14  
  * governing permissions and limitations under the License.
 15  
  */
 16  
 package org.seasar.uruma.renderer;
 17  
 
 18  
 import org.seasar.uruma.component.UIComponent;
 19  
 import org.seasar.uruma.context.PartContext;
 20  
 import org.seasar.uruma.context.WidgetHandle;
 21  
 import org.seasar.uruma.context.WindowContext;
 22  
 
 23  
 /**
 24  
  * ウィジットをレンダリングするためのインターフェースです。<br />
 25  
  * 
 26  
  * @author y-komori
 27  
  */
 28  
 public interface Renderer {
 29  
     /**
 30  
      * レンダリングを行います。</br>
 31  
      * <p>
 32  
      * 本メソッドは、{@link UIComponent#preRender(WidgetHandle, org.seasar.uruma.context.WindowContext)}
 33  
      * の内部から呼び出されます。<br />
 34  
      * </p>
 35  
      * 
 36  
      * @param uiComponent
 37  
      *            レンダリング対象の情報を持つ {@link UIComponent} オブジェクト
 38  
      * @param parent
 39  
      *            親となる {@link WidgetHandle} オブジェクト
 40  
      * @param context
 41  
      *            画面情報を収めた {@link WindowContext} オブジェクト
 42  
      * @return レンダリングしたウィジットのハンドル
 43  
      */
 44  
     public WidgetHandle preRender(UIComponent uiComponent, WidgetHandle parent,
 45  
             WindowContext context);
 46  
 
 47  
     /**
 48  
      * レンダリングを行います。</br>
 49  
      * 
 50  
      * @param uiComponent
 51  
      *            レンダリング対象の情報を持つ {@link UIComponent} オブジェクト
 52  
      * @param parent
 53  
      *            親となる {@link WidgetHandle} オブジェクト
 54  
      * @param context
 55  
      *            画面情報を収めた {@link PartContext} オブジェクト
 56  
      * @return レンダリングしたウィジットのハンドル
 57  
      */
 58  
     public WidgetHandle render(UIComponent uiComponent, WidgetHandle parent,
 59  
             PartContext context);
 60  
 
 61  
     /**
 62  
      * 子のレンダリングが終わった後に呼び出されるメソッドです。</br>
 63  
      * 
 64  
      * @param widget
 65  
      *            {@link Renderer#render(UIComponent, WidgetHandle, PartContext) render()}
 66  
      *            メソッドでレンダリングされた {@link WidgetHandle} オブジェクト
 67  
      * 
 68  
      * @param uiComponent
 69  
      *            レンダリング対象の情報を持つ {@link UIComponent} オブジェクト
 70  
      * @param parent
 71  
      *            親となる {@link WidgetHandle} オブジェクト
 72  
      * @param context
 73  
      *            画面情報を収めた {@link PartContext} オブジェクト
 74  
      */
 75  
     public void renderAfter(WidgetHandle widget, UIComponent uiComponent,
 76  
             WidgetHandle parent, PartContext context);
 77  
 
 78  
     /**
 79  
      * 一度レンダリングしたウィジットに対する再レンダリングを行います。<br />
 80  
      * 再レンダリングとは、 {@link UIComponent} が保持する情報をウィジットに対して再度反映させる処理のことです。<br />
 81  
      * 再レンダリングを行うには、変更したい属性に対応する {@link UIComponent} の属性を変更し、変更対象のウィジットと
 82  
      * {@link UIComponent} を保持する {@link WidgetHandle} を本メソッドの引数として渡してください。
 83  
      * 
 84  
      * @param widget
 85  
      *            再レンダリング対象のウィジットと {@link UIComponent} を保持する
 86  
      *            {@link WidgetHandle} オブジェクト
 87  
      */
 88  
     public void reRender(WidgetHandle widget);
 89  
 }