J2ME framework and design patterns

Hi everyone.
I'm thinking of building a few J2ME applications, and was wondering if there are any frameworks for this (i.e. for building midlets)? For web applications you have frameworks like Struts (Jakarta/apache), but I've not found anything for J2ME.
Also, any known and proven J2ME design patterns would be of great help!
Thanks for all your help!
Best regards,
Arnt

Hi
AFAIK there r no frameworks, you dont need them - everything you code should be as simple and straightforward as possible.
Hmmm... proven design patterns, well, as I've found standard Java DP can't be used in J2ME, cause you need to do everything with small amount of memory and processing power. Object programming is cool, but it makes big impact on speed of code and on size of generated classes.
And believie me, sometimes those 2-3 kb make difference (eg. on Nokia 6310i, where you have 30 KB of memory, on 3510i it's about 60KB...)
So, one patter of which I can think about is - make your code simple :)
regards
Leszek

Similar Messages

  • MIDlet framework's design pattern

    What design pattern does the MIDlet framework work on?

    That's just as silly as asking:
    "What design pattern doesn J2me work on?"
    A framework doesn't work on a particular design pattern. The software you write does, and surly the api of the framework will make use of several pattern.
    Why not take a look at the api yourself and find out?

  • Best architecture and design pattern to use

    I am currently designing a moderately sized LabView application and cannot decide on the best architecture/design pattern or combinations thereof to implement.
    The program basically polls an instrument connected to a serial port continuously at a 2-10Hz rate. When operator clicks a button to start a run, the polled data is then filtered, has math functions performed on the data, writes collected data to files, and produces reltime graphs and calculates point-by-point statistics. At the completion of a run, some additional data files are written. I pretty much know how to accomplish all these tasks.
    What is also required is main-vi front panel interaction by the operator to access a database (via a C# dll with .Net) to query for specifications to apply in order to determine pass/fail status. Setup conditions also need to be changed from time to time by the operator and applied to the data in real time (ie- a measurement offset). I have prototyped the database portion successfully thus far.
    For the main vi, I started off using the Top Level Application Using Events design pattern (Event structure within a while loop). Copious use of bundled clusters and shift registers keep the database data updated. I cannot figure out how to have the top level vi concurrently poll the serial device as outlined above. The Event structure is only active when defined control values change, and use of a timeout is no help since it prevent data from being collected while the user is accessing the database. All database and setup parameters must be applied to the data as it comes in from the serial port. Error trapping/recovery is a must.
    I believe what I need is two parallel processes running under my main vi (one for database and setup, the other for polling and data processing/display, but what would be the preferred choice here?
    Revert back to a polled loop in lieu of Events, use notifiers, occurrences, user-defined events, Producer-consumer loops?
    It�s been about 3 years since I have had an application on this level (which used a state machine architecture), and a lot has changed in LabView (using 7.1 Prof Devel). I am currently having a mental block while trying to digest a lot of features I have never used before.
    Suggestions Welcome!
    Thanks.
    ~~~~~~~~~~~~~~~~~~~~~~~~~~
    "It’s the questions that drive us.”
    ~~~~~~~~~~~~~~~~~~~~~~~~~~

    I suggest a (3) state machine(s) architecture. The first is the user interface. Your main VI is a good start. Another state machine handles the instrument I/O (your serial polling). The third handles all data processing. The three loops run independently. Each has a wait to allow LV's scheduler to share CPU time among the loops. I like queues or functional globals for inter-loop communications.
    This allows a lot of flexibility. Each portion can be tested alone. Each can have different timing and priority.
    Spend some time thinking about what needs to be done and plan the structure carefully before you do any coding (except for little test programs to try new ideas).
    I also like Conway and Watts "A Software Engineering Approach to LabVIEW", published
    by Prentice Hall.
    Lynn

  • EJB and Design Patterns

    Hi all,
    Which design patterns could be applied in coding EJB? I don't know if my question is clear enough, but what I really want to know is which design patterns I could use with EJB and how could I use them this way? (Some example situation)
    Regards,
    Filipe Fedalto

    i think it depends of what u intend to do..
    e.g. i think (maybe i'm wrong, any relevant replies are welcome!) that u could use a stateless session bean to implement some facade, delegating entities creation to some non-bean classes? or why not a stateful session bean to implement a factory (when entities creation depend on client preferences)?

  • Get instance method and design pattern

    Hi All,
    1. I New to abap objects and i read the help and some stuff from the forum,
    l like to now more about design pattern in abap objects,
    2. I saw in some abap class the use of method of GET_INSTANCE i think it's from factory pattern , what is the pros. and cons to use this method ,when i should consider to use it ?
    Thanks in Advance
    Nina

    Hello Nina
    A very good introduction into design patterns is the book "Head First: Design Patterns". Here you will find many good reasons why and when to use the factory pattern.
    You should use the factory pattern when
    - you want to prevent "direct" instantiation (i.e. using a public CONSTRUCTOR method) by the developer
    - you want to hide the complexity of instantiation from the user of the class
    - the instantiation creates an implementation of an interface and you want to keep control of which implementing class is returned
    Regards
      Uwe

  • Difference between n-layer software architecture and MVVM design pattern?

    hello everyone,
    I am not clear with this concepts of Software architecture pattern and design pattern.
    I am developing an wpf application using MVVM. Now, my question is, does MVVM come under n-layered architecture? 
    or n-layer architecture and MVVM both are different? 
    Regards,
    Rakesh.N
    Rakesh murthy

    "
    Now my question is, i want to process the data which i get from database. where should i write that processing logic after getting the data from database? in model classes? or in view model classes?
    The model is however the data comes from wherever it comes from.
    If there is any processing after you get it then that would be in the viewmodel.
    The viewmodel adapts your data to the view.
    If it needs any adapting then the viewmodel does that, not the model.
    EG here
    protected async override void GetData()
    ThrobberVisible = Visibility.Visible;
    ObservableCollection<CustomerVM> _customers = new ObservableCollection<CustomerVM>();
    var customers = await (from c in db.Customers
    orderby c.CustomerName
    select c).ToListAsync();
    foreach (Customer cust in customers)
    _customers.Add(new CustomerVM { IsNew = false, TheEntity = cust });
    Customers = _customers;
    RaisePropertyChanged("Customers");
    ThrobberVisible = Visibility.Collapsed;
    That logic is in a viewmodel.
    in this context , in which layer the viewmodel and model classes are put under in n-tier architecture?
    They're in two of the n layers/tiers.
    Or they're in one.
    Depending on how someone decides to classify a layer or a tier.
    There is no absolute definition.
    Why would you care?
    Hope that helps.
    Technet articles: Uneventful MVVM;
    All my Technet Articles

  • Life cycle and desing patterns

    Hi Friends,
    I am new to SAP BI/BW and learned extract and Reports
    Now i am getting some doubts like what sdlc and design patterns are used to SAP BI/BW
    Please could you suggest , whether we are have to use in BI/BW
    thanks
    Babu

    Hi Babu,
    SAP BI/BW project also has got the standard project life cycle steps. Whenever you are working on a SAP BI/BW implementation project it starts from
    Requirement Gathering -
    > Blueprinting -
    > High level and detailed design -
    > Implementation -
    > Unit Testing -
    > Integration Testing -
    > Go live.
    Regards,
    Durgesh.

  • Book Review: A Serious Guide to OOP Design Patterns

    I've just finished reviewing a new book: AdvancED ActionSpript 3.0: Design Patterns by Ben Smith, published by Apress as part of the Adobe Learning Library
    I liked the book very much and I wanted to share my discovery with those of you who (like me) would like to bring the advantages of Object-Oriented Programming and Design Patterns to your Flash/AS3 application development efforts.
    I posted my review (“A Serious Guide to OOP Design Patterns”) on Amazon just the other day. Take a look at my review and browse through Mr. Smith's book—if you're interested.

    Nikimathew wrote:
    Every now and then I ask people if they are familiar with the book, Design Patterns: Elements of Reusable Object-Oriented Software. On such occassions, I'm often surprised to hear someone respond, "Yes, I've read it." Having spent close to three years running a study group devoted to understanding the subtleties, combinations and variations of the patterns in this book and others, I am often compelled to ask these individuals if they actually believe that the book can be "read" rather than "studied"? trolling for new members?
    three years? c'mon. i love the GoF book, but it's not holy writ. and it hasn't saved object-oriented software development.
    sounds like you need to move on to a new topic. go buy another book.
    %

  • Design Patterns and J2mE

    Hey,
    I do wanna know if is recommendable to use a Java Design Pattern (like Singleton, Fa�ade, etc)... in a J2ME application. I mean, a colleague of mine made a j2me application using these kind of technologies, but, when he installed in his cell phone, the application occuppied much memory. So, another guy told me that due to the limited memory space we find on these devices it's better for us to use only the MVC idea. So, is it recommendable for me to use this kind of resources???
    Thanks!

    Hi,
    it is a good programming practice to use Design patterns. But too much of design patterns results in more classes which will be a problem in j2me sometimes.
    Most of the MIDP classes uses Singleton and abstract design patterns

  • A beginner to design pattern(Struct,Spring & Hibernate framework)

    Actually I am beginner to MVC2 Approach of complex application incorporated by design pattern as Struct,Spring & Hibernate framework.
    Currently I am learning JSP Concepts,I have one doubt.
    (1)What are the things I should grasp even before taking off to Design pattern?
    Help me anyone plz?
    With Regards,
    Stalin.G

    [email protected] wrote:
    Actually I am beginner to MVC2 Approach of complex application incorporated by design pattern as Struct,Spring & Hibernate framework.
    Currently I am learning JSP Concepts,I have one doubt.Just one?
    >
    (1)What are the things I should grasp even before taking off to Design pattern?You should understand core Java very, very well.
    You should know JSPs using JSTL without scriptlets.
    You should understand relational databases and SQL.
    You should understand HTML and HTTP.
    Personally I think Struts, Spring, and Hibernate all at once are well beyond any beginner.
    It's hard to advise you on what to do without knowing your capabilities and the problem you're trying to solve, but I think you should try it first using just JSPs, servlets, and JDBC. Get that to work and then refactor it to use the frameworks. You'll understand and appreciate them more that way.
    %

  • Is MVC2 a design pattern or architecture? for yes and no why?

    I am using JSF which follows MVC2. Is MVC2 a design pattern or architecture? For yes and no why? what is the difference between design pattern or architecture?

    Hi There,
    Maybe this will help answer your questions...
    Firstly, MVC2 is a proprietary name for the Microsoft .NET framework based around the Model-View-Controller pattern - it is an updated version of their first attempt - MVC.
    The Model-View-Controller pattern harks back to the days of SmallTalk, and as far as I am aware is not included in the original Gang Of Four design patterns, although there is no reason why it can't be considered a design pattern.
    Software architecture is about how different parts of the system fit (interface) together and how they relate, including static relationships (cardinality relationships, state) and processes (what happens when), it most often consists of many design patterns each used to address the various needs of a complete system.
    Hope this helps
    Rich

  • Is design patterns to much used in j2me or wireless development?

    Hey guys,
    I do wanna know if any design patterns is too much used in J2ME development and which one of them are more used?
    Thanx
    Lucas

    Well, anything that is usable can be implemented of cource. I don't see why you you can't use them.
    Thet question what is uses morst of the time is irrelevant, since pattern are alway's dependant on what you would like to do.
    You should never use a pattern just to use a pattern!

  • Business delegate and Session facade design patterns

    Does any one tell me, what is the difference between business delegate and session facade design patterns.

    1. Session Facade decouples client code from Entity beans introducing session bean as a middle layer while Business Delegate decouples client code from EJB layer ( Session beans).
    2. SF reduces network overhead while BD reduces maintenance overhead.
    3. In SF any change in Session bean would make client code change.
    While in DB client is totally separate from Session bean because BD layer insulate client from Session beans(EJB layer).
    3. In only SF scenario, Client coder has to know about EJB programming but BD pattern no EJB specialization needed.
    4.SF emphasizes on separation of Verb, Noun scenario while BD emphasizes on separation of client(presentable) and EJB layer.
    Anybody pls suggest more differences ?

  • How to create plug and play design pattern on a environment

    Hi All,
    Help me to get a best design for my problem statement.
    Problem Statement: I have to create a platform where I should be able to plug and play different components. explaining better with example
    Example:
    1. I have to create a platform for school
    2. In this school platform we have to plug in multiple components like "Student", "Teacher", "Subjects", "ClassPeriods" etc.,
    3. These components should be easily plug/unplug and play
    4. Like, the component "ClassPeriods" want to purchase from Vendor 1 and plug it to "School" platform it should work.
    5. Incase if we want to unplug the "ClassPeriod" component provided bfy Vendor 1 from "School" platform and want to plug the "ClassPeriod" from Vendor 2. then the Design should support without any extra effort.
    Suggest me the best design pattern for the problem
    This design pattern is for ASP.Net
    Thanks,
    S.Kannan

    Sounds like you're looking at 'Composition'. As a background, and possible solution, take a look at MEF;
    http://mef.codeplex.com/
    http://pauliom.wordpress.com

  • JavaBean Models, Command Bean and J2EE Design Pattern

    Hello,
    I have read the available "How To", “Using EJBs in Web Dynpro Applications” where the author mentions that one should use a Command Bean (according to J2EE Design Patterns) so that one can invoke business methods in a Session Bean from our Web Dynpro Application. Well, although, I have read some available articles in the internet about J2EE design patterns, I still have some questions about command beans and its usage in Web Dynpro applications.
    I have developed a WD App which uses EJBs to read data from the DB.
    Let's suppose I only have two tables: BOOKS and AUTHORS.
    Let’s also suppose I have to Entity Beans (one for each table) and a Session Bean with two methods: Book[] getAllBooks() and Author[] getAllAuthors();
    I also have a Command Bean which I imported in my WD App.
    My questions are:
    How should I design my Command Bean?
    Can I have only one Command Bean with two methods each calling one of the methods of the Session Bean?
    Or instead should I design two Command Beans, one for each call?
    In the last case do the methods must be named <b>execute</b> or can I name them whatever I want?
    Furthermore, how should I store the data in my command bean? In instance variables?
    If so, can I use array of a class representing a record in the database table (for instance, classes Book and Author) or do I have to store the data in a generic collection (such as ArrayList for instance)?
    I ask this last question because if I try to store the data in an array when I am importing the Command Bean as a JavaBean model I always get an error.
    One last question: Can the Command Bean execute method directly return the data or should I always store the data in an instance variable an then get it using getter methods?
    I know this questions are more about J2EE Design Patterns and JavaBeans specification than they are about Web Dynpro but I also have doubts about the rules that the command bean must obey in order to accomplish a successful JavaBean model import in WD.
    Some guidance or tips would be highly appreciated.
    King Regards

    I have the same problem.
    Does anyone know the solution?
    Thanks
    Davide

Maybe you are looking for

  • How to solve ORA-12560:TNS:protocol adapter error?

    I'm trying to use sqlplus on Windows 2008 R2 which is installed on VirtualBox to access an Oracle 11gR2 database on Red Hat Linux. I'm sure that the database on Red Hat Linux is up and tnsnames.ora is a copy from another machine which is used by anot

  • Full Screen mode feedback

    I love that Flash CC now has a Full Screen mode. However, a couple of minor oversights keep me from using it regularly: I can't see tabs of the other documents I currently have open. In order to switch documents, I have to switch back to regular view

  • Soap 1.2 in NetBeans 6.1

    I have a BPEL process (NetBeans 6.1 CAPS) calling a Visual Studio 2008 web service. It's a simple string in, string out scenario. There are a few posts on the web that claim to consume .net web service from BPEL using the most recent binding componen

  • Fingerprint Sensor/Reader not working?

    I completely wiped my computer clean with a fresh recovery since I had problems. Everything has been running smoothly except the Fingerprint sensor. When I used to swipe my finger it would light up and HP SimplePass would open up. Now nothing happens

  • Clear Accounts

    Experts, Is there any t-code or functionality to clear up accounts similar to clearing vendors ( f-44). All answers would be duly rewarded with points. Thanks, Nandita