Expose H Program Package File

This section describes how to load an H program package file.

If you are tired of typing the package name when access package variables and functions, you can expose them as native variables and functions with the following syntax:

$expose package_name.variable_name $as new_variable_name; 
$expose package_name.function_name $as new_function_name; 
$expose package_name.variable_name; # keep the original name 
$expose package_name.function_name; # keep the original name
$expose package_name; # expose all variables and functions

Example of exposing H package variables and functions:

$load c $from "circle.h";
$expose c; 
$expose c.area $as a; 
$expose c.circumference $as cf; 

write(pi); # same as write(c.pi);

Table of Contents

 About This Book

 Introduction of H Language


 Data Types




 "boolean" Data Type

 "integer" Data Type

 "string" Data Type

 "real" Data Type

 "array" Data Type

Source Code Packages

 What Is Function

 Create H Program Package File

 Load H Program Package File

 Load Program Package Multiple Times

 Load Program Package in Functions

 Load Program Package Remotely

Expose H Program Package File

 Classes and Objects

 Object Oriented Programming

 Inheritance - Object Attachments

 Encapsulation - Private Members


 Full Version in PDF/ePUB