swirl Guide to OmniMark 6   OmniMark home
docs home 
IndexConceptsTasksSyntaxLibrariesOMX VariablesErrors
 
      Other Library Functions  
function   to-net-long   Available in:
Professional
Enterprise

Library: omnetutl - miscellaneous network utilities
Include: omnetutl.xin
Return type: Integer
Returns:       

Returns a sequence of bytes/octets that is the long network number encoding of an integer value.


Declaration

  to-net-long (c)
  where
c
is an integer value


Purpose

Use to-net-long to translate an integer value into a sequence of bytes/octets that is the integer value's long network number encoding.

Requirements

You must include the following line at the beginning of your OmniMark program:


  include "omnetutl.xin"

Example


  include "omnetutl.xin"

  process
     local stream network-bytes
     local integer host-long initial {"12345678"}
     local integer translated-long
     set network-bytes to to-net-long (host-long)
  ;  Check to make sure the conversion worked:   
     set translated-long to from-net-long (network-bytes)
     output "translated-long = %d(translated-long)%n"

        Other Library Functions
   from-net-long
   NETGetHostIP
   NETGetHostName
   NETIsVersionCompatible
   NETLibraryVersion
   net-long
   to-net-long
 
----  

Top [ INDEX ] [ CONCEPTS ] [ TASKS ] [ SYNTAX ] [ LIBRARIES ] [ OMX ] [ ERRORS ]

OmniMark 6.5 Documentation Generated: December 23, 2002 at 6:25:44 pm
If you have any comments about this section of the documentation, send email to [email protected]

Copyright © OmniMark Technologies Corporation, 1988-2002.