PHP Classes
Icontem

File: DATA/Number.php


  Search   All class groups All class groups   Latest entries Latest entries   Top 10 charts Top 10 charts   Newsletter Newsletter   Blog Blog   Forums Forums   Help FAQ Help FAQ  
  Login   Register  
Recommend this page to a friend! ReTweet ReTweet Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Martin Alterisio  >  DATA  >  DATA/Number.php  
File: DATA/Number.php
Role: Class source
Content type: text/plain
Description: Interface for numerical objects.
Class: DATA
Access data stored in MySQL tables like arrays
 

Contents

Class file image Download
<?php
/**
 * @package DATA
 */

/**
 * Interface for numerical objects.
 */
interface DATA_Number {
    
/**
     * Returns the number in a native php type.
     * 
     * @return int|float|string Number value.
     */
    
public function getNumber();
    
/**
     * Adds this number to another and returns the result.
     * 
     * @param DATA_Number $other The number to add.
     * @return DATA_Number The result.
     */
    
public function add(DATA_Number $other);
    
/**
     * Substracts this number to another and returns the result.
     * 
     * @param DATA_Number $other The number to substract.
     * @return DATA_Number The result.
     */
    
public function substract(DATA_Number $other);
    
/**
     * Multiplies this number to another and returns the result.
     * 
     * @param DATA_Number $other The number to multiply by.
     * @return DATA_Number The result.
     */
    
public function multiply(DATA_Number $other);
    
/**
     * Divides this number to another and returns the result.
     * 
     * @param DATA_Number $other The number to divide by.
     * @return DATA_Number The result.
     */
    
public function divide(DATA_Number $other);
}
?>

 
  Advertise on this site Advertise on this site   Site map Site map   Statistics Statistics   Site tips Site tips   Privacy policy Privacy policy   Contact Contact  

For more information send a message to :
info at phpclasses dot org.
Copyright (c) Icontem 1999-2009 PHP Classes - PHP Class Scripts
  PHP Book Reviews - Reviews of books and other products