<?xml version = '1.0' encoding = 'UTF-8'?>
<page xmlns="http://bali.us.oracle.com/cabo/baja" 
      xmlns:baja="http://bali.us.oracle.com/cabo/baja"       
      xmlns:data="http://bali.us.oracle.com/cabo/marlin"       
      xmlns:marlin="http://bali.us.oracle.com/cabo/marlin" 
      xmlns:html="http://www.w3.org/TR/REC-html40">
  
  <baja:content xmlns="http://bali.us.oracle.com/cabo/marlin" >
    <dataScope>

      <contents>

        <html:title>
          <text data:text="title@thresholdData" />
        </html:title>

        <form name="thresholdData" method="POST">
          <contents>
            <pageLayout xmlns="http://bali.us.oracle.com/cabo/marlin" >
              <mediumAdvertisement>
                <include baja:node="../oemBanner" />
              </mediumAdvertisement>
              <globalButtons>
                <include baja:node="../globalButtonBar" />
              </globalButtons>
              <data:tabs>
                <include baja:node="../globalTabs" />
              </data:tabs>
              <data:pageHeader>
                <include baja:node="../globalHeader" />
              </data:pageHeader>
              <data:location>
                <include baja:node="../breadCrumbs" /> 
              </data:location>
              <copyright>
                <include baja:node="../copyright"/>
              </copyright>
              
              <contentFooter>
               <pageButtonBar>                    
                <contents>
                 <button data:text="OK_BUTTON@mntrResourceBundle"
                         data:destination="okButtonDestination@thresholdData"/>
                </contents>
               </pageButtonBar>
              </contentFooter>

               <data:contents>
                <stackLayout>
                 <contents>
                  <header data:text="header@thresholdData">
                   <contents>

                    <borderLayout>  
                     <innerTop>                  
                      <styledText data:text="headerMessage@thresholdData"
                                  styleClass="OraInstructionText"/>
                     </innerTop>                  
                     <right>
                      <rowLayout>
                       <contents>
                        <button data:text="OK_BUTTON@mntrResourceBundle"
                                data:destination="okButtonDestination@thresholdData"/>
                       </contents>
                      </rowLayout>
                     </right>
                    </borderLayout>
                     
                    <spacer height="15"/>
                    
                     <borderLayout>
                      <contents>
                       <switcher data:childName="node@thresholdData">
                        <case name="okNode">
                         <stackLayout>
                          <contents>
                           <table name="thresholdDataTable"
                                  data:alternateText="NO_DATA_STR@mntrResourceBundle"
                                  width="100%"
                                  data:tableData="row@thresholdData"
                                  data:columnHeaderData="columnHeaders@columnHeaderData"
                                  data:value="value@thresholdData">
                                  
                            <tableFormat tableBanding="rowBanding"/>
                             <columnHeaderStamp>
                              <sortableHeader data:text="value" data:sortable="sortable" />
                             </columnHeaderStamp>
      
                             <columnFormats>
                              <columnFormat width="35%" columnDataFormat="textFormat"/>
                              <columnFormat width="5%" columnDataFormat="iconButtonFormat"/>
                              <columnFormat width="15%" columnDataFormat="textFormat"/>
                              <columnFormat width="15%" columnDataFormat="textFormat"/>
                              <columnFormat width="30%" columnDataFormat="textFormat"/>
                             </columnFormats>
                             
                                        <contents>
                                          <dataScope>
                                            <contents>                                      
                                              <switcher data:childName="ic">
                                                <case name="false">
                                                  <styledText data:text="ml"
                                                              styleClass="OraInstructionText"/>
                                                </case>
                                                <case name="true">
                                                  <flowLayout>
                                                    <contents>
                                                      <spacer width="20"/>                                                
                                                      <styledText data:text="ml"
                                                                  styleClass="OraInstructionText"/>
                                                    </contents>
                                                  </flowLayout>
                                                </case>
                                              </switcher>
                                            </contents>
                                          </dataScope>
                                          <stackLayout>
                                            <contents>                                               
                                              <styledText rendered="true"
                                                          data:rendered="sv"
                                                          data:text="co"
                                                          styleClass="OraInstructionTextStrong"/>
                                            </contents>
                                          </stackLayout>                                               
                                          <stackLayout>
                                            <contents> 
                                              <styledText rendered="true"
                                                         data:rendered="sv"
                                                         name="wt" 
                                                         columns="10"
                                                         data:text="wt"
                                                         readOnly="true"/>
                                            </contents>
                                          </stackLayout>                                               
                                          <stackLayout>
                                            <contents>
                                              <textInput rendered="true"
                                                         data:rendered="sv"
                                                         name="ct" 
                                                         columns="10"
                                                         data:text="ct"
                                                         readOnly="true"/>
                                            </contents>
                                          </stackLayout>                                               
                                          <stackLayout>
                                            <contents>                                               
                                              <textInput rendered="true"
                                                         data:rendered="sv"
                                                         name="fj" 
                                                         columns="50"
                                                         data:text="fj"
                                                         readOnly="true"/>
                                            </contents>
                                          </stackLayout>

                                        </contents>
                                      </table>
                                     </contents>
                                   </stackLayout>
                                    </case>
                          <case name="errNode">
                            <messageBox data:message="errMsg@thresholdData"
                                        messageType="error"
                                        longDescURL="unimpl"
                                        data:text="ERROR_OCCURRED_MSG@mntrResourceBundle">
                            </messageBox>
                          </case>
                        </switcher>
                      </contents>
                    </borderLayout>
                    
                   </contents>
                  </header> 
                  </contents>
                </stackLayout>   
             </data:contents>
             
            </pageLayout>
          </contents>
        </form>        
      </contents>

      <provider>
      
        <data name="columnHeaderData">
          <inline>
            <columnHeaders data:value="METRIC_COLHDR_LABEL@mntrResourceBundle" 
                           sortable="no"/> 
            <columnHeaders data:value="COMPARISION_OP_COLHDR_LABEL@mntrResourceBundle" 
                           sortable="no"/>
            <columnHeaders data:value="WARNING_THRESHOLD_COLHDR_LABEL@mntrResourceBundle" 
                           sortable="no"/>
            <columnHeaders data:value="CRITICAL_THRESHOLD_COLHDR_LABEL@mntrResourceBundle" 
                           sortable="no"/>
            <columnHeaders data:value="FIXIT_JOB_COLHDR_LABEL@mntrResourceBundle" 
                           sortable="no"/>
          </inline>
        </data>

        <data name="commonResourceBundle">
            <bundle class="oracle.sysman.resources.CommonResourceBundle"/>
        </data>

        <data name="mntrResourceBundle">
            <bundle class="oracle.sysman.resources.MntrResourceBundle"/>
        </data>

        <data name="thresholdData">
            <method class="oracle.sysman.eml.mntr.metrics.MetricThresholdsDataObject" 
                    method="getThresholdData"/>
        </data>
       
      </provider>
      
    </dataScope>
  </baja:content>

  <handlers>
    <!-- use this handler to enter this page -->
    <event name="*">
      <method class="oracle.sysman.eml.mntr.metrics.MetricThresholdsDataObject"
              method="doLoad"/>
    </event>
    <event name="doLoad">
      <method class="oracle.sysman.eml.mntr.metrics.MetricThresholdsDataObject"
              method="doLoad"/>
    </event>
  </handlers>

</page>
