.NET

Reply
Distinguished Mentor
BlackBox_
Posts: 701
Registered: ‎02-25-2013
Message 1 of 10 (250 Views)
Accepted Solution

LayerTable.GetUnreconciledLayers()

250 Views, 9 Replies
06-05-2013 09:46 AM

I am attempting to help someone else by writing a LispFunction Method, which calls LayerTable.GetUnreconciledLayers().

 

Unless I've overlooked something, last night when I started coding this at home GetUnreconciledLayers() required no argument, and returned ObjectIdCollection (2014).

 

Today during lunch, however (2012):

No overload for method 'GetUnreconciledLayers' takes 0 arguments

 ... Seemingly something changed between the two versions, which is fine, I don't mind accounting for that with an 18, and 19 assembly version... I just cannot find an example of how to supply:

AcArray<AcDbObjectId,AcArrayMemCopyReallocator<AcDbObjectId> >

 ... As an argument to my GetUnreconciledLayers() call, in any of the developer documentation, DevBlog articles, etc.

 

 

 

Any assistance would be greatly appreciated.

 

Cheers



"Potential has a shelf life." - Margaret Atwood


Autodesk Exchange Apps ~ Autoloader ~ AutoCAD Security

*Expert Elite*
Jeff_M
Posts: 3,963
Registered: ‎07-22-2003
Message 2 of 10 (234 Views)

Re: LayerTable.GetUnreconciledLayers()

06-05-2013 12:13 PM in reply to: BlackBox_

Perhaps this?

http://www.theswamp.org/index.php?topic=42795.0

Jeff_M, also a frequent Swamper
Distinguished Mentor
BlackBox_
Posts: 701
Registered: ‎02-25-2013
Message 3 of 10 (227 Views)

Re: LayerTable.GetUnreconciledLayers()

06-05-2013 12:43 PM in reply to: Jeff_M

Jeff_M wrote:

Perhaps this?

http://www.theswamp.org/index.php?topic=42795.0


Thanks, Jeff... Tony's offering looks like the ticket.

 

The only part that confuses me a bit, is the ObjectIdCollection argument being passed... Doesn't the LayerTable itself possess the LayerTableRecord ObjectIds? *confused*

 

Cheers



"Potential has a shelf life." - Margaret Atwood


Autodesk Exchange Apps ~ Autoloader ~ AutoCAD Security

*Expert Elite*
Jeff_M
Posts: 3,963
Registered: ‎07-22-2003
Message 4 of 10 (223 Views)

Re: LayerTable.GetUnreconciledLayers()

06-05-2013 12:54 PM in reply to: BlackBox_

I haven't tested it, but my guess is that the ids are an output parameter. So that will be the collection of Unreconciled Layer Ids.

Jeff_M, also a frequent Swamper
Distinguished Mentor
BlackBox_
Posts: 701
Registered: ‎02-25-2013
Message 5 of 10 (217 Views)

Re: LayerTable.GetUnreconciledLayers()

06-05-2013 01:33 PM in reply to: Jeff_M

Jeff_M wrote:

I haven't tested it, but my guess is that the ids are an output parameter. So that will be the collection of Unreconciled Layer Ids.


That makes sense... As always, thanks for the guidance, Jeff.

 

Cheers



"Potential has a shelf life." - Margaret Atwood


Autodesk Exchange Apps ~ Autoloader ~ AutoCAD Security

Valued Mentor
Posts: 370
Registered: ‎05-06-2012
Message 6 of 10 (179 Views)

Re: LayerTable.GetUnreconciledLayers()

06-06-2013 05:15 PM in reply to: BlackBox_

I'm still not sure what the person that implemented this method was thinking.

 

It's unusable from managed code, which seems to suggest that it was completely botched.

 

Jeff's link to my swamp post shows how to P/Invoke the native API.

ADN Support Specialist
Balaji_Ram
Posts: 609
Registered: ‎03-21-2011
Message 7 of 10 (163 Views)

Re: LayerTable.GetUnreconciledLayers()

06-06-2013 09:30 PM in reply to: DiningPhilosopher

We had brought this to the notice of our engineering team and is likely to be fixed soon.

 

Sorry for the trouble.



Balaji
Developer Technical Services
Autodesk Developer Network

Valued Mentor
Posts: 319
Registered: ‎05-12-2009
Message 8 of 10 (156 Views)

Re: LayerTable.GetUnreconciledLayers()

06-06-2013 09:52 PM in reply to: Balaji_Ram

Today was my sons 6th birthday and had a bowling party where I spent a decent amount money and had to deal with and entertain 30 other people's creepy little kids so in the mood to rant.

 

DiningPhilosopher wrote:

I'm still not sure what the person that implemented this method was thinking.


I think the problem is there is no person or person reviewing and testing. I seem to remeber Kean mentioned on his blog that it is automated and done with some tool or program.

 

What that tells me is there is not much reviewing of what was generated and that no testing was done.

I do not see how they could even sucessfully compile if GetUnreconciledLayers() was called for testing.

 

