Hi Takeshita,

I had to push a fix to Crux to make Crux work with MXRoyale and/or Spark
Applications (there is not a common base class with the Basic/Jewel/Express
applications). So you will need the latest royale build with that change.

I also had to make some changes to the code you supplied to get something
that will compile. See the dropbox download.... it should show some
examples for how to get things working with Crux.
FYI there is also a Mock service helper in the Crux library which I did not
try to use yet, but might be helpful to try if you want to do some local
testing before you you try with real remote object. If you do try that
please let me know if you see any problems with it and I will work to solve
them.

At the moment the Crux setup is only for the application startup
(configuration) and the 'Login' flow to the signIn call, so it triggers the
command etc. So there are only basic examples of Injection and
configuration etc. I left some 'singleton' like access on some of the
configuration classes, so it is possible to use a mix of the singleton
pattern access that Cairngorm has or via injection. For Crux you would
usually use injection though.

https://www.dropbox.com/s/qsokfmxt0ed59sk/CairngormPortExample.zip?dl=0

I have no IDE configuration in that file set. I used maven locally to build
that, as a local variation inside the royale crux examples. So I did add a
file that shows the injection metadata and other compiler options I was
using. Hopefully you can use those compiler options along with a normal
setup for all the royale dependencies.

I left copies of the built javascript versions inside, so you can take a
look. I did not try to make the UI look good, and it has some bugs under
different conditions (make sure you choose the 2nd 'fake role' from the
dropdown, which does not appear correctly).

I hope there are useful clues in that - ask questions if you need
clarification. I will try to make another example (maybe the github viewer
again) in royale examples using MXRoyale instead of Jewel/Basic in the
coming days.
regards,
Greg


On Wed, Oct 30, 2019 at 8:58 AM Greg Dove <greg.d...@gmail.com> wrote:

> Hi Takeshita,
>
> My work day has just started. Sure, I will take a look at that later today
> and let you know.
>
> On Wed, 30 Oct 2019, 00:58 Takeshita Shoichiro, <jl03...@gmail.com> wrote:
>
>>
>>  Royale.zip
>> <https://drive.google.com/file/d/18vkAxOkgnZTtXFWD_HAna0z1yXzZFCi-/view?usp=drive_web>
>> Greg, I'm providing a simplified Flex application example that uses
>> Cairngorm framework.
>> I'd like to know changes required to migrate to Crux and any possible
>> problems for migration.
>>
>> I take our Login function for this case study. Royale.zip contains the
>> following:
>> (I hope you have time to look at these files and give me advices on
>> migration)
>>
>>
>> - Login.mxml
>>         Here, put focus only on LoginLoadEvent and LoginSignInEvent.
>>
>> - LoginLoadEvent.as
>>         LoginLoadEvent dispatcher
>>
>> - LoginSignInEvent.as
>>         LoginSignInEvent dispatcher
>>
>> - LoginController.as
>>         Associate events and commands.
>>         Here, put focus only on LoginSignInCommand.
>>
>> - LoginServiceDelegate.as
>>         Find remote service from service locator (Services.mxml) and call
>> it.
>>
>> - Services.mxml
>>         Service locator
>>
>> - LoginModelLocator.as
>>         Update Login.mxml with returned value object.
>>
>> - UserLoginVO.as: Sent to server
>>
>> - UserMainVO.as: Returned from server
>>
>>
>>
>>
>> --
>> Shoichiro Takeshita
>> 武下 祥一郎
>>
>

Reply via email to