Retrieve stock information to my flex application
Hey guys ive been thinking about building an application where i can query for a specific stock. I looked at yahoo finance and at google finance api. However they just dont seem to make any sense to me. So here is the question. Do you guys know of a service, webservice ,where i can basically send in a stock ticker and recieve a response back with information. Though i know this is not a flex related question im trying to build this app in flex 4 and i like to be able to take advantage of any free services out there that i can leverage.
Your response would be greatly appreciated.
Miguel
Yahoo runs a free web service to return stock quotes, indices, etc. The CPAN module is well documented, and it has been ported to all sorts of other languages, such as Ruby.
http://search.cpan.org/~edd/Finance-YahooQuote/YahooQuote.pm
Google Finance also has similar capabilities, but the interface is somewhat harder to use and I have no experience with that.
A few months ago, Yahoo pulled the Dow Jones Industrials index from their free web service, so it always returns "unchanged" now. I think you can still get that from Google Finance's service. Or scrape it from Yahoo's HTML.
Similar Messages
-
Hello. I just upgraded to Lion OS X 10.7.3. I was previously running 10.5.7 which included the ENTOURAGE application. how do I retrieve needed information from this application that no longer runs on this new system?
The file you'll be looking for that has most of what you're looking for - messages, address book, etc. is the Entourage Database. The verison of Microsoft Office I run (on Lion) is Office 2008. By default the Entourage Database for this verison is at user/Documents/Microsoft User Data/Office 2008 Identities/Main Identity/Database. That folder (Main Identitty) also has your rules, signatures, and such. You'll have to recover this file from whatever backup you have. If you have a different version of Entourage, the file location will be a little diffferent.
Good luck
srb -
I just opened my mail, and I don't find absolutely nothing, no message. The application is empty! how I can retrieve the information?!! do not know what happened
Click here and follow the instructions. You may need to completely remove and reinstall iTunes and all related components, or run the process multiple times; this won't normally affect its library, but that should be backed up anyway.
(99460) -
Prepopulating Flex application
Hi,
I am using flex applications for designing forms for Licecycle ES.
I have a problem about prepopulation of forms.
For XDP forms, I could prepopulate forms using render pdfform service.
But for rendering Flex forms, I could only see Read resource content service which only gets the application from defined resource.
And as I know, it has no capability of merging template and form data as I did for XDP forms.
For example my current problem is when process creator opens a form to initiate a process, I want to prepopulate the form with some userss
İnformation like name, departmet etc..
Is there any method to propose to solve this problem?
Note : As my flex form is opened in workspace (which is also a flex application ), and in workspace application I could see the username (commonname), may be it is possible to get this variable of parent applications from my flex form. If it is defined public..
Anyone knows how can I reach this variable?
Thanks in advance
Regards
CihanThere is a way to do that. This is an extract from an email one of my colleague on the subject:
In your Flex form you will make use of the FormConnector (see Flex Language Reference under lc.core.FormConnector which is used to simplify communication between Flex app and Workspace ES) that exposes three events (formInitiallData, formSaveDataRequest, formSubmitDataRequest). This will let you run a function when the Flex form initializes in Workspace - -the goal of that function will be to make a call to retrieve the data required and merge it into the Flex form.
In order to retrieve the data required for pre-population a common need would be to retrieve data related to the logged in user making the start form request. This information is not known to your Flex Form but is known to the Workspace ES Flex application that is hosting the form. So what you will need to do here is gain access into the Workspace application to retrieve the current session. From that current session you can extract the id (sessionManager.authenticatedUser.oid) of the current user. This will be an argument to your function calling some external source for data to be pre-populated.
You can now make a call to the data source to retrieve the data you want. For example, call a LC process that is exposed as a Web Service taking as its input a users id (the oid you retrieved from the session) whose steps will make the call to the directory server and get the info you need (e.g. department, manager, employee id, etc.) to prepopulate and return it back to the Flex form.
I do not have a working sample of this but below is a portion of sample code that would be in the Flex form and reflects what was discussed above.
<mx:Application
xmlns:mx="http://www.adobe.com/2006/mxml"
xmlns:lc="http://www.adobe.com/2006/livecycle" creationComplete="connector.setReady()" width="100%" height="100%">
<lc:FormConnector id="connector"
formInitialData="initialData(event)"
formSaveDataRequest="returnFormData(event)"
formSubmitDataRequest="returnFormDataForSubmit(event)"/>
<mx:Script>
<![CDATA[
import lc.domain.SessionMap;
import lc.core.ISessionManager;
private function getUserId():string
var session:SessionMap = SessionMap(Application.application.session);
var sessionManager:ISessionManager = ISessionManager (session.getObject("lc.core.ISessionManager"));
return sessionManager.authenticatedUser.oid;
Private function prepop(userId:String):XML
\\add code to call Web Service and retrieve info to prepopulate (in our example à name, dept, mgr)
private function initialData(event:DataEvent):void
if (event.data != null && event.data != "")
xmldata = new XML(event.data);
else
var myUID:String = getUserId();
xmldata = prepop(myUID);
]]>
</mx:Script>
<mx:VBox horizontalCenter="0" verticalCenter="0" width="100%" height="100%">
<mx:Form id="theForm" backgroundColor="0xffffff" width="100%" height="100%">
<mx:FormHeading label="My form"/>
<mx:FormItem label="Name" required="true">
<mx:TextInput id="userName" text="{xmldata.name}" change="xmldata.name = userName.text; connector.setDirty()"/>
</mx:FormItem>
<mx:FormItem label="Name" required="true">
<mx:TextInput id="userDepartment" text="{xmldata.dept}" change="xmldata.dept = userDepartment.text; connector.setDirty()"/>
</mx:FormItem>
<mx:FormItem label="Name" required="true">
<mx:TextInput id="userManager" text="{xmldata.mgr}" change="xmldata.mgr = userManager.text; connector.setDirty()"/>
</mx:FormItem>
</mx:Form>
</mx:VBox>
</mx:Application>
I hope that helps.
Jasmin -
RE: Polymorphism - retrieving type information from thedatabase or how
Don,
Ok but if I was to model a real restaurant, I would then have a head chef
that can then delegate to other chefs. This head chef would have the
additional task of coordinating the completion of subservient chefs. This
does not and would not mean that the head chef is stuck (or partitioned) in
one part of the kitchen. Further a head chef would most likely also be a
chef so that he would be running around the kitchen using and interacting
with different objects to get his part of the recipe completed. Then once
all chefs have completed their part of the recipe the head chef could return
the meal.
I would also point out that it does not make sense to me to be talking about
the chef and its ability to scale. I would look that the resource limited
devices that must be used to prepare meals to see scalability. In this case
the grill, the stove and the microwave. Scalability of the restaurant is a
function of the amount of resource limited devices versus the number of
process (i.e. chefs) that need to use those devices concurrently and the
amount of time they require access to those devices. By talking about chefs
as if they are the scalability limiting factor seems to bring us back to the
notion that the chef is a manager object that is shared. And again I come
back to the question, why?
You may now think that in a real restaurant, there are only so many chefs so
why not make it a shared service? Well in a real restaurant there are only
so many of any object, but this is not a consideration in our restaurant
model. In our "virtual" restaurant hiring a chef is as easy as:
Chef = new;
And of course chefs are of zero mass so there can be a whole lot in the
kitchen. Now assuming the Grill, Stove and Microwave map to physical
objects in our computing environment, then that is the limiting factor and
are therefore partitioned. Whenever communication has to go through a
single source, then scalability breaks down. I fear that too many people
make shared objects and create communication bottlenecks where they simply
don't exist. The only place your scalability bottlenecks should exist is in
the actual resource limited objects of your computing environment. Simply
said, if something isn't a resource limited object, then why is it shared?
If anyone is not clear how to architect an application independently of the
business model, then I would suggest looking at various framework products
and reading some technical architecture white papers to get a different, and
possibly enlightening, point of view.
Mark Perreira
Sage IT Partners.
-----Original Message-----
From: Don Nelson [mailto:[email protected]]
Sent: Wednesday, June 17, 1998 9:04 AM
To: Mark Perreira
Cc: [email protected]
Subject: RE: Polymorphism - retrieving type information from the
database
Mark,
First, I completely agree about the naming. I purposely used rather
euphamistic names for these "managers", since I see many convoluted names
for common things in various applications. But that is a topic for another
thread...
Simply because there is a "manager" of some type, does not imply that it is
chained to a particular duty. However, let's look at a real life case. In
a large restaurant, you would rarely see a chef chopping carrots or serving
dishes to customers. Those are the responsibilities of the sous-chef and
the waiter. So, we see that the chef does not really follow the food
around. Why not? Because it simply doesn't scale. When scalability isn't
a problem, (the restaurant isn't that popular, for example) the chef has
some lattitude to accept more responsibility, and might even get involved
with purchasing, etc.
In the real world, the more scalable something has to be, the narrower the
responsibilities are for each of the participating members.
Don
At 12:59 AM 6/17/98 -0700, Mark Perreira wrote:
Don,
One thing that always baffles me is when should an Object get the moniker
"Manager." This practice seems to tell me a couple of things about these
objects. In general when someone makes reference to a "Manager" objectthat
it is probably a service object and probably contains no or very little
attribution. The question is why? If I am developing an object model why
am I thinking about such implementation issues.
Surely if you are trying to model cooking an egg I would not see
"SustenancePreparationManager" in your model. Using a more common term I
would still be alarmed to see "CookManager" in your model. What does the
CookManager manage? Does it manage other cooks or eggs. Maybe it shouldbe
called an EggManager, but that doesn't make sense. How about just Cook.
There that seems like the real world. And this brings me to a problem in
the analogy. Conjuring up managers in a model can sometimes make you missa
container. For example, I would say that if we wanted to model the real
world, then eggs is a specialization of ingredient that is contained by
recipe that can be given to a cook to be prepared.
I may have many cooks (objects) that can prepare recipes and my application
architecture not the object model needs to deal with how to best let those
cooks utilize the grill, stove and microwave that sits on different
partitions on my server. My cooks can move around and when they do they
take their ability to know how to cook with them. In the real world Iwould
expect a cook to use the right appliance to prepare the recipe based on its
contents. I would not chain every cook to its appliance and them make me
responsible for giving the right cook the right recipe. This is what
managers can cause. They cause the consumer of cooks to know which cookcan
prepare what recipes based on where they are chained. This then makes me
know something about cooking. And if I don't know anything about cooking I
can only image what my egg would look like if I accidentally gave therecipe
to the cook stationed at the microwave.
Ok Ok, I have seen many architectures use facades to hide the fact that I
like to chain my cooks to their appliance. But what is that. I have gone
to restaurants and I don't know what a cook facade is. If I ask themanager
to present the cook facade manager employee I would probably be met by the
bouncer employee.
So what is the answer? Well for a start keep the application architecture
out of the model. The model should stand alone in describing the
interactions required to satisfy use cases. Second find an architecture
that describes a more responsibility driven design and how that design and
can map your business object behavior to a physical implementation with
appliances and cooking rules. And lastly, don't be so quick to chain your
cooks to their appliances. Give them some control over where they cook
their recipes, after all that is what they do.
Mark Perreira
Sage IT Partners.
-----Original Message-----
From: [email protected]
[<a href="mailto:[email protected]">mailto:[email protected]]On</a> Behalf Of Don Nelson
Sent: Tuesday, June 16, 1998 2:07 PM
To: Nick Willson
Cc: [email protected]
Subject: Re: Polymorphism - retrieving type information from the
database
This thread is switching context a bit, but I would add one thought tothe
idea of encapsulating behavior. One of the advantages to OO is that it
helps us model real world behavior. In the real world, I would not askan
invoice to stuff itself into an envelope and mail itself to its
customer; I
would not ask my vehicle to fuel itself or change its own oil; I wouldnot
tell an egg carton to ask one of its eggs to fry itself. Even if these
things were physically feasible, I could list a number of reasons why I
still wouldn't want to do them. That is why we haveVehicleRepairManagers
and SustenancePreparationManagers (aka, "Mechanics" and "Cooks").
Don
At 11:28 PM 6/15/98 -0700, Nick Willson wrote:
Tim,
You've had lots of good suggestions so I hope you won't mind an attempt
at another one. The consensus seems to be for your option (1) for the
Vehicle table, and Steve's example of a GenericConstraint (taking the
place of your Vehicle) is probably how most people would go about
answering your question. I don't have much to add to that, just wanted
to offer something about where the persistence mechanism lives and how
things look to clients that depend on it.
Suppose for a moment you think about the Vehicle classes' persistence as
being just one aspect of their behavior. In addition to persistence,
you might have to implement security, or locking for concurrent access,
or caching of vehicle objects to improve performance, and of course you
want to calculate the vehicle tax and probably do other things with
Vehicles too.
You can put the persistence aspect of Vehicles into a
PersistenceObjectManager, but then the others need somewhere too. If
you use a bunch of Managers (one for security, one for locking...) then
each class's behavior is scattered across these various Manager classes,
each of which has to know about many classes. Or if you use one Manager
class, it's going to know still more, plus you are forced to implement
all the behavior in (or at least via) that manager's partition.
An alternative would be to keep all the Vehicle classes' behavior
encapsulated together, so a client always makes requests to a Vehicle,
and the Vehicle delegates the implementation of requests to a chain of
handler objects that hang off the vehicle object (a handler for
security, another for persistence, and so on).
One of the nice things about this is, the handlers can be responsible
for going to another partition (if necessary), e.g. to perform
persistence operations, or for more business-specific operations like
tax calculations. And because the handlers are smart, you don't have to
put a lot of code into service objects, the SOs can stay pretty simple.
This isn't an approach you'll see in Express, so I hope of it's of some
interest.
General wrote:
Part 1.1 Type: Plain Text (text/plain)
Encoding: quoted-printable--
Nick Willson
SCAFFOLDS Consultant,
Sage IT Partners, Inc.
(415) 392 7243 x 373
[email protected]
The Leaders in Internet Enabled Enterprise Computing
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:<a href=
"http://pinehurst.sageit.com/listarchive/">http://pinehurst.sageit.com/listarchive/</a>>
>>>
>>>
>>
>>
============================================
Don Nelson
Regional Consulting Manager - Rocky Mountain Region
Forte Software, Inc.
Denver, CO
Phone: 303-265-7709
Corporate voice mail: 510-986-3810
aka: [email protected]
============================================
"When you deal with higher numbers, you need higher math." - Hobbes
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:<a href=
"http://pinehurst.sageit.com/listarchive/">http://pinehurst.sageit.com/listarchive/</a>>
>>
>
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:<a href=
"http://pinehurst.sageit.com/listarchive/">http://pinehurst.sageit.com/listarchive/</a>>
>
>
============================================
Don Nelson
Regional Consulting Manager - Rocky Mountain Region
Forte Software, Inc.
Denver, CO
Phone: 303-265-7709
Corporate voice mail: 510-986-3810
aka: [email protected]
============================================
"When you deal with higher numbers, you need higher math." - Hobbes
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:<a href=
"http://pinehurst.sageit.com/listarchive/">http://pinehurst.sageit.com/listarchive/</a>>Don,
You are absolutely correct. But this is where I honestly think you are
missing the point. While the mail program sends the mail, my mail message
has an interface (i.e. send button) which can delegate that to the mail
program. This makes it nice and simple for me the consumer of the mail
program. It also means I can think of mailing by focusing on the interface
(i.e. the button). It would suck if every time I wanted to mail something I
had to identify the correct pop server to send it to (i.e the MailManager).
Mailing something is the collaboration of the setup information of the mail
program and my mail message. If I were to model this my mail object would
indeed have a send method that could delegate to the correct mail servers.
This is just simplicity of interface and it is a good practice in UI
development just as it is in business model development. A simpler
interface, I think we can all agree, provides for a better and quicker
understanding.
Mark Perreira
Sage IT Partners.
-----Original Message-----
From: [email protected]
[<a href="mailto:[email protected]">mailto:[email protected]]On</a> Behalf Of Don Nelson
Sent: Thursday, June 18, 1998 9:22 AM
To: Nick Willson
Cc: [email protected]
Subject: Re: Polymorphism - retrieving type information from the
database
Nick,
It turns out that your message does not, indeed send itself. Your mailing
program does that.
Don
At 11:54 PM 6/17/98 -0700, Nick Willson wrote:
Hey Don,
In the real world, no, you can't tell an invoice to put itself into anenvelope
and mail itself. You have to know about stamps and post boxes and wherethey
are located. But isn't it nice that in software you don't have to followthe
real world very closely if you don't want to?
Above the top left hand corner of this message I'm typing right now, thereis a
send button which lets me tell the message to 'stuff itself into anenvelope
and mail itself'. Why wouldn't you want to do that?
Don Nelson wrote:
This thread is switching context a bit, but I would add one thought to
the
idea of encapsulating behavior. One of the advantages to OO is that it
helps us model real world behavior. In the real world, I would not askan
invoice to stuff itself into an envelope and mail itself to its customer;I
would not ask my vehicle to fuel itself or change its own oil; I wouldnot
tell an egg carton to ask one of its eggs to fry itself. Even if these
things were physically feasible, I could list a number of reasons why I
still wouldn't want to do them. That is why we haveVehicleRepairManagers
and SustenancePreparationManagers (aka, "Mechanics" and "Cooks").
Don
At 11:28 PM 6/15/98 -0700, Nick Willson wrote:
Tim,
You've had lots of good suggestions so I hope you won't mind an attempt
at another one. The consensus seems to be for your option (1) for the
Vehicle table, and Steve's example of a GenericConstraint (taking the
place of your Vehicle) is probably how most people would go about
answering your question. I don't have much to add to that, just wanted
to offer something about where the persistence mechanism lives and how
things look to clients that depend on it.
Suppose for a moment you think about the Vehicle classes' persistence as
being just one aspect of their behavior. In addition to persistence,
you might have to implement security, or locking for concurrent access,
or caching of vehicle objects to improve performance, and of course you
want to calculate the vehicle tax and probably do other things with
Vehicles too.
You can put the persistence aspect of Vehicles into a
PersistenceObjectManager, but then the others need somewhere too. If
you use a bunch of Managers (one for security, one for locking...) then
each class's behavior is scattered across these various Manager classes,
each of which has to know about many classes. Or if you use one Manager
class, it's going to know still more, plus you are forced to implement
all the behavior in (or at least via) that manager's partition.
An alternative would be to keep all the Vehicle classes' behavior
encapsulated together, so a client always makes requests to a Vehicle,
and the Vehicle delegates the implementation of requests to a chain of
handler objects that hang off the vehicle object (a handler for
security, another for persistence, and so on).
One of the nice things about this is, the handlers can be responsible
for going to another partition (if necessary), e.g. to perform
persistence operations, or for more business-specific operations like
tax calculations. And because the handlers are smart, you don't have to
put a lot of code into service objects, the SOs can stay pretty simple.
This isn't an approach you'll see in Express, so I hope of it's of some
interest.
General wrote:
Part 1.1 Type: Plain Text (text/plain)
Encoding: quoted-printable--
Nick Willson
SCAFFOLDS Consultant,
Sage IT Partners, Inc.
(415) 392 7243 x 373
[email protected]
The Leaders in Internet Enabled Enterprise Computing
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:<a href=
"http://pinehurst.sageit.com/listarchive/">http://pinehurst.sageit.com/listarchive/</a>>
>>>
>>>
>>
============================================
Don Nelson
Regional Consulting Manager - Rocky Mountain Region
Forte Software, Inc.
Denver, CO
Phone: 303-265-7709
Corporate voice mail: 510-986-3810
aka: [email protected]
============================================
"When you deal with higher numbers, you need higher math." - Hobbes--
Nick
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:<a href="http://pinehurst.sageit.com/listarchive/">http://pinehurst.sageit.com/listarchive/</a>>
>
>
============================================
Don Nelson
Regional Consulting Manager - Rocky Mountain Region
Forte Software, Inc.
Denver, CO
Phone: 303-265-7709
Corporate voice mail: 510-986-3810
aka: [email protected]
============================================
"When you deal with higher numbers, you need higher math." - Hobbes
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:<a href=
"http://pinehurst.sageit.com/listarchive/">http://pinehurst.sageit.com/listarchive/</a>>
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:<a href=
"http://pinehurst.sageit.com/listarchive/">http://pinehurst.sageit.com/listarchive/</a>> -
Embedding Fonts in a Flex application -- Legal issues?
I am currently building a Flex application for a Client. The Style guide they have provided shows Univers 55, Univers 65, and Univers 45 as the main fonts for the site and the app.
Page 1567 of Using Flex 4.5 states
Note:
Check your font licenses before embedding any font files in your applications. Fonts might have licensing restrictions that preclude them from being stored as vector information.
The fonts they are using in the AI file for the design document appear to be older version Adobe 1.0 TrueType fonts dated 30th June 1997.
I can not find the original license for these fonts, but such licenses may pre-date embedding technology, so are we allowed to embed them?
As an alternative could we safely use the OTF Univers LT Std family and are there any differences?
Message was edited by: lingoguruAs far as i see it, it's mainly just for convenience.
Embedding an image into application removes the need for you to store it elsewhere on the server, as it becomes part of the .swf file.
From personal experience it's very handy with small images, as it doesn't increase the size of the .swf file too much, and it means you don't have to keep track of them when distributing your release build.
you don't have to embed anything, you can simply reference it by location instead, but you'll experience a slight delay as it's loaded into the application on request.
The need for using this feature depends entirely on what you're trying to accomplish.
If you're making something like a large image gallery, it'll completely remove the need for wait for pictures to load when you're scrolling through them. However i wouldn't recommend it as you'll send your application size will go through the roof, and the waiting time for the whole application to load would be fairly extensive.
If you have an application with like 40 small ~3kb images using for navigation icons or something, you might as well, it's just convenient and won't impact the loading time by too much. -
In Flex application functionality is working sometimes and not working sometimes..
Hi,
Please help me on this..
In my flex application some functionality is working some times and not working sometimes..
In my project i have 5 sections with 5 separate screens..Each screen is of one diffeent module.
After logining into the application:
I will go to one screen..First time every functionality is working in that screen..
Ex:: I have a screen with datagrid.From that user will select one job name from datagrid click on next button..
Based the job name the user selected i have to display some information in next screen and customer names.customer names is a combo box..
below is the code:::
public function populateAllOEMCustomers(event:ResultEvent):void
1) var object_CustomerList:CustomerList = event.result as CustomerList; //Assigining result object values to Object reference variable.
2) var allOEMCustomersCollection:ArrayCollection = new ArrayCollection(); //Declaration ArrayColliction referance variable.
3) var i:int=0;
4) var customerComboLabel:Label = new Label();
5) for (i = 0;i < object_CustomerList.arryCollCustName.length; i++)
var strCustName:String = object_CustomerList.arryCollCustName.getItemAt(i).toString();
var strCustId:String = object_CustomerList.arryCollCustId.getItemAt(i).toString();
customerComboLabel = new Label(); //Dynamic declaration of label.
customerComboLabel.name = strCustName; //Assinging the customer name to the Label name field.
customerComboLabel.text = strCustId; //Assingning the customer id to the Label text field.
allOEMCustomersCollection.addItem(customerComboLabel); //Adding Lable into the ArrayCollection referace variable.
//customerComboID.selectedItem = "--";
OEMCustomersComboID.dataProvider = allOEMCustomersCollection;
OEMCustomersComboID.selectedItem = -1;
This functionality is working fine when i visit to this screen first time..If you go back to another screen and come back to this same screen and click on next button this time customer names combo box has no customer details..I am getting Nullpointer Exception and it is showing the line number 5( i have given the number for code given above..)
If i change the first line of the code to below code:: every time the above functionality is working fine.Not getting any error msg..
var object_CustomerList:Object= event.result ;
If i type cast it to specific class(CustomerList) ,functionality is not working ..getting null pointer exception..If i type cast it to Object everything is working fine..In my code wherever i have typecasted it to specific class functionality is not working(gettingNullpointerExcepion).
Please help me on this..I am not getting what could be the reason..
I am using::Flex 3,Flash player 10.1
Thanks in advance..
Regards,
SatyaHi Satya,
This sometimes as in your case might not work as the way you have specified the RemoteClass attribute in your AS class. As somtimes there may be a case as before it is mapped to a server side you are returned the data and so that you may not get the data as your Custom class but as normal Object type.
So in order to avoid this you can map the server side class to AS classes in the PreInitialize handler itself as shown below:
Specify the preinitializeHandler in your main application and write the below function.This way also you can map AS classes with the server side. So that you will not have any problem referring your application as AS class types.
You can use the same line for registering all the classes. By using this you can remove all the [RemoteClass] attributes on all AS classes and include it at single place.
preinitialize="onPreinitialize()"
private function onPreinitialize():void
registerClassAlias("com.expeditor.ScriptAdmin.Objects.CustomerList", CustomerList);
Here in the above line of code the string in quotes refer to the namespace of the Server side class and the latter is your AS class. Also dont forget to import the namespace of the corresponding AS class in the file.
Try this and let me know..
Thanks,
Bhasker -
Restarting A Flex Application Programmatically
Howdy folks,
I have just created a database driven user management system
which works wonders, but I'm having a problem with logging out a
user. By far the easiest, sure fire way of doing this would be to
clear the users login in the database (not really relevant to the
problem) then restart the application programmatically (as if the
user pressed the refresh button in thier browser) which would bring
them back to the login screen at the start of the application. Is
re-initialising the application possible to do in actionscript?
If not it would involve clearing user specific variables,
resending http requests which relate to the login, removing
permissions based controls and all this over many modules... just a
hell of a lot of what may be unesscessary work, especially if all
that really needs to happen is the application to re-initialise.
Any help on this would be amazing!
Many thanksquote:
Originally posted by:
mattyb1515
My initial suggestion is to wrap your flex application in a
PHP web page and let PHP do the authentication/deauthentication. To
logout the user you can create a PHP function that destroys the
session variable and then refresh/redirect to the login/home page
of your application.
Thanks for the reply but I'm afraid it isn't as easy as that.
I'm a php guru and I do use PHP and FlashVars for use with
authentication but only to 'remember' user information when the
user opens up a different application (basically if they log into
one application, theyre logged into the rest). Using 'out of
application' authentication is of no use when it comes to a
permissions based user system and applying dynamic permissions
(such as "this user can see this menu", "this user cant press this
button") to a flex application. It's clearing these permission
variables I'd prefer not to do if the application can be
programmatically re-initialised which would have the same
effect. -
Performance Of Flex Application?
Hello all
Recently I went through video tutorials of flex and found it to be great.But I have one question regarding performance. If I am not wrong then Flex application works like this, Entire application is converted into swf file and for navigation between pages of application there is concept of states.Whatever data is required for different states is get by using HTTPService,WebService etc . wheras if we talk about normal web application built using PHP every page and data is loaded from server .For each navigation, data plus markup(HTML/DHTML CSS javascript etc.) to show that data or content is loaded.It has a benefit of downloading only that part of application which is required.
For example if we have shoping store applicatiion and it has a search page and product list page to display products list in different formats like grid or table then markup plus data in normal web application will be loaded with each request.If user click on search page only then that page is loaded from server and if user want to view the search results in table format only then that page is loaded.
I want to know how this work in Flex application.For data part It is clear that for each state whatever data is required is get by using services like HTTPService,WebService etc. But how state presentation part is get?Is the entire swf file containing all states related information is loaded before running the applicatio? For example as in our previous example presentation part of all states like shopping store serch state, product list in table format state and product list in grid format state in the begining of application .later on if user click on search link it will already have that state view information and it will get data for search part and put that data into view and present it to the user.For search result also it will be already having information about how to present that data so it will get data only and present it to user.
If Flex works as i stated above then if we have very big application with many different stats then user has to wait for the loading time off all the states.Or there is provision for some backgroud loading of states that as soon as user request the application first time he gets the first view and then on other states are loaded in backgroud?
If all the states are loaded at begining of application then what will be performance of application with many states?(Means in that case swf file of compiled application will be of big size and it will take time to load in browser.)
can anybody tell me about all these things in detail.I am sorry if my understanding of Flex is wrong.I am newbie.
Thanks in advance .This seems more of an RIA performance question than a Flex specific one. Honestly though, modules aren't needed often in my experience (depends greatly on requirements).
You say that "only the part of the application that is needed" is downloaded, while this is technically true (a bit of an oversimplification as there are other advantages to be had from RIAs), you still have the round trip time required for every single request to the server. Since an RIA is generally a single bulk download (which may not even be needed if there's caching going on), usually you're talking about a single wait of a few seconds for loading vs multiple waits of a few seconds for page refreshes.
Even if the initial load time is as much as ~10 seconds (for the first visit), does that outweigh the 1 to 3+ second page refresh penalty constantly interrupting the user's work flow over time? Also consider Flex's AMF protocol, which blows competing formats (esp XML based) out of the water on performance. RIAs (especially Flex) win the performance game. -
Embedding Flex applications inside a portlet question
I'm trying to embed a Flex application within a Java portlet on my WLP 10.3.2 portal. I'm able to display the Flex app in the portlet but now I'm trying to access data. Does anyone know of any documents that cover how to access Flex data from a portlet and how to access portlet data from the embedded Flex application?
thanksWhen you mentioned you integrated Flex App inside a Portlet, are you using like iFrame tag or Browser Portlet where in iFrame tag you specify the Flex app url like that. If so, then you will not be able to share any data/information between this iFrame portlet and the actual other real portlets.
If these Flex app has something like JSR based Flex portlets, then you can integrate them in WLP more easily. Another option is to consume these Flex Portlets as remote portlets using WSRP on WLP Side and the producer will be Flex Portal App (with flex portlets).
See if this link helps: http://livedocs.adobe.com/livecycle/es/sdkHelp/programmer/lcds/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=wsrp_1.html
Ravi Jegga -
Regarding Flex application in Adobe Air
I> I developed a flex application using FLEX BUILDER3. My
main.mxml and background image file was under src directory in flex
project. There was a folder named history under which
index.template.html was present. I inserted the javascript code
inside this html file. I want to convert the same flex application
to a desktop application. So I created a new project as a desktop
app and copied the mxml file and background image file under the
src directoy of the project. I am not able to see a folder named
history. I dont know where and how to insert the javascript and
html code for creating desktop air application
> Also the backgroundimage file is not getting display in
the window. Not sure why is it so. I had inserted the JPEGThe ability to package Composite Applications in AIR is currently available
as a limited release, so if you are interested you will need to contact your
sales channel for more information.
The technology includes a library (mosaic-mxml.swc) that contains UI
Components that allow developers to control the loading and placement of
Tiles or entire AXML Applications within the AIR application. There are
samples and documentation available.
As for mobile, there is work underway to support Mobile AIR applications
scheduled for an upcoming release.
Matt -
Polymorphism - retrieving type information from thedatabase
Daniel,
Yes I have always thought, that modeling the real world can lead to objects
that are unnecessary or overly complex relationships that do exist in the
real world but may not have to in a computing environment. Many times,
business models could be greatly simplified if the modelers factored out
interfaces from objects so that these interfaces could be applied based on
need of behavior without having to always construct class hierarchies in a
particular behavioral structure. Or they could benefit greatly by applying
design patterns to enhance delegation. But the problem with both of these
pieces of advice is that they assume the modeler is well versed and
understands how to apply these concepts. Many application developments I
come across are being done by a group of people that have never used an OO
tool before. With an audience such as this, how are they supposed to get
started?
Usually they will look and analyze the real-world. This will give them a
starting point in which to conduct dialog for building an object model. I
think I do know how these advanced strategies I described above are applied,
yet I always ask a customer to explain the real-world example of something
before I attempt at understanding their model and make any attempts at
advising changes. This assures that I and they have a better physical
understanding of an interaction before we attempt to describe an abstract
model of the same interaction.
As far as sharing of business objects, it is quite routine for a company to
have one group of IT application developers create a subsystem with business
objects that must be SHARED by another group of IT application developers.
The different subsystems have points of interconnect. These points can be
at the architectural level or business object level. So I don't think this
situation is as rare as you state. Further, I can see that the marketplace
is pushing more for run-time object sharing and collaboration so that this
will be the norm and not the exception.
I agree on the importance of custom routing for performance. I think it is
complex enough that I would stop short of telling people to spend time
building such a scheme. I would hate to see an application miss delivery
because the developers got too entangled in technical problems like custom
routing. But I do happen to know of a Framework product that has this as
one of its features. :)
I agree 100% with you the complexity of Forte is the marrying of object and
distributed technologies. I don't agree that frameworks cannot provide the
answer. I look at a framework as more than just a technical solution. We
use our framework to help divide the responsibilities between Business
Analyst, GUI Architect, Back-end Architect, GUI Developers and Back-End
developers. At many customers, some people play all of these roles. At
some customers, a developer may play just the GUI Developer role until he
can come up to speed on how to build simple views that are used to build
more complex windows. In this way, a large problem can be broken down into
a set of much smaller problems to help the architects manage work load and
education of the team. Without a framework that supports this sort of
approach, the architects of the application would have to delay development
until boundaries could be put in place. This can be very time consuming and
cause application rewrites if the boundaries were guessed wrong. In the
Forte marketplace today, there are products to help people set up those
architectural boundaries. It simply is more cost effective to buy one of
these solutions then it is to have your team spend time on this and add risk
to your project. In other words, architecture for a Forte development can
be bought much more cheaply than it can be created.
Mark Perreira
Sage IT Partners.
-----Original Message-----
From: Daniel Nguyen [mailto:[email protected]]
Sent: Sunday, June 21, 1998 7:35 AM
To: Mark Perreira
Cc: [email protected]
Subject: Re: Polymorphism - retrieving type information from the
database
Mark,
The battle question was only a little provocation : it seems that Forte
people and yours don't have exactly the same point of view about the way
that distribution should be made.
The problem I see on modeling the real world is that the hypothesis
seems to
be wrong : the world will never be as static as the modeling in my point
of
view. The fact is that when you try to model real world you will add
many
concepts you don't really need for the application. Those concepts may
change
with time. In my own experience I have seen that if you don't have a
real
concrete objective, it is very easy to imagine many things which won't
be
usefull when the real aim will come. That's why I think that in a
pragmatic
point of view it is better (in a cost view that's right) to focus on a
good
modeling of the system you have to build. For instance, in an exotic
currencies options system, you can imagine modeling for the Front a
system
without the product concepts, but only rules, because it is the real
world.
But when you come to the Back Office, you realize that all is managed
through
product concept. Then you come back to the Front modeling and break a
lot
of work. In the real world, the product concept does not exist, that's
right.
But it is a way to manage operations.
We all speak about Business Objects (and rules) share and re-use. I
imagine
that it is only applicable on some specific domains where the concepts
are
already shared as Insurance, Banking or Risk management on shares. This
is
because we have common rules for all companies : some financial markets
are
organized with public rules and constraints for instance. So the
difference
between companies is only on the service and not really in the business
foundations. But, in most cases, the differences between competitors are
on their business, their know how.
I have some difficulties to imagine companies with specific know how
sharing
it with competitors! So I imagine that shared business objects will be
very poor.
The problem may be that Business components will be provided by editors
like
Microsoft or may be Forte (with Express evolutions may be). But, the
business of their clients is not in the job of those providers : they
may
have a wrong view of the business of their customers, because they don't
have their know how.
On routage capabilities of manager, I agree on the technical point of
view.
This should be inherited from a service definition from Forte or a
technical
component. But, I have seen (on financial markets) that you also need
business
routage for scalability and performance. This is unfortunatly not in
Forte and
may be not really in technical frameworks on the market. Just an example
You have a financial market which is managed on several physical sites
(let's
take 2 sites). When everything is ok, you have one instance of a service
on each
site, first one managing some kind of instances (futures for instance)
and the
second one managing other kinds of instances (options for instance). But
when the
first site falls, you need (at run-time and if possible without stopping
the market)
to reconfigure the second service to manage all the instances (futures
and options).
So this is linked to business really. That's right, I base the
reflection on a very
specific (and experienced) case where the cost of the IT system is very
low compared
to the money exchanged on the system : you can imagine very specific
solutions.
The main problem I see today is that people have real difficulties to
integrate
object and distribution concepts and that Forte is to hard for Cobol or
Visual
Basic developpers. So those kinds of product should be more encapsulated
and
packaged on a push button way. The solution of making frameworks may be
very
short term solution, because of the cost and limitations about coverage
of the
clients specific objectives. Those problems come from Client/server
architectures
and needs, in my opinion, and NOT specifically from Forte or other
competitors.
Daniel Nguyen
Freelance Forte Consultant
Mark Perreira wrote:
Daniel,
I hope not. For SCAFFOLDS works only because of Forte and when I make
someone a happy SCAFFOLDS customer then they are also a happy Forte
customer. So if we sell more SCAFFOLDS, Forte sells moreForte. If there
is a battle between us, I certainly don't understand why,because we are on
the same team with the same goal.
I have always found customer have a different role than you have pointed
out. While I agree with the objectives, I have found most clients do
actually try to model the real world. They do it because it is an easy
starting point. They also do it because most OO books on the subject of
modeling point people in that direction. So they do indeedplay the role of
God with the business object model. But I have found thesesame customers
unwilling to play the role of God with the architecture. Theyare either
new to Forte and distributed object systems or they feelcomfortable with
the architecture to be documented and supported beyond thetenure of a set
of consultants that could come in and build such a system. In this case
they buy a pre-defined and built architecture.
I also agree that a Forte Service Object in and of itself can be
problematic. But I depart where you say a manager can dothings like custom
routing. This is exactly why I think Forte can be too difficult for too
many people. Any custom routing scheme is not to be takenlightly in its
impact of the overall performance and makeup of a running system. The
manager pattern does not describe a run-time environment withthe checks and
balances needed to make sure a custom router can perform. I have talked
with you Daniel and have complete faith in your ability todevelop such a
system. I would be very concerned in having just anyone try toimplement
custom routing in manager objects without a run-time environment that
simplifies and protects the participants from the mountain of technical
problems that would follow.
Mark Perreira
Sage IT Partners.
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/> -
RE: Polymorphism - retrieving type information from thedatabase
I would disagree with your statement that either the object or data model
must be wrong. The problem is more fundamental-trying to store objects in a
relational database. The object and relational paradigms can be made to
work together, but usually only by compromising tenets of one or the other
(or both). Now granted, there are many ways of making them work
together-and some are definitely better than others.
CJ
Chris Johnson
612-594-2535 (direct)
612-510-4077 (pager)
-----Original Message-----
From: Rottier, Pascal [SMTP:[email protected]]
Sent: Monday, June 15, 1998 8:17 AM
To: Forte Users Mailing list
Subject: RE: Polymorphism - retrieving type information from
the database
> ----------
> From: Rottier, Pascal[SMTP:[email protected]]
> Sent: Monday, June 15, 1998 8:17:16 AM
> To: Forte Users Mailing list
> Subject: RE: Polymorphism - retrieving type information from
the database
> Auto forwarded by a Rule
>
This issue has already passed this mailing list a couple of
times in the past. To put it in more general terms, you have
different classes which you store in the same DB table.
This is always tricky. Nine out of ten times, this means
either your Object model or your DataBase model is wrong.
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>This issue has already passed this mailing list a couple of
times in the past. To put it in more general terms, you have
different classes which you store in the same DB table.
This is always tricky. Nine out of ten times, this means
either your Object model or your DataBase model is wrong.
If you can differentiate between different classes, this
means you're dealing with different entities, which should
be stored in different tables. What if one class has an
attribute the other one doesn't. This would mean you have
to add a column to the database which is filled it the row
represends one class and is NULL if the row represends
another class. This is not good database practice!
Differentiating between different classes by means of
a "type" attribute is the classic procedural approach.
The OO approach would be to create subclasses. How-
ever, a relational database doesn't support subclasses.
The best way, would be to have a different table for
each subclass. If this gives you problems with norma-
lizing your database, you can create a table with all
the attributes generic to vehicle, and a table for each
subclass with only the attributes relevant to this sub-
class and a foreign key relation to the main table. If all
of this is not feasable, you're left with the need to find
some mechanism to identify what kind of class a cer-
tain row represends and then instantiate this class. The
tree solutions you suggested all work. It doesn't really
matter which one you chose, they're all equally dirty.
Hope this helps,
Pascal.
-----Original Message-----
From: General [SMTP:[email protected]]
Sent: Monday 15 June 1998 12:20
To: [email protected]
Subject: Polymorphism - retrieving type information from the
database
Suppose I have a class structure containing one base class with
several specialisations. Say, "Vehicle", with specialisations of
"Car", "Van" and "Truck". All vehicles are persisted in the database,
in a rolled-up table, and I want a generic retrieval mechanism, which
fetches a vehicle based on the license plate number. (It will probably
be a service object, which I will call a Persistent Object Manager).
I wish to retrieve ALL vehicles, and calculate the road tax for each.
However, cars, vans and trucks are all subject to different tax rules,
and require a different method to calculate their road tax. To put it
another way, there is a polymorphic method 'CalculateRoadTax' on the
"Vehicle" class.
Q: As each vehicle is extracted from the database, how does the rest
of the Forte application know what type of vehicle it is?
I am sure that others must have solved this problem before, but it is
new to us. We have come up with the following solutions:
(1) Add a "sub-type" column to the "Vehicle" table. Use the type
information to instantiate a Forte object of the correct type
(2) Maintain a completely separate table linking the vehicle licence
plate to its sub-type.
(3) Deduce the type of the object from the pattern of null columns in
the row.
I think (1) is the best solution, but I'm interested to know what the
experts say!
Incidentally, if Express can help or hinder in this situation, I would
be interested in that as well.
regards,
Tim Kimber
EDS (UK)
To unsubscribe, email '[email protected]' with
'unsubscribe forte-users' as the body of the message.
Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/> -
How to open user file in Flex Application
Hi forum,
I develop flex2 application where user can browse and open
XML file: the file should be loaded to text area.
Could you, please, advice me how to browse and open user
file?
I found FileReference class but it looks that it can only
upload file to a server. I need to open the file in flex
application.
Thanks for your help.
Smoke007The issue isn't Flex, but the Flash Player. It is too much of
a security risk to allow SWFs running in the Flash Player to open
local files. Imagine going to a web site that has a SWF banner ad -
but that banner ad opens local files and sends them to a remote
system - all of your personal and financial information transfered
without your consent.
Flex apps running in the AIR player are different - the end
user must launch them explicitly, just like any other local
program. -
FlashIsland UI element missing to embed Flex application
Hi,
I am trying to add flex application into my webdynpro java . But FlashIsland UI element is not displaying in my NWDS.
I am using NWDS Version: 7.0.09
EP Version: 7.0 SP: 16
Is there any way to get the FlashIsland UI element in my view?
Regards
VineelaHi Vineela,
To implement Flash Island for Web Dynpro Java applications integrating Flash Islands, you require the following:
Adobe Flex Builder 2 or 3
Adobe Flash Player 9 Update 3
Flash Island Flex library WDIslandLibrary.swc. To enable the use of a Flash/Flex component in Web Dynpro, the component must exist in the form of a FlashIsland. This wrapping enables the communication between the Flex component and the Web Dynpro Framework.
Are you sure, you are having the required installations available with you. Please check the links below for more information on the same, in case you have missed:
[Adobe Flash Islands for Web Dynpro Java|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/301e6047-01c9-2b10-3998-a08970c23639]
[http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/203ece12-85bf-2b10-31a1-cc051670e9c7]
Please keep posted in case found useful. Thanks!
Regards,
Gaurav Bhardwaj
Maybe you are looking for
-
Logical standby database to physical standby database
I already start my logical standby database and I want to return it again to physical standby database. So what should I do?
-
Lion Preview and Textedit very slow when opening files from Leopard Server
My small office (about 10 users) recently upgraded our iMac's, Mac Mini's, and Macbook Pro's. We are experiencing a big problem with Preview opening super slow (1-2 minutes) when trying to open JPG's, PDF's, etc from our 10.5.8 Leopard Server. We h
-
I have spent so much time trying to restore my I phone 3 as aple sent the link and have logged on connected the phone to itunes but cant go any further as it keeps asking for password any ideas on this problem?
-
UWL - Error when lauching webdynpro for Approve time
Please suggest me how to solve this error. As part of Manager Self Services (MSS) - we are getting error , when we try to click on the UWL Task link for "Approval of Working Times", UWL tries to launch a Webdynpro page and it could not find that. As
-
How to use isLast() method of Resultset ??
When I use the isLast() method of Result, there is following error java.lang.AbstractMethodError What should I do ? and how to use isLast() method ? Thanks a lot :-)