Home | History | Annotate | Download | only in mappers
      1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
      2 <!-- NewPage -->
      3 <html lang="pl">
      4 <head>
      5 <!-- Generated by javadoc (1.8.0) on Mon Jul 28 12:08:59 CEST 2014 -->
      6 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
      7 <title>DataMapper (JUnitParams 1.0.3-SNAPSHOT API)</title>
      8 <meta name="date" content="2014-07-28">
      9 <link rel="stylesheet" type="text/css" href="../../stylesheet.css" title="Style">
     10 <script type="text/javascript" src="../../script.js"></script>
     11 </head>
     12 <body>
     13 <script type="text/javascript"><!--
     14     try {
     15         if (location.href.indexOf('is-external=true') == -1) {
     16             parent.document.title="DataMapper (JUnitParams 1.0.3-SNAPSHOT API)";
     17         }
     18     }
     19     catch(err) {
     20     }
     21 //-->
     22 var methods = {"i0":6};
     23 var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"]};
     24 var altColor = "altColor";
     25 var rowColor = "rowColor";
     26 var tableTab = "tableTab";
     27 var activeTableTab = "activeTableTab";
     28 </script>
     29 <noscript>
     30 <div>JavaScript is disabled on your browser.</div>
     31 </noscript>
     32 <!-- ========= START OF TOP NAVBAR ======= -->
     33 <div class="topNav"><a name="navbar.top">
     34 <!--   -->
     35 </a>
     36 <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
     37 <a name="navbar.top.firstrow">
     38 <!--   -->
     39 </a>
     40 <ul class="navList" title="Navigation">
     41 <li><a href="../../overview-summary.html">Overview</a></li>
     42 <li><a href="package-summary.html">Package</a></li>
     43 <li class="navBarCell1Rev">Class</li>
     44 <li><a href="class-use/DataMapper.html">Use</a></li>
     45 <li><a href="package-tree.html">Tree</a></li>
     46 <li><a href="../../deprecated-list.html">Deprecated</a></li>
     47 <li><a href="../../index-all.html">Index</a></li>
     48 <li><a href="../../help-doc.html">Help</a></li>
     49 </ul>
     50 </div>
     51 <div class="subNav">
     52 <ul class="navList">
     53 <li><a href="../../junitparams/mappers/CsvWithHeaderMapper.html" title="class in junitparams.mappers"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
     54 <li><a href="../../junitparams/mappers/IdentityMapper.html" title="class in junitparams.mappers"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
     55 </ul>
     56 <ul class="navList">
     57 <li><a href="../../index.html?junitparams/mappers/DataMapper.html" target="_top">Frames</a></li>
     58 <li><a href="DataMapper.html" target="_top">No&nbsp;Frames</a></li>
     59 </ul>
     60 <ul class="navList" id="allclasses_navbar_top">
     61 <li><a href="../../allclasses-noframe.html">All&nbsp;Classes</a></li>
     62 </ul>
     63 <div>
     64 <script type="text/javascript"><!--
     65   allClassesLink = document.getElementById("allclasses_navbar_top");
     66   if(window==top) {
     67     allClassesLink.style.display = "block";
     68   }
     69   else {
     70     allClassesLink.style.display = "none";
     71   }
     72   //-->
     73 </script>
     74 </div>
     75 <div>
     76 <ul class="subNavList">
     77 <li>Summary:&nbsp;</li>
     78 <li>Nested&nbsp;|&nbsp;</li>
     79 <li>Field&nbsp;|&nbsp;</li>
     80 <li>Constr&nbsp;|&nbsp;</li>
     81 <li><a href="#method.summary">Method</a></li>
     82 </ul>
     83 <ul class="subNavList">
     84 <li>Detail:&nbsp;</li>
     85 <li>Field&nbsp;|&nbsp;</li>
     86 <li>Constr&nbsp;|&nbsp;</li>
     87 <li><a href="#method.detail">Method</a></li>
     88 </ul>
     89 </div>
     90 <a name="skip.navbar.top">
     91 <!--   -->
     92 </a></div>
     93 <!-- ========= END OF TOP NAVBAR ========= -->
     94 <!-- ======== START OF CLASS DATA ======== -->
     95 <div class="header">
     96 <div class="subTitle">junitparams.mappers</div>
     97 <h2 title="Interface DataMapper" class="title">Interface DataMapper</h2>
     98 </div>
     99 <div class="contentContainer">
    100 <div class="description">
    101 <ul class="blockList">
    102 <li class="blockList">
    103 <dl>
    104 <dt>All Known Implementing Classes:</dt>
    105 <dd><a href="../../junitparams/mappers/CsvWithHeaderMapper.html" title="class in junitparams.mappers">CsvWithHeaderMapper</a>, <a href="../../junitparams/mappers/IdentityMapper.html" title="class in junitparams.mappers">IdentityMapper</a></dd>
    106 </dl>
    107 <hr>
    108 <br>
    109 <pre>public interface <span class="typeNameLabel">DataMapper</span></pre>
    110 <div class="block">Interface to be used by FileParameters'ized test methods. If you want to read
    111  your own format of data from file, implement the map method appropriately.
    112  For CSV files, just skip it.</div>
    113 <dl>
    114 <dt><span class="simpleTagLabel">Author:</span></dt>
    115 <dd>Pawel Lipinski</dd>
    116 </dl>
    117 </li>
    118 </ul>
    119 </div>
    120 <div class="summary">
    121 <ul class="blockList">
    122 <li class="blockList">
    123 <!-- ========== METHOD SUMMARY =========== -->
    124 <ul class="blockList">
    125 <li class="blockList"><a name="method.summary">
    126 <!--   -->
    127 </a>
    128 <h3>Method Summary</h3>
    129 <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
    130 <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Abstract Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
    131 <tr>
    132 <th class="colFirst" scope="col">Modifier and Type</th>
    133 <th class="colLast" scope="col">Method and Description</th>
    134 </tr>
    135 <tr id="i0" class="altColor">
    136 <td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>[]</code></td>
    137 <td class="colLast"><code><span class="memberNameLink"><a href="../../junitparams/mappers/DataMapper.html#map-java.io.Reader-">map</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a>&nbsp;reader)</code>
    138 <div class="block">Maps file contents to parameters.</div>
    139 </td>
    140 </tr>
    141 </table>
    142 </li>
    143 </ul>
    144 </li>
    145 </ul>
    146 </div>
    147 <div class="details">
    148 <ul class="blockList">
    149 <li class="blockList">
    150 <!-- ============ METHOD DETAIL ========== -->
    151 <ul class="blockList">
    152 <li class="blockList"><a name="method.detail">
    153 <!--   -->
    154 </a>
    155 <h3>Method Detail</h3>
    156 <a name="map-java.io.Reader-">
    157 <!--   -->
    158 </a>
    159 <ul class="blockListLast">
    160 <li class="blockList">
    161 <h4>map</h4>
    162 <pre><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>[]&nbsp;map(<a href="http://docs.oracle.com/javase/6/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</a>&nbsp;reader)</pre>
    163 <div class="block">Maps file contents to parameters. In your implementation read the data
    164  from the reader. The reader is closed in the framework, so just read it
    165  :)
    166  
    167  While reading transform the data into Object[][], where external
    168  dimension are different parameter sets, and internal dimension is the set
    169  of params per single test call
    170  
    171  You can optionally return Object[] with Strings inside, but each String
    172  must be a string in the same format as what you would normally pass to
    173  &#064;Parameters({})</div>
    174 <dl>
    175 <dt><span class="paramLabel">Parameters:</span></dt>
    176 <dd><code>reader</code> - </dd>
    177 <dt><span class="returnLabel">Returns:</span></dt>
    178 <dd>an array with all parameter sets</dd>
    179 </dl>
    180 </li>
    181 </ul>
    182 </li>
    183 </ul>
    184 </li>
    185 </ul>
    186 </div>
    187 </div>
    188 <!-- ========= END OF CLASS DATA ========= -->
    189 <!-- ======= START OF BOTTOM NAVBAR ====== -->
    190 <div class="bottomNav"><a name="navbar.bottom">
    191 <!--   -->
    192 </a>
    193 <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
    194 <a name="navbar.bottom.firstrow">
    195 <!--   -->
    196 </a>
    197 <ul class="navList" title="Navigation">
    198 <li><a href="../../overview-summary.html">Overview</a></li>
    199 <li><a href="package-summary.html">Package</a></li>
    200 <li class="navBarCell1Rev">Class</li>
    201 <li><a href="class-use/DataMapper.html">Use</a></li>
    202 <li><a href="package-tree.html">Tree</a></li>
    203 <li><a href="../../deprecated-list.html">Deprecated</a></li>
    204 <li><a href="../../index-all.html">Index</a></li>
    205 <li><a href="../../help-doc.html">Help</a></li>
    206 </ul>
    207 </div>
    208 <div class="subNav">
    209 <ul class="navList">
    210 <li><a href="../../junitparams/mappers/CsvWithHeaderMapper.html" title="class in junitparams.mappers"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
    211 <li><a href="../../junitparams/mappers/IdentityMapper.html" title="class in junitparams.mappers"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
    212 </ul>
    213 <ul class="navList">
    214 <li><a href="../../index.html?junitparams/mappers/DataMapper.html" target="_top">Frames</a></li>
    215 <li><a href="DataMapper.html" target="_top">No&nbsp;Frames</a></li>
    216 </ul>
    217 <ul class="navList" id="allclasses_navbar_bottom">
    218 <li><a href="../../allclasses-noframe.html">All&nbsp;Classes</a></li>
    219 </ul>
    220 <div>
    221 <script type="text/javascript"><!--
    222   allClassesLink = document.getElementById("allclasses_navbar_bottom");
    223   if(window==top) {
    224     allClassesLink.style.display = "block";
    225   }
    226   else {
    227     allClassesLink.style.display = "none";
    228   }
    229   //-->
    230 </script>
    231 </div>
    232 <div>
    233 <ul class="subNavList">
    234 <li>Summary:&nbsp;</li>
    235 <li>Nested&nbsp;|&nbsp;</li>
    236 <li>Field&nbsp;|&nbsp;</li>
    237 <li>Constr&nbsp;|&nbsp;</li>
    238 <li><a href="#method.summary">Method</a></li>
    239 </ul>
    240 <ul class="subNavList">
    241 <li>Detail:&nbsp;</li>
    242 <li>Field&nbsp;|&nbsp;</li>
    243 <li>Constr&nbsp;|&nbsp;</li>
    244 <li><a href="#method.detail">Method</a></li>
    245 </ul>
    246 </div>
    247 <a name="skip.navbar.bottom">
    248 <!--   -->
    249 </a></div>
    250 <!-- ======== END OF BOTTOM NAVBAR ======= -->
    251 <p class="legalCopy"><small>Copyright &#169; 2014 <a href="http://pragmatists.pl">Pragmatists</a>. All rights reserved.</small></p>
    252 </body>
    253 </html>
    254