The definition of base class Context was not found

Kyle's Avatar

Kyle

20 Jan, 2011 04:17 AM

Hey guys,
Trying to get my first implementation of Robotlegs up and running, and so far I am really loving it, save the following issue: Each context file that I have tried to create throws the following error "Description Resource Path Location Type1017: The definition of base class Context was not found."

I have tried creating multiple projects, using different versions of the Robotlegs library (version 1.3 and 1.4 both .swc and source implementation), but no matter what I do I can't seem to shake this error. I know that the library is being found as I am getting code completion for the Context class, and can also click-through the Context class to bring up the class.

Any suggestions would be greatly appreciated!

  1. 1 Posted by Stray on 20 Jan, 2011 09:38 AM

    Stray's Avatar

    Hi Kyle - that does sound weird!

    Any chance your resource path is pointed at the folder above, which might still give you code completion but would think the package was - for example - robotlegs.org.robotlegs.mvcs.Context ?

    I guess if you've tried both swc and source that doesn't make sense anyway.

    I don't use FlashBuilder, but I'll also tweet a request incase anyone else has run into it.

    Stray

  2. 2 Posted by mike.cann on 20 Jan, 2011 09:44 AM

    mike.cann's Avatar

    Hi Kyle,

    Are you using the SignalsCommandMap or any other RL extension? I have had issues where I couldnt find some of the core RL classes when using the SWC version of the SignalsCommandMap.

    What you are experiencing where you can link through to the code is indeed weird however. Its almost as if Eclipse can locate the Context but the flex compiler cannot. There aren't any odd permissions things going on are there?

    Mike

  3. 3 Posted by simon on 20 Jan, 2011 10:06 AM

    simon's Avatar

    Hi Kyle,

    Mike raises a good point, I also am not a FB user, however a couple of thoughts spring to mind and it would be useful to see your project Flex Build Path properties, specifically Library Paths.

    Look in your . actionScriptProperties file and see what libraryPathEntry values you have and how they are being included in your compile. I jotted down some notes on this aspect here Linking Libraries in Flex using mxmlc

    Simon

  4. Support Staff 4 Posted by Ondina D.F. on 20 Jan, 2011 10:52 AM

    Ondina D.F.'s Avatar

    Hello
    I could reproduce the error 1017 only by removing the libs folder(containing the robotlegs.swc):
    FlashBuilder -> Properties -> Flex Build Path -> libs -> Remove
    Normally when you add a file to the libs folder Flah Builder will automatically build the path for it. For some reasons your Flash Builder doesn’t do that.

    So the solution is:
    FlashBuilder -> Properties -> Flex Build Path ->Add SWC Folder -> Browse to the folder containing your robotlegs.swc file and add the folder to your build path
    If you already have a libs folder try adding the swc (Add SWC)

    Hope that helps.
    Ondina

  5. Support Staff 5 Posted by Ondina D.F. on 20 Jan, 2011 10:52 AM

    Ondina D.F.'s Avatar

    Oh, I see, Simon already answered your question while I was editing my reply.

  6. 6 Posted by Kyle on 20 Jan, 2011 02:40 PM

    Kyle's Avatar

    Thank you all for your quick input! Unfortunately, I am still unable to
    resolve the issue. To answer a few questions:
    1) I am not using any plugins for RL
    2) I have mapped a directory called "libs" in my build path which contains
    the RL swc (however, I have also tried mapping directly to the swc file, as
    well as adding the source folder into my compile path. You can see current
    properties of the .actionscript file in the attached image.

    I have also attached an image of my Buil Path options from Flash Builder. On
    a side note, I was able to create a successful test project last night using
    the same RL swc file (after banging my head for a half-hour I finally found
    the article noting that you have to check the compile .swc option in Flash
    for it to properly compile, someone might want to think about surfacing this
    information higher up in the documentation, seems like a pretty big
    "gotcha"). This tells me that my .swc and inclusion methods should be ok (as
    I am doing the same thing in my broken project). The next step seems to be
    to recreate the entire project structure from scratch (which will be
    extremely time consuming), so if anyone has any other suggestions, they
    would be greatly appreciated!

    Thanks again for all the input!

    On Thu, Jan 20, 2011 at 2:52 AM, Ondina D.F. <
    [email blocked]<tender%[email blocked]>
    > wrote:

  7. 7 Posted by Kyle on 20 Jan, 2011 02:41 PM

    Kyle's Avatar

    And here's the screenshots I mentioned in my previous reply.

  8. 8 Posted by Stray on 20 Jan, 2011 02:42 PM

    Stray's Avatar

    Rather than re-create the entire project from scratch, could you create a new project and just attempt to include an instance of Context as a var while you narrow down the linking problem?

  9. 9 Posted by Kyle on 20 Jan, 2011 02:46 PM

    Kyle's Avatar

    Hey Stray,
    Do you mean the specific context file that is throwing the errors? i.e.
    Create a new project, then set the projects context file as the problematic
    file (copy it into the new project)? Perhaps you could provide a bit more
    detail on what exactly you're thinking here..

    I did create a test project last night with a new context file, a basic view
    and mediator, and a document class and application mediator, and was able to
    get it to run successfully. Not sure if this is what you are talking about.

    Thanks!

    On Thu, Jan 20, 2011 at 6:43 AM, Stray <
    [email blocked]<tender%[email blocked]>
    > wrote:

  10. Support Staff 10 Posted by Ondina D.F. on 20 Jan, 2011 03:20 PM

    Ondina D.F.'s Avatar

    Hey Kyle,
    Can you see the robotlegs swc under your Referenced Libraries (FB Package Explorer) and the Context.abc under org.robotlegs.mvcs there?

    What I do when something goes really wrong with a project’s settings in FB is:

    1. right click on the project in the Package Explorer, choose Delete
    2. radiobutton: DO NOT DELETE CONTENTS !!
    3. go to the folder of the project on your hard-disk
    4. delete :bin-debug, .settings, .actionScriptProperties, .flexProperties, .project
    5. and eventually the libs content
    6. don’t delete src !!
    7. go back to FB, create a new Flex Project with the same name (RLTest) and location
      The structure of your project will be intact, you’ll just have new settings.

    Does that help?
    Ondina

  11. 11 Posted by Kyle on 20 Jan, 2011 03:28 PM

    Kyle's Avatar

    Hey Ondina,
    Looking at the referenced libs, there are no classes displayed under the RL swc (i.e. no twirldown option). I have to run out the door, but I will try your above suggestion as soon as I get back and let you know how it goes. Thanks for the idea!

    • Flash_-_GoogleReaderWidget_com_chumby_widgets_googlereader_GoogleReaderWidgetContext.as_-_Flash_Builder_-__Users_ktyacke_Freelance_Chumby.jpg (Processing Asset) 100 KB
  12. 12 Posted by Kyle on 20 Jan, 2011 05:36 PM

    Kyle's Avatar

    Ondina,
    That seems to have done the trick! I recreated the project, then re-linked the libs directory (thus forcing a recompile/inclusion of the RL lib) and voila! When I dig into the referenced libraries now I can see the class inclusions for the RL Lib.

    Thank you guys all so much for your help!

    -Kyle

  13. Stray closed this discussion on 11 Feb, 2011 11:15 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac