Object API/it: Difference between revisions

From FreeCAD Documentation
(Updating to match new version of source page)
(Updating to match new version of source page)
 
(9 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<languages/>
{{VeryImportantMessage|(Ottobre 2019) Non modificare queste pagine. Le informazioni sono incomplete e obsolete. Per l'API più recente, consultare la [https://www.freecadweb.org/api documentazione API autogenerata] o generare la documentazione autonomamente. Vedere [[Source documentation/it|Documentazione del codice sorgente]].}}

Essendo parametrici, in FreeCAD gli oggetti del documento possono avere un sacco di altre proprietà. Queste sono quelle di base, presenti in ogni FreeCAD Document Object. Gli oggetti possono essere recuperati semplicemente con il loro nome. Esempio:
Essendo parametrici, in FreeCAD gli oggetti del documento possono avere un sacco di altre proprietà. Queste sono quelle di base, presenti in ogni FreeCAD Document Object. Gli oggetti possono essere recuperati semplicemente con il loro nome. Esempio:
{{Code|code=
<syntaxhighlight>
myObj = FreeCAD.ActiveDocument.myObjectName
myObj = FreeCAD.ActiveDocument.myObjectName
print myObj.PropertiesList
print myObj.PropertiesList
}}
</syntaxhighlight>


{{APIProperty|Content|Una rappresentazione XML delle proprietà di un oggetto.}}
{{APIProperty|Label|Ottiene / imposta l'etichetta degli oggetti. La stringa può essere unicode.}}
{{APIProperty|Name|Il nome univoco di un oggetto.}}
{{APIProperty|Placement|Ottiene / imposta il posizionamento di un oggetto. Un posizionamento definisce un orientamento (rotazione) ed una posizione (base) nello spazio 3D. Viene utilizzato quando non è necessario alcun ridimensionamento o altro tipo di distorsione.}}
{{APIProperty|PropertiesList|Un elenco delle proprietà di un oggetto}}
{{APIProperty|State| Lo stato di FreeCAD di un oggetto (ad esempio se deve essere ricalcolato)}}
{{APIProperty|Type|Una stringa che descrive il tipo di oggetto}}
{{APIProperty|ViewObject|Il View Provider associato (oggetto FreeCADGUI) a un oggetto}}
{{APIFunction|getAllDerivedFrom| | |Tutti i discendenti di questo oggetto}}
{{APIFunction|getDocumentationOfProperty| | |La stringa di documentazione della proprietà di questa classe.}}
{{APIFunction|getGroupOfProperty| | |Il nome del gruppo a cui appartiene la proprietà in questa categoria. Le proprietà sono ordinate in gruppi diversi denominati secondo convenienza.}}
{{APIFunction|getPropertyByName| | |Il valore di una proprietà denominata.}}
{{APIFunction|getTypeOfProperty| | |Il tipo di una proprietà denominata. Questo può essere (Hidden,ReadOnly,Output) o qualsiasi combinazione.}}
{{APIFunction|isDerivedFrom| | |True se il tipo dato è un padre}}
{{APIFunction|purgeTouched| |Contrassegna l'oggetto come unchanged (invariato)| }}
{{APIFunction|touch| |Contrassegna l'oggetto come changed (modificato, toccato)| }}


{{Userdocnavi{{#translation:}}}}
{{APIProperty|Content|An XML representation of the properties of an object.}}
[[Category:API{{#translation:}}]]
{{APIProperty|Label|Gets/sets the objects label. The string can be unicode.}}
[[Category:Poweruser Documentation{{#translation:}}]]
{{APIProperty|Name|The unique name of an object.}}
{{clear}}
{{APIProperty|Placement|Gets/sets the Placement of an object. A placement defines an orientation (rotation) and a position (base) in 3D space. It is used when no scaling or other distortion is needed.}}
{{APIProperty|PropertiesList|A list of the properties of an object}}
{{APIProperty|State|The FreeCAD state of an object (ie. if it needs to be recomputed)}}
{{APIProperty|Type|A string describing the type of an object}}
{{APIProperty|ViewObject|The associated View Provider (FreeCADGUI object) of an object}}
{{APIFunction|getAllDerivedFrom| | |All descendants of this object}}
{{APIFunction|getDocumentationOfProperty| | |The documentation string of the property of this class.}}
{{APIFunction|getGroupOfProperty| | |The name of the group which the property belongs to in this class. The properties are sorted in different named groups for convenience.}}
{{APIFunction|getPropertyByName| | |The value of a named property.}}
{{APIFunction|getTypeOfProperty| | |The type of a named property. This can be (Hidden,ReadOnly,Output) or any combination.}}
{{APIFunction|isDerivedFrom| | |True if given type is a father}}
{{APIFunction|purgeTouched| |Marks the object as unchanged| }}
{{APIFunction|touch| |Marks the object as changed (touched)| }}

[[Category:API/it]]
<languages/>

Latest revision as of 21:03, 27 February 2020

Other languages:
(Ottobre 2019) Non modificare queste pagine. Le informazioni sono incomplete e obsolete. Per l'API più recente, consultare la documentazione API autogenerata o generare la documentazione autonomamente. Vedere Documentazione del codice sorgente.

Essendo parametrici, in FreeCAD gli oggetti del documento possono avere un sacco di altre proprietà. Queste sono quelle di base, presenti in ogni FreeCAD Document Object. Gli oggetti possono essere recuperati semplicemente con il loro nome. Esempio:

myObj = FreeCAD.ActiveDocument.myObjectName
print myObj.PropertiesList
Content

Returns: Una rappresentazione XML delle proprietà di un oggetto.

Label

Returns: Ottiene / imposta l'etichetta degli oggetti. La stringa può essere unicode.

Name

Returns: Il nome univoco di un oggetto.

Placement

Returns: Ottiene / imposta il posizionamento di un oggetto. Un posizionamento definisce un orientamento (rotazione) ed una posizione (base) nello spazio 3D. Viene utilizzato quando non è necessario alcun ridimensionamento o altro tipo di distorsione.

PropertiesList

Returns: Un elenco delle proprietà di un oggetto

State

Returns: Lo stato di FreeCAD di un oggetto (ad esempio se deve essere ricalcolato)

Type

Returns: Una stringa che descrive il tipo di oggetto

ViewObject

Returns: Il View Provider associato (oggetto FreeCADGUI) a un oggetto

getAllDerivedFrom( )

Description:

Returns: Tutti i discendenti di questo oggetto

getDocumentationOfProperty( )

Description:

Returns: La stringa di documentazione della proprietà di questa classe.

getGroupOfProperty( )

Description:

Returns: Il nome del gruppo a cui appartiene la proprietà in questa categoria. Le proprietà sono ordinate in gruppi diversi denominati secondo convenienza.

getPropertyByName( )

Description:

Returns: Il valore di una proprietà denominata.

getTypeOfProperty( )

Description:

Returns: Il tipo di una proprietà denominata. Questo può essere (Hidden,ReadOnly,Output) o qualsiasi combinazione.

isDerivedFrom( )

Description:

Returns: True se il tipo dato è un padre

purgeTouched( )

Description: Contrassegna l'oggetto come unchanged (invariato)

Returns:

touch( )

Description: Contrassegna l'oggetto come changed (modificato, toccato)

Returns: