Forum und email

COM support functies voor Windows

Introductie

COM is a technology which allows the reuse of code written in any language (by any language) using a standard calling convention and hiding behind APIs the implementation details such as what machine the Component is stored on and the executable which houses it. It can be thought of as a super Remote Procedure Call (RPC) mechanism with some basic object roots. It separates implementation from interface.

COM encourages versioning, separation of implementation from interface and hiding the implementation details such as executable location and the language it was written in.

Afhankelijkheden

COM functies zijn alleen bruikbaar in de Windows versie van PHP.

Installatie

Er zijn geen handelingen nodig m.b.t. tot installatie voor deze functies, deze maken deel uit van de kern van PHP.

Deze functies worden automatisch ingebouwd in de windows versie van PHP. Er zijn geen extra handelingen nodig om deze functies te gebruiken.

Configuratie tijdens scriptuitvoer

Het gedrag van deze functies wordt beïnvloed vanuit php.ini.

Com configuratie opties
Naam Standaard waarde Veranderbaar
com.allow_dcom "0" PHP_INI_SYSTEM
com.autoregister_typelib "0" PHP_INI_SYSTEM
com.autoregister_verbose "0" PHP_INI_SYSTEM
com.autoregister_casesensitive "1" PHP_INI_SYSTEM
com.typelib_file "" PHP_INI_SYSTEM
Voor verdere details en definities van de PHP_INI_* konstanten, zie ini_set().

Voorgedefinieerde constanten

Deze constanten worden gedefinieerd door deze extensie, en zullen alleen beschikbaar zijn als de extensie met PHP is meegecompileerd, of als deze dynamisch is geladen vanuit een script.

CLSCTX_INPROC_SERVER (integer)
CLSCTX_INPROC_HANDLER (integer)
CLSCTX_LOCAL_SERVER (integer)
CLSCTX_REMOTE_SERVER (integer)
CLSCTX_SERVER (integer)
CLSCTX_ALL (integer)
VT_NULL (integer)
VT_EMPTY (integer)
VT_UI1 (integer)
VT_I2 (integer)
VT_I4 (integer)
VT_R4 (integer)
VT_R8 (integer)
VT_BOOL (integer)
VT_ERROR (integer)
VT_CY (integer)
VT_DATE (integer)
VT_BSTR (integer)
VT_DECIMAL (integer)
VT_UNKNOWN (integer)
VT_DISPATCH (integer)
VT_VARIANT (integer)
VT_I1 (integer)
VT_UI2 (integer)
VT_UI4 (integer)
VT_INT (integer)
VT_UINT (integer)
VT_ARRAY (integer)
VT_BYREF (integer)
CP_ACP (integer)
CP_MACCP (integer)
CP_OEMCP (integer)
CP_UTF7 (integer)
CP_UTF8 (integer)
CP_SYMBOL (integer)
CP_THREAD_ACP (integer)

Zie ook

Voor meer informatie over COM lees » COM specification of neem een kijkje in Don Box's » Yet Another COM Library (YACL)

Table of Contents

  • COM — COM klasse
  • DOTNET — DOTNET class
  • VARIANT — VARIANT klasse
  • com_addref — Verhoogt de teller van het component waar naar verwezen wordt.
  • com_create_guid — Generate a globally unique identifier (GUID)
  • com_event_sink — Connect events from a COM object to a PHP object
  • com_get_active_object — Returns a handle to an already running instance of a COM object
  • com_get — Haalt de waarde op van een eigenschap van een COM Component
  • com_invoke — Roept een methode aan van een COM component.
  • com_isenum — Pakt een IEnumVariant
  • com_load_typelib — Laadt een Typelib
  • com_load — Maakt een nieuwe instantie naar een COM component
  • com_message_pump — Process COM messages, sleeping for up to timeoutms milliseconds
  • com_print_typeinfo — Print out a PHP class definition for a dispatchable interface
  • com_propget — Alternatief voor com_get
  • com_propput — Alternatief voor com_put
  • com_propset — Alternatief voor com_put
  • com_release — Verlaagt de teller van het component waar naar verwezen wordt.
  • com_set — Geeft een nieuwe waarde aan een eigenschap van een COM component
  • variant_abs — Returns the absolute value of a variant
  • variant_add — "Adds" two variant values together and returns the result
  • variant_and — performs a bitwise AND operation between two variants and returns the result
  • variant_cast — Convert a variant into a new variant object of another type
  • variant_cat — concatenates two variant values together and returns the result
  • variant_cmp — Compares two variants
  • variant_date_from_timestamp — Returns a variant date representation of a Unix timestamp
  • variant_date_to_timestamp — Converts a variant date/time value to Unix timestamp
  • variant_div — Returns the result from dividing two variants
  • variant_eqv — Performs a bitwise equivalence on two variants
  • variant_fix — Returns the integer portion ? of a variant
  • variant_get_type — Returns the type of a variant object
  • variant_idiv — Converts variants to integers and then returns the result from dividing them
  • variant_imp — Performs a bitwise implication on two variants
  • variant_int — Returns the integer portion of a variant
  • variant_mod — Divides two variants and returns only the remainder
  • variant_mul — multiplies the values of the two variants and returns the result
  • variant_neg — Performs logical negation on a variant
  • variant_not — Performs bitwise not negation on a variant
  • variant_or — Performs a logical disjunction on two variants
  • variant_pow — Returns the result of performing the power function with two variants
  • variant_round — Rounds a variant to the specified number of decimal places
  • variant_set_type — Convert a variant into another type "in-place"
  • variant_set — Assigns a new value for a variant object
  • variant_sub — subtracts the value of the right variant from the left variant value and returns the result
  • variant_xor — Performs a logical exclusion on two variants