This is pure speculation but I do not think it is so much the people responsible for the API that allow this to happen, but for the higher-ups who decide on how much resources will be used for maintaining the API, and with limited resources and a deadline to roll it out they do what they can.

 

It is acceptable for unuseable methods to make it in the release of the API?

Unuseable is probably not the right word but a method that will not allow you to do a successful build.

 

I know autodesk was aware of this before 2014 release, and still not fixed.

 

In the 2013 documentation the signature was

 

public unsafe void GetUnreconciledLayers(
    AcArray<AcDbObjectId,AcArrayMemCopyReallocator<AcDbObjectId>>* modopt(IsImplicitlyDereferenced) idArray
);

 In 2014 documentation it was changed to

public ObjectIdCollection GetUnreconciledLayers();

 Then at bottom in Links section it has 2013 signature as if whoever updated the docs change what the method signature should be and pasted what it really is at bottom.

 

What is the reason for something like this not being addressed?

 

From what I understand the when something like this is reported to the ADN team they verify the bug exists and notify the engineering team.

 

This might be a method that no one ever used and only has been reported a few times, but can you see how it gives the impression your not concerned releasing things like this publicly?

  

 Speaking of layers and from the name of the properties it is obvious what the returned boolen represents, but mainly out of curiousity to see if it would get fixed I have reported for the last 2 years that the description for IsHidden & IsLocked is the description for IsFrozen.

The description for all three is "Assesses if the layer is frozen".

 

All it would it take is to change frozen to locked for IsLocked,

and frozen to hidden for IsHidden.

 

I know its minor but it just gives me the feeling you do not care about the quality.

 

 With other APIs I have dealt with when a issue arises it just seems your made to feel they are concerned with the quality and are working on fixing the issue.

 

You can always go to Autodesk's carrer page to see what they are hiring for and get idea where they are putting the money, and have not looked at it lately but last time I looked it seemed it was for the entertainment side and software that its description seemed to describe 3dMax, Revit, etc....

 

I just get frustrated sometimes and wish Autodesk would realize if they invested more resources and produced better quality API and documentation that it would attract more developers and allow 3rd party developers to more easily create useful plugins, and would benefit from the 3rd party developers doing the work for them.

 

 Again not blaming or trying to jump on any person but more on Autodesk decisions on resources allocated and procedures for fixing issues with API, or those kids put me in a bad mood.

 

 

 

 

 

 

 

You can also find your answers @ TheSwamp
ADN Support Specialist
Balaji_Ram
Posts: 609
Registered: ‎03-21-2011
Message 9 of 10 (152 Views)

Re: LayerTable.GetUnreconciledLayers()

06-06-2013 10:16 PM in reply to: jeff

Sorry, it was my mistake. 

 

I had a relook at the engineering request that was created for this.

 

This has been fixed in the 2014 release and the documentation reflects that. 

 

@Jeff : My Best wishes on your son's birthday.

 

 



Balaji
Developer Technical Services
Autodesk Developer Network

Distinguished Mentor
BlackBox_
Posts: 701
Registered: ‎02-25-2013
Message 10 of 10 (139 Views)

Re: LayerTable.GetUnreconciledLayers()

06-07-2013 12:26 AM in reply to: Balaji_Ram

Balaji_Ram wrote:

Sorry, it was my mistake. 

 

I had a relook at the engineering request that was created for this.

 

This has been fixed in the 2014 release and the documentation reflects that. 


So... That's great for others using 2014; what about those of us still coding for legacy versions (I state I'm using 2012 in the OP)?

 

Have you any intention of fixing those versions, or am I (and every other developer) entirely dependent on DiningPhilosopher's continued kindess to fix API gaps (where possible) when Autodesk chooses not to?

 

Despite the fact that DiningPhilosopher more often than not delivers working solutions before I even come to need them, this isn't his job, frankly; it's yours (Autodesk's).

 

I was fortunate enough to be awarded an ADN membership for free, but had I actually come out of pocket the $1400+, I'd be quite a deal more unhappy, being diplomatic.

 

I'm relatively new to .NET development as compared to the talent participating in this thread, so forgive my being so forward, but methinks the fact that one so new seemingly stumbles into multiple API gaps so soon after beginning to develop via .NET API speaks to the lack of completeness on Autodesk's part, more so than to the advanced nature of this beginner's coding prowess. Just saying.

 

"Integrity is doign the right thing, even when no one is watching" - C.S. Lewis

 


Balaji_Ram wrote:

 

@Jeff : My Best wishes on your son's birthday. 


1+... Cheers 'lil Jeff!

 

 



"Potential has a shelf life." - Margaret Atwood


Autodesk Exchange Apps ~ Autoloader ~ AutoCAD Security

You are not logged in.

Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register

Announcements
Welcome to the new Autodesk Community!
If this is your first visit, click here to get started and make the most of the Community. Let us know what you think of the new experience in the Community Feedback Forum.

Need installation help?

Start with some of our most frequented solutions to get help installing your software.

Ask the Community