<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title>Jaggery - Delicious Javascript</title>
    <meta name="description" content="">
    <meta name="author" content="">

    <!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
    <!--[if lt IE 9]>
    <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->

    <!-- Le styles -->
    <link href="../css/bootstrap.css" rel="stylesheet">
    <style type="text/css">
        body {
            padding-top: 60px;
        }
    </style>
    <link href="../css/prettify.css" rel="stylesheet">
    <!-- Le fav and touch icons -->
    <link rel="shortcut icon" href="../images/favicon.ico">
    <link rel="apple-touch-icon" href="../images/apple-touch-icon.png">
    <link rel="apple-touch-icon" sizes="72x72"
          href="../images/apple-touch-icon-72x72.png">
    <link rel="apple-touch-icon" sizes="114x114"
          href="../images/apple-touch-icon-114x114.png">
</head>

<body>

<%
include('/includes/topnavi.jag');
%>

<div class="container-fluid" style="width: 960px; margin: auto;">
<div class="row">
    <div class="span16">
        <div class="page-header">
            <h1>
                Documentation
                <small>API documentation for Jaggery.js</small>
            </h1>
        </div>
    </div>
</div>

<div class="row">
<div class="span4">
    <div class="well">
        <%
        include('/includes/navi.jag');
        %>

    </div>

</div>
<div class="span12">
<div class="content" id="atomFeed" name="atomFeed">
    <h3>Entry</h3>

        <pre class="prettyprint linenums">
&lt%
//creating entries for feed
var entry = new Entry();
entry.title = "Jaggery Sample Entry";
entry.content = "This is content for a sample atom entry";
entry.authors = ["wso2", "Jaggery"];

//creating list of entris
var entries  = new Array();
entries.push(entry);

//creating feed
var feed= new Feed();
//adding new entries for Feed
feed.entries = entries;

//printing the feed
print(feed.toString());
%&gt
</pre>
    <%
    var reqCode = '&lt%'
    + '\n var entry = new Entry();'
    + '\n entry.title = "Jaggery Sample Entry";'
    + '\n entry.content = "This is content for a sample atom entry";'
    + '\n entry.authors = ["wso2", "Jaggery"];'
    + '\n'
    + '\n var entries  = new Array();'
    + '\n entries.push(entry);'
    + '\n '
    + '\n var feed= new Feed();'
    + '\n feed.entries = entries;'
    + '\n '
    + '\n print(feed.toString());'
    + '\n %&gt';

    var codeSnip = encodeURIComponent(reqCode);
    var urlString = '../tryitframe.jag?code='+codeSnip;

    include('/includes/tryit_but.jag');
    %>

    <div id="pageLinks">
                <a class="navilink" href="#overview">Overview</a>
                <a class="navilink" href="#members">Members</a>
                <a class="navilink" href="#operations">Operations</a>
                </div>
                 <section id="overview">
                     <h4>Overview</h4>
                      <p class="description">Entry object is the container for entries returned by Feed.</p>
                     </section>

    <section id="members">
        <h4>Members</h4>

        <table class="clsStd member-table">
            <tbody>
            <tr>
                <th>Member</th>
                <th>Type</th>
                <th>Description</th>
            </tr>
            <tr>
                <td>id</td>
                <td>String</td>
                <td>
		 <pre class="prettyprint">entry.id</pre>
                    Returns the id.
					<pre class="prettyprint">entry.id = "id1";</pre>
                   Setting the id attribute.
		</td>
            </tr>
            <tr>
                <td>authors</td>
                <td>String [ ] </td>
                <td>
		 <pre class="prettyprint">entry.authors[i]</pre>
                    Returns the i th author of the entry.
					<pre class="prettyprint">entry.authors = ["author1","author2"];</pre>
                    Setting an array of authors to the entry.
		</td>
            </tr>
            <tr>
                <td>categories</td>
                <td>String [ ]</td>
                <td>
	         <pre class="prettyprint">entry.categories[i]</pre>
                    Returns the i th category of the entry.
					<pre class="prettyprint">entry.categories = ["cat1","cat2"];</pre>
                    Setting an array of categories to the entry.
		</td>
            </tr>
            <tr>
                <td>content</td>
                <td>String </td>
                <td>
		 <pre class="prettyprint">entry.content</pre>
                    Returns the content.
					<pre class="prettyprint">entry.content = "content1";</pre>
                   Setting the content attribute.
		</td>
            </tr>
            <tr>
                <td>contributors</td>
                <td>String [ ] </td>
                <td>
		<pre class="prettyprint">entry.contributors[i]</pre>
                    Returns the i th contributor of the entry.
					<pre class="prettyprint">entry.contributors = ["cont1","cont2"];</pre>
                    Setting an array of contributors to the entry.
		</td>
            </tr>
            <tr>
                <td>links</td>
                <td>String [ ] </td>
                <td>
		<pre class="prettyprint">entry.links[i]</pre>
                    Returns the i th location of the entry.
					<pre class="prettyprint">entry.links = ["link1","link2"];</pre>
                    Setting locations of the entry.
		</td>
            </tr>
            <tr>
                <td>published</td>
                <td>Date </td>
                <td>
		<pre class="prettyprint">entry.published</pre>
                    Returns the published date of the entry.
					<pre class="prettyprint">var d1 = new Date("March 13, 2013 11:13:00")
entry.published = d1;</pre>
                    Setting published date of the entry.
		</td>
            </tr>
            <tr>
                <td>rights</td>
                <td>String </td>
                <td>
		 <pre class="prettyprint">entry.rights</pre>
                    Returns the rights associated with this entry.
					<pre class="prettyprint">entry.rights = "right1";</pre>
                    Setting rights associated with this entry.
		</td>
            </tr>
            <tr>
                <td>summary</td>
                <td>String </td>
                <td>
		 <pre class="prettyprint">entry.summary</pre>
                    Returns the summary of this entry.
					<pre class="prettyprint">entry.summary = "summary1";</pre>
                    Setting the summary attribute.
		</td>
            </tr>
            <tr>
                <td>title</td>
                <td>String </td>
                <td>
		 <pre class="prettyprint">entry.title</pre>
                    Returns the title of this entry.
					<pre class="prettyprint">entry.title = "title1";</pre>
                    Setting the title attribute.
		</td>
            </tr>
            <tr>
                <td>updated</td>
                <td>Date</td>
                <td>
		<pre class="prettyprint">entry.updated</pre>
                    Returns the last updated date of the entry.
					<pre class="prettyprint">var d1 = new Date("March 13, 2013 11:13:00")
entry.updated = d1;</pre>
                    Setting the last updated date of the entry.
		</td>
            </tr>

            </tbody>
        </table>
    </section>
        <section id="operations">
<h4>Operations</h4>
<table class="clsStd operations-table">

    <tbody>

    <tr>

        <th>Operations</th>
       <th>Returns</th>
        <th>Description</th>

    </tr>
                <tr>
                    <td>
                    <code>Entry()</code>
                    </td>
                    <td>Entry</td>
                    <td>
		    <pre class="prettyprint">var entry = new Entry();</pre>
                   Returns an Entry object
		   </td>
                </tr>
				<tr>
                    <td>
                    <code>toXML()</code>
                    </td>
                    <td>XML</td>
                    <td> 
		    <pre class="prettyprint">entry.toXML()</pre>
		     Returns the E4X XML contents of this Entry object.
		    </td>
                </tr>
                <tr>
                    <td>
                    <code>toString()</code>
                    </td>
                    <td>String</td>
                    <td>
		    <pre class="prettyprint">entry.toString()</pre>
		     Returns the String representation of the Entry</td>
                </tr>

    <tbody>
    </table>
    </section>



</div>
<br>
</div>

</div>
<%
include('/includes/footer.jag');
%>

</div>

<!-- /container -->
<%
include('/includes/scripts.jag')
%>
<script>

    $(document).ready(function () {
        $('#entry').toggleClass('active')
        $('#docs').addClass('active')
    })
</script>
</body>
</html>
