ftp.nice.ch/pub/next/developer/resources/classes/CompSim.s.tar.gz#/CompSim/Incrementor.h

This is Incrementor.h in view mode; [Download] [Up]

//
// Incrementor
//
// An Objective-C class for the simulation of digital logic.
// 
// Incrementor very simply increments its n-bit input and
// puts the result on its n-bit output.
//


#import <objc/Object.h>
#import "Node.h"
#import "One.h"
#import "Adder.h"


@interface Incrementor : Object


{
    //
    // Basic state:
    //
    
    int		numbits;
    
    //
    // External interface:
    //
    
    Node	*IN;					// n-bit input node.
    Node	*OUT;					// n-bit output node.
    
    //
    // Internal Functional Unit:
    //
    
    Adder	*adder;
    
    //
    // Internal Glue Nodes:
    //
    
    Node	*one;					// n-bit constant = 1.
    Node	*foo;					// 1-bit dummy node for non-connections.
}


- initNumBits:(int)nbits in:innode out:outnode;
- free;

- cycle;


@end


//
// End of file.
//

These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.