Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Riena » where to do the remote service call
where to do the remote service call [message #26143] Sun, 17 May 2009 19:14 Go to next message
Eclipse UserFriend
Originally posted by: kessels.sjoerd.gmail.com

Hi,

I have a view and corresponding controller that displays a list of projects.
In the controller's configureRidgets() method I placed the call to the
remote service that returns the list of projects. This works.
However the second time I open the view via the navigation menu the
configureRidgets() method is not called anymore, which makes sense. So my
view is not repopulated.

What would be the best place to place my remote service call so I am able to
call it every time the view (navigationnode) gets activated while still
being able to ge to the controller to update the model that is bound to the
table?

Is there something like a listener of navigationnodes? And where would I
place the listener?

Thanks,

Sjoerd
Re: where to do the remote service call [message #26226 is a reply to message #26143] Mon, 18 May 2009 12:33 Go to previous messageGo to next message
Thorsten Schenkel is currently offline Thorsten SchenkelFriend
Messages: 15
Registered: July 2009
Junior Member
Hi Sjoerd,

you can add to every node of the navigation a listener
(NavigationNodeListener).
So you will be informed after every change of status of the navigation node.

example:


@Override
public void setNavigationNode(ISubModuleNode navigationNode) {

super.setNavigationNode(navigationNode);

getNavigationNode().addListener(new SubModuleNodeListener() {
@Override
public void afterDeactivated(ISubModuleNode source) {
super.afterDeactivated(source);
getStatusLine().clear();
}
});
}

greetings

Thorsten


Sjoerd Kessels schrieb:
> Hi,
>
> I have a view and corresponding controller that displays a list of
> projects. In the controller's configureRidgets() method I placed the
> call to the remote service that returns the list of projects. This works.
> However the second time I open the view via the navigation menu the
> configureRidgets() method is not called anymore, which makes sense. So
> my view is not repopulated.
>
> What would be the best place to place my remote service call so I am
> able to call it every time the view (navigationnode) gets activated
> while still being able to ge to the controller to update the model that
> is bound to the table?
>
> Is there something like a listener of navigationnodes? And where would I
> place the listener?
>
> Thanks,
>
> Sjoerd
Re: where to do the remote service call [message #26304 is a reply to message #26226] Mon, 18 May 2009 13:37 Go to previous messageGo to next message
Christian Campo is currently offline Christian CampoFriend
Messages: 597
Registered: July 2009
Senior Member
Hi Sjoerd,

you can use the NavigationNodeListener for a number of different event you get for the nodes. For the problem that you
describe you might as well overwrite the method afterBind in the SubModuleController (make sure you call
super.afterBind()) and that method "afterBind" gets called each and every time that SubModule is activated.

cheers
christian


Thorsten Schenkel schrieb:
> Hi Sjoerd,
>
> you can add to every node of the navigation a listener
> (NavigationNodeListener).
> So you will be informed after every change of status of the navigation
> node.
>
> example:
>
>
> @Override
> public void setNavigationNode(ISubModuleNode navigationNode) {
>
> super.setNavigationNode(navigationNode);
>
> getNavigationNode().addListener(new SubModuleNodeListener() {
> @Override
> public void afterDeactivated(ISubModuleNode source) {
> super.afterDeactivated(source);
> getStatusLine().clear();
> }
> });
> }
>
> greetings
>
> Thorsten
>
>
> Sjoerd Kessels schrieb:
>> Hi,
>>
>> I have a view and corresponding controller that displays a list of
>> projects. In the controller's configureRidgets() method I placed the
>> call to the remote service that returns the list of projects. This works.
>> However the second time I open the view via the navigation menu the
>> configureRidgets() method is not called anymore, which makes sense. So
>> my view is not repopulated.
>>
>> What would be the best place to place my remote service call so I am
>> able to call it every time the view (navigationnode) gets activated
>> while still being able to ge to the controller to update the model
>> that is bound to the table?
>>
>> Is there something like a listener of navigationnodes? And where would
>> I place the listener?
>>
>> Thanks,
>>
>> Sjoerd
Re: where to do the remote service call [message #26342 is a reply to message #26304] Mon, 18 May 2009 18:27 Go to previous message
Eclipse UserFriend
Originally posted by: kessels.sjoerd.gmail.com

Thanks! Both work fine.

Thanks,

Sjoerd

"Christian Campo" <christian.campo@compeople.de> wrote in message
news:4A1164AC.9000503@compeople.de...
> Hi Sjoerd,
>
> you can use the NavigationNodeListener for a number of different event you
> get for the nodes. For the problem that you describe you might as well
> overwrite the method afterBind in the SubModuleController (make sure you
> call super.afterBind()) and that method "afterBind" gets called each and
> every time that SubModule is activated.
>
> cheers
> christian
>
>
> Thorsten Schenkel schrieb:
>> Hi Sjoerd,
>>
>> you can add to every node of the navigation a listener
>> (NavigationNodeListener).
>> So you will be informed after every change of status of the navigation
>> node.
>>
>> example:
>>
>>
>> @Override
>> public void setNavigationNode(ISubModuleNode navigationNode) {
>>
>> super.setNavigationNode(navigationNode);
>>
>> getNavigationNode().addListener(new SubModuleNodeListener() {
>> @Override
>> public void afterDeactivated(ISubModuleNode source) {
>> super.afterDeactivated(source);
>> getStatusLine().clear();
>> }
>> });
>> }
>>
>> greetings
>>
>> Thorsten
>>
>>
>> Sjoerd Kessels schrieb:
>>> Hi,
>>>
>>> I have a view and corresponding controller that displays a list of
>>> projects. In the controller's configureRidgets() method I placed the
>>> call to the remote service that returns the list of projects. This
>>> works.
>>> However the second time I open the view via the navigation menu the
>>> configureRidgets() method is not called anymore, which makes sense. So
>>> my view is not repopulated.
>>>
>>> What would be the best place to place my remote service call so I am
>>> able to call it every time the view (navigationnode) gets activated
>>> while still being able to ge to the controller to update the model that
>>> is bound to the table?
>>>
>>> Is there something like a listener of navigationnodes? And where would I
>>> place the listener?
>>>
>>> Thanks,
>>>
>>> Sjoerd
Re: where to do the remote service call [message #582572 is a reply to message #26143] Mon, 18 May 2009 12:33 Go to previous message
Thorsten Schenkel is currently offline Thorsten SchenkelFriend
Messages: 15
Registered: July 2009
Junior Member
Hi Sjoerd,

you can add to every node of the navigation a listener
(NavigationNodeListener).
So you will be informed after every change of status of the navigation node.

example:


@Override
public void setNavigationNode(ISubModuleNode navigationNode) {

super.setNavigationNode(navigationNode);

getNavigationNode().addListener(new SubModuleNodeListener() {
@Override
public void afterDeactivated(ISubModuleNode source) {
super.afterDeactivated(source);
getStatusLine().clear();
}
});
}

greetings

Thorsten


Sjoerd Kessels schrieb:
> Hi,
>
> I have a view and corresponding controller that displays a list of
> projects. In the controller's configureRidgets() method I placed the
> call to the remote service that returns the list of projects. This works.
> However the second time I open the view via the navigation menu the
> configureRidgets() method is not called anymore, which makes sense. So
> my view is not repopulated.
>
> What would be the best place to place my remote service call so I am
> able to call it every time the view (navigationnode) gets activated
> while still being able to ge to the controller to update the model that
> is bound to the table?
>
> Is there something like a listener of navigationnodes? And where would I
> place the listener?
>
> Thanks,
>
> Sjoerd
Re: where to do the remote service call [message #582593 is a reply to message #26226] Mon, 18 May 2009 13:37 Go to previous message
Christian Campo is currently offline Christian CampoFriend
Messages: 597
Registered: July 2009
Senior Member
Hi Sjoerd,

you can use the NavigationNodeListener for a number of different event you get for the nodes. For the problem that you
describe you might as well overwrite the method afterBind in the SubModuleController (make sure you call
super.afterBind()) and that method "afterBind" gets called each and every time that SubModule is activated.

cheers
christian


Thorsten Schenkel schrieb:
> Hi Sjoerd,
>
> you can add to every node of the navigation a listener
> (NavigationNodeListener).
> So you will be informed after every change of status of the navigation
> node.
>
> example:
>
>
> @Override
> public void setNavigationNode(ISubModuleNode navigationNode) {
>
> super.setNavigationNode(navigationNode);
>
> getNavigationNode().addListener(new SubModuleNodeListener() {
> @Override
> public void afterDeactivated(ISubModuleNode source) {
> super.afterDeactivated(source);
> getStatusLine().clear();
> }
> });
> }
>
> greetings
>
> Thorsten
>
>
> Sjoerd Kessels schrieb:
>> Hi,
>>
>> I have a view and corresponding controller that displays a list of
>> projects. In the controller's configureRidgets() method I placed the
>> call to the remote service that returns the list of projects. This works.
>> However the second time I open the view via the navigation menu the
>> configureRidgets() method is not called anymore, which makes sense. So
>> my view is not repopulated.
>>
>> What would be the best place to place my remote service call so I am
>> able to call it every time the view (navigationnode) gets activated
>> while still being able to ge to the controller to update the model
>> that is bound to the table?
>>
>> Is there something like a listener of navigationnodes? And where would
>> I place the listener?
>>
>> Thanks,
>>
>> Sjoerd
Re: where to do the remote service call [message #582612 is a reply to message #26304] Mon, 18 May 2009 18:27 Go to previous message
Sjoerd Kessels is currently offline Sjoerd KesselsFriend
Messages: 15
Registered: July 2009
Junior Member
Thanks! Both work fine.

Thanks,

Sjoerd

"Christian Campo" <christian.campo@compeople.de> wrote in message
news:4A1164AC.9000503@compeople.de...
> Hi Sjoerd,
>
> you can use the NavigationNodeListener for a number of different event you
> get for the nodes. For the problem that you describe you might as well
> overwrite the method afterBind in the SubModuleController (make sure you
> call super.afterBind()) and that method "afterBind" gets called each and
> every time that SubModule is activated.
>
> cheers
> christian
>
>
> Thorsten Schenkel schrieb:
>> Hi Sjoerd,
>>
>> you can add to every node of the navigation a listener
>> (NavigationNodeListener).
>> So you will be informed after every change of status of the navigation
>> node.
>>
>> example:
>>
>>
>> @Override
>> public void setNavigationNode(ISubModuleNode navigationNode) {
>>
>> super.setNavigationNode(navigationNode);
>>
>> getNavigationNode().addListener(new SubModuleNodeListener() {
>> @Override
>> public void afterDeactivated(ISubModuleNode source) {
>> super.afterDeactivated(source);
>> getStatusLine().clear();
>> }
>> });
>> }
>>
>> greetings
>>
>> Thorsten
>>
>>
>> Sjoerd Kessels schrieb:
>>> Hi,
>>>
>>> I have a view and corresponding controller that displays a list of
>>> projects. In the controller's configureRidgets() method I placed the
>>> call to the remote service that returns the list of projects. This
>>> works.
>>> However the second time I open the view via the navigation menu the
>>> configureRidgets() method is not called anymore, which makes sense. So
>>> my view is not repopulated.
>>>
>>> What would be the best place to place my remote service call so I am
>>> able to call it every time the view (navigationnode) gets activated
>>> while still being able to ge to the controller to update the model that
>>> is bound to the table?
>>>
>>> Is there something like a listener of navigationnodes? And where would I
>>> place the listener?
>>>
>>> Thanks,
>>>
>>> Sjoerd
Previous Topic:where to do the remote service call
Next Topic:Wrong service implementation used since 1.1.0M7
Goto Forum:
  


Current Time: Thu Oct 28 15:02:28 GMT 2021

Powered by FUDForum. Page generated in 0.02286 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top