<?php $isip_window_title = "ISIP Homepage"; ?>
<?php include("/data/isip/www/templates/documentation/header/header.html"); ?>

<!--#set var="isip_page_title" value="Llong" -->
<?php include("/data/isip/www/templates/documentation/body/index_class.html"); ?>
<?php include("/data/isip/www/templates/documentation/body/bar.html"); ?>

<a name="name">
<b>name: <a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h">Llong</a>:  public  <a href="../MScalar/index.html">MScalar&lt;llong, int64&gt;</a></b> 

<br><br>

<a name="synopsis">
<b>synopsis:</b>
<br><br>

<blockquote>
<pre>
g++ [flags ...] file ... -l /isip/tools/lib/$ISIP_BINARY/lib_math_scalar.a

#include &lt;Llong.h&gt;

Llong(llong arg = DEF_VALUE);
Llong(const Llong& arg);
</pre>
</blockquote>

<a name="quick_start">
<b>quick start:</b>
<br><br>

<blockquote>
<pre>
Llong val0;
val0 = 10;

Llong val1(5);
Llong val2;

val2 = val0.exp10(2) + val1.factorial();

</pre>
</blockquote>

<a name="description"> 
<b>description:</b>
<br><br>

The Llong class manages 64-bit signed integers. It is derived from the
<a href="../MScalar/index.html">MScalar</a>
class and inherits the commonly-used mathematical, logical, DSP
and i/o methods from it. A Llong object can read itself from (or write
itself to) a Sof file. It includes the memory management methods which
use the MemoryManager class to allocate or delete memory.

<br><br>

<a name="dependencies">
<b>dependencies:</b>
<br><br>

<ul>
  <li> <a href="../MScalar/index.html">MScalar</a>
</ul>


<a name="constants">
<b>public constants:</b>
<br><br>

<ul>
  <li> define the class name:
       
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/llng_00.cc&constant=CLASS_NAME">static const String CLASS_NAME = L"Llong";</a></pre>
</ul>

<a name="error">
<b>error codes:</b>
<br><br>

<ul>
  <li> error code indicating console class general error:
       
       <pre><a href="/perl/ifc_document.pl?err=00020900">static const long ERR = 20900;</a></pre>
</ul>

<a name="protected">
<b>protected data:</b>
<br><br>

<ul>
  <li> static memory manager:
       
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/llng_00.cc&static=mgr_d">static MemoryManager mgr_d;</a></pre>
</ul>

<a name="public">
<b>required public methods:</b>
<br><br>

<ul>
  <li> static methods:
       
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=name">static const String& name();</a></pre>
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/llng_02.cc">static boolean diagnose(Integral::DEBUG debug_level);</a></pre>
       
  <li> debug methods:
       
       <pre>setDebug is inherited from the <a href="../MScalar/index.html#public:debug">MScalar</a> template class</pre>
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/llng_01.cc">boolean debug(const unichar* message) const;</a></pre>
       
  <li> destructor/constructor(s):
       
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=destructor">~Llong()</a></pre>
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=default+constructor&instance=0">Llong(llong arg = DEF_VALUE);</a></pre>
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=copy+constructor">Llong(const Llong& arg);</a></pre>
       
  <li> assign methods:
       
 <pre>assign methods are inherited from the <a href="../MScalar/index.html#public:assign">MScalar</a> template class</pre>

  <li> operator= methods:
       
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=operator%3D&instance=0">Llong& operator= (const Llong& arg);</a></pre>
       
  <li> i/o methods:
       
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong//Llong.h&method=read">boolean read(Sof& sof, long tag, const String& name = CLASS_NAME);</a></pre>
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong//Llong.h&method=write">boolean write(Sof& sof, long tag, const String& name = CLASS_NAME) const;</a></pre>
 <pre>readData and writeData are inherited from the <a href="../MScalar/index.html#public:io">MScalar</a> template class</pre>
       <pre>sofSize is inherited from the <a href="../MScalar/index.html#public:io">MScalar</a> template class</pre>
       
  <li> equality methods:
       
  <pre>equality methods are inherited from the <a href="../MScalar/index.html#public:equality">MScalar</a> template class</pre>
       
 <li> memory management methods:
      
      <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=new">static void* operator new(size_t size);</a></pre>
      <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=new[]">static void* operator new[](size_t size);</a></pre>
      <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=delete">static void operator delete(void* ptr);</a></pre>
      <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=delete[]">static void operator delete[](void* ptr);</a></pre>
      <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=setGrowSize">static boolean setGrowSize(long grow_size);</a></pre>
      <pre>clear is inherited from the <a href="../MScalar/index.html#public:memory">MScalar</a> template class</pre>
</ul>

<a name="public">
<a name="specific">
<b>class-specific public methods:</b>
<br><br>

<ul>
  
  <li> operator overload methods:
       
       <pre><a href="/perl/ifc_document.pl?file=$isip/class/math/scalar/Llong/Llong.h&method=operator%3D&instance=1">Llong& operator= (llong arg);</a></pre>
</ul>

<a name="private">
<b>private methods:</b>
<ul>
      <li>declare trigonometric methods as private because they cannot be
      defined for llong operations.
       <pre> llong acos(llong); </pre>
       <pre> llong acosh(llong); </pre>
       <pre> llong asin(llong);</pre>
       <pre> llong asinh(llong); </pre>
       <pre> llong atan(llong); </pre>
       <pre> llong atanh(llong); </pre>
       <pre> llong cos(llong); </pre>
       <pre> llong cosh(llong); </pre>
       <pre> llong sin(llong);</pre>
       <pre> llong sinh(llong); </pre>
       <pre> llong tan(llong); </pre>
       <pre> llong tanh(llong); </pre>

   <li>declare those methods as private which cannot be defined for
      integer numbers
       <pre> llong ceil(llong);</pre>
       <pre> llong rceil(llong);</pre>
       <pre> llong rfloor(llong);</pre>
       <pre> llong round(llong);</pre>
       <pre> llong floor(llong);</pre>
       <pre> llong fraction(llong);</pre> 
</ul>

<a name="examples">
<b>examples:</b>
<br><br>

<ul>
  <li> This example shows how to write a Llong object into a Sof file:
       
       <pre>
Llong val0(5);
String tmp_filename(L"foo");
Sof tmp_file;
tmp_file.open(tmp_filename, File::WRITE_ONLY, File::TEXT);
       
val0.write(tmp_file, (long)0);
tmp_file.close();
       </pre>

  <li> This example shows how to do some mathematic calculations and limit the result to the given range:
       
<pre>
Llong value;
Llong value1;
Llong value2;

llong coef1 = 7;
llong coef2 = 3;
       
llong min = 0;
llong max = 255;

value1 = 4;
value2 = 5;

value = value1.exp(2)*coef1 + value2.exp(3)*coef2;
value.limit(min, max);</pre>
</ul>

<a name="notes">
<b>notes:</b>
<br><br>

<ul>
  <li> See the
       <a href="../MScalar/index.html#notes">notes section of MScalar</a>.
</ul>       

<!--#include virtual="/hse/ies/templates/documentation/footer/footer.html" -->
