Core Function DLLStructGetDef

From Sputnik Wiki
(Difference between revisions)
Jump to: navigation, search
(Created page with "<pre> DLLStructGetDef( <name> ) </pre> === Description === Return the <def string> of a given DLLStruct created by DLLStructCreateDef(). === Parameters === ==== name ==== T...")
 
(Example)
Line 24: Line 24:
  
 
=== Example ===
 
=== Example ===
 +
 +
This example gets the DefString by direct name created by DLLStructCreateDef:
  
 
<syntaxhighlight lang="sputnik">
 
<syntaxhighlight lang="sputnik">
Line 29: Line 31:
 
$DefString = DLLStructGetDef("POINT");
 
$DefString = DLLStructGetDef("POINT");
 
println("The def string of 'POINT' is: " . $DefString);
 
println("The def string of 'POINT' is: " . $DefString);
 +
</syntaxhighlight>
 +
 +
This example gets the DefString by variable created by DLLStructCreate:
 +
 +
<syntaxhighlight lang="sputnik">
 +
$Point = DLLStructCreate("int x; int y");
 +
$DefString = DLLStructGetDef($Point);
 +
println("The def string is: " . $DefString);
 
</syntaxhighlight>
 
</syntaxhighlight>
  
 
[[Category:Core Function]]
 
[[Category:Core Function]]

Revision as of 00:09, 20 April 2012

DLLStructGetDef( <name> )

Contents

Description

Return the <def string> of a given DLLStruct created by DLLStructCreateDef().

Parameters

name

The name of a DLLStruct created using DLLStructCreateDef.

Return Value

Success: The <def string> of the DLLStruct.

Failure: 0.

Remarks

None.

Example

This example gets the DefString by direct name created by DLLStructCreateDef:

DLLStructCreateDef("POINT", "int x;int y");
$DefString = DLLStructGetDef("POINT");
println("The def string of 'POINT' is: " . $DefString);

This example gets the DefString by variable created by DLLStructCreate:

$Point = DLLStructCreate("int x; int y");
$DefString = DLLStructGetDef($Point);
println("The def string is: " . $DefString);
Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox