This is more of a request for a history lesson here about the Revit api, but whats the deal with the method get_Parameter()? I've seen it used in past forum posts for use in Revit versions before 2022, but I don't see any references to it in the revitapidocs. Does anyone know where it stems from (the API, another API, the enchanted jungle of BIM?) and if still a valid method to use today in leau of GetParameter() method (seems far easier to just use get_Parameter with a GUID vs GetParameter.
Thanks!
Solved! Go to Solution.
Solved by jeremy_tammik. Go to Solution.
Hi.
Sorry that I do not feel motivated to answer this in full.
I addressed the exact same question here in the forum recently. So, all you get is the short version:
https://duckduckgo.com/?q=.net+get_+property+prefix
Please figure it out yourself from there, or search for the previous answer to the same question.
Happy weekend!
I made the effort of searching for the previous answer as well.
Since it has come up twice in a row, I guess I'll add it to the blog anon.
Here it is:
https://forums.autodesk.com/t5/revit-api-forum/importinstance-geometry-vs-get-geometry/m-p/11720577
Oh, and to wrap up: what is the Seinfeld bassline, please?
Later: I guess it is common knowledge, just not to me:
Thanks for the link(s) @jeremy_tammik. those helped figure it out!
As for the Seinfeld bassline bit, that was my poor attempt at humor :).
Have a good weekend as well!
There is a reference to it here in the older literature. (and New)
https://www.revitapidocs.com/2020/0cf342ef-c64f-b0b7-cbec-da8f3428a7dc.htm
I think this dates back a long ways including references in 2010...
https://thebuildingcoder.typepad.com/blog/2010/08/get-element-type.html
This is not the same. It isn't an API design choice it is just calling an underlying method because C# can't use indexed properties.
Every indexed property has an underlying method in MSIL to retrieve the value these are prefixed 'get_' . So to avoid the indexed property issue C# uses the underlying method directly instead.
Note that in above example 'RowKey' has no 'set_RowKey' because it is ReadOnly.
Can't find what you're looking for? Ask the community or share your knowledge.