Skip to content

T_CodeJam_HGlobal

andrewvk edited this page Jul 1, 2016 · 4 revisions

HGlobal Class

Wraps Mashal.AllocHGlobal and Marshal.FreeHGlobal.

Inheritance Hierarchy

System.Object
  System.Runtime.ConstrainedExecution.CriticalFinalizerObject
    CodeJam.HGlobal
Namespace: CodeJam
Assembly: CodeJam (in CodeJam.dll) Version: 1.1.0.0 (1.1.0.0)

Syntax

C#

[SecurityCriticalAttribute]
public class HGlobal : CriticalFinalizerObject, IDisposable

VB

<SecurityCriticalAttribute>
Public Class HGlobal
	Inherits CriticalFinalizerObject
	Implements IDisposable

F#

[<SecurityCriticalAttribute>]
type HGlobal =  
    class
        inherit CriticalFinalizerObject
        interface IDisposable
    end

The HGlobal type exposes the following members.

Constructors

 

Name Description
Public method HGlobal(Int32) Allocates memory from the unmanaged memory of the process by using the specified number of bytes.
Public method HGlobal(IntPtr) Takes ownership over given pointer.
  Back to Top

Properties

 

Name Description
Public property Data Pointer to data.
Public property Length Length
  Back to Top

Methods

 

Name Description
Public method Dispose Dispose method to free all resources.
Public method Equals Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected method Finalize Finalizer. (Overrides CriticalFinalizerObject.Finalize().)
Public method GetHashCode Serves as the default hash function. (Inherited from Object.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public method ToString Returns a string that represents the current object. (Inherited from Object.)
  Back to Top

See Also

Reference

CodeJam Namespace

Clone this wiki locally