- Computers & Software»
- Computer Science & Programming
Developing Systematics for BlackBerry App Development
When developing a new BB App it may happen that you may be at your wits' end as to how to begin and where to begin. A systematic approach to starting a new BB App project may help us overcome this initial hesitancy. All programmers have rituals which help them get started. Even these rituals may not completely remove anxiety at the start of a new project. Having a systematics for starting a project and then having a systematics to overcome any moments of doldrums might help smooth the development process.
When you have some information about your project try to write up project goals in your own words. As soon as you have started applying your mind to a problem at hand you will start thinking about difficulties that you may face. All programmers have grey areas. Things they don't know. Things that they aren't too sure about. Try to make a list of things that you need to master for this project. Search code snippets and store them in text files. General reading of documentation should be avoided to keep focus. You can create a file called focus.txt in the project's research folder. There is no need to remove all your grey areas before you start the project. But it is always important to keep focus. And focus may change. While at the beginning of project focus may be to get rid of "starting" anxiety later on there may be specific problem to be solved. If anxiety returns and you hit a writer's block you may return to same rituals that you used at beginning to get back into momentum.
Conversation With Yourself
Writing up the project goals is not same as writing design document. It is more a conversation with self. Design documents are written as part of Object Oriented Systems Analysis and Design. Goals documents are conversations with self. Design documents use design systematics such as UML etc. Goals document are chatty, conversational.
Next we make a short list of our grey areas. Things we do not know or are not too sure about. Is it possible to centre text vertically in a label area? If yes, how? In my article "Getting Started in BlackBerry App Development" I had proposed that my series of BB-App-Dev articles on hubpages develop a "pedagogic" App software. I had suggested a simple App which presents two fractions and asks user to add them and enter resulting fraction to earn game reward points. Now typically a fraction is written as: a b/c when bare minimum fixed width typewriter like text can be used. But it would be much better if we print on a BB screen like one sees in high school math books. That is "a" will be placed at vertical centre of a graphic box which will be about two lines high. "b" and "c" will follow it except that "b" will be on top line and "c" will on bottom line. And "/" that occurs in "b/c" will become a horizontal bar that can be painted using underscore. How can we show underscored text?
The type of search that we do on internet is not random search. We are looking for something. We are searching with a purpose. It is purposive search. When you read documentation while writing software, you read it with a purpose. It is not idle reading as in reading a novel. It is purposive reading. You are reading with a purpose. You can make rituals around searching and reading docs and forums with a specific purpose. You can keep record of searches. The searches are recorded by browsers in browsing history. But that is different. You can make your own record of searches you did, the keywords that you used and with what purpose the search was performed. And which link you found useful. As you research internet and read relevant docs pages you may realise how hard or easy a task going to be. It may make your expectation more realistic.
Example of Purposive Search
Centring Text Vertically in a Label Area
To illustrate above points, I searched Google with following words:
- BlackBerry Centring Text Vertically in a Label Area
- BlackBerry Java Centring Text Vertically in a Label Area
First attempt gave me search result with following link on top: http://supportforums.blackberry.com/t5/Adobe-AIR-Development/Align-text-vertically-on-a-Label/td-p/1058465 . Since this was obviously not what I was looking for I looked at the second link which had relevant material. I also searched again Google with second set of keywords and that produced more relevant link at the top of result: http://stackoverflow.com/questions/6127907/blackberry-vertically-center-labelfield-with-custom-height .
Books are another resource which can be tapped for building a ritual which can help you break out of anxiety. A familiar routine always helps more effectively than uncharted territory. If you have in past carried a book to (say) a cafetaria, it is worth finding out if same ritual can help mitigate anxiety and help you get started. Even if it were a book unrelated to your purposive search effort, it may be worth trying rituals which helped you in past. Best kind of rituals are those that combine work related activity with something else. But if you need ritual only at the beginning it is okay to follow any ritual. Any ritual at all which helps you get started and then once the start has happened ritual is not needed. Such rituals may compensate for lost time on them by an early start which may build up to a healthy fast paced momentum.
I scour for books on internet. Amazon.com is a good website to brainstorm for books. On individual title's page related books are shown under various headings like: "Frequently Bought Together", "Customers Who Bought This Item Also Bought", etc. I donot rush into buying books. I always search local library's online catalogue and reserve a book if it is there. As a part of ritual to get started on new project reserving a book in local library may or may not work for you. Most good books have long reservation queue. Even when you are only person to reserve, transit times for books to arrive at your local branch may be huge. Still I reserve books because for me it brings finality to one step: the step of searching books. Searching and reserving book in library may be done in earnest, but really they are rituals. If it works to break our writer's block it is useful. If it does not then we should try to wean ourselves from it. You should develope habit of self-observation and see if a certain ritual is helping or not.
Sometimes you might find free downloadable copy of book that you like. If you prefer accessing electronic versions of books try your local library. They may have relationship with a electronic book vendor. Books with index are excellent source of purposive searches. Most electronic versions of books that I have downloaded are in Adobe Acrobat PDF format. Some are in "Compiled HTML Help" format with file extension *.CHM. These opens with Microsoft(R) HTML Help reader. This is the reader started by many Microsoft(R) programs when help is requested and it has a "Search" tab. As part of ritual to get started on a new project, books are far cry from purposive searches conducted on internet. But if you have a desk reference type of book which is more than just a copy-paste of official docs pages then they will have more guidance than typical docs pages have. Some people like to read print books rather than read their electronic copies. A print book can be carried. Very useful if getting away from desk will help start your project. Here again having a helpful ritual is more important than just any ritual whatsoever. We want to break the hold of writer's block.
Ritual can be anything but if it is even indirectly related to work then it has dual uses: one use is like the use of any other rituals and another is to provide with real concrete information to solve your problem. In office environment no one will object to a ritual like this.
Accessing Javadocs in BlackBerry Java Plug-in for Eclipse
Both flavors of BB Dev IDE's come with documentation for java as well as RIM supplied packages. Javadocs are all HTML files and can be viewed in any internet browser. If I had installed BB Java Plug-in for Eclipse in the folder named: "C:\akkad" then I would find files like "index*.html" in folder like: C:\akkad\plugins\net.rim.ejde.componentpack7.0.0_22.214.171.124\components\docs\api\index-files
Let me show this path in "tree" format:
Please note the name: "net.rim.ejde.componentpack7.0.0_126.96.36.199". This name will vary from version to version. Also if you are searching inside C:\akkad folder and its heirarchy a file named "index.html" you might fail. Search instead for files named: "index*.html". This hassle of finding the path where docs files are stored is quite unnecessary when you have source file opened in Eclipse. In Eclipse with plugin if you are reading a program written by somebody else and you want to find documentation of a Java or RIM supplied class then you can hover mouse on its name in source program and the plug-in will show you the documentation related to the class in a popup window. These are known as ToolTip popups, but if you are familiar with tool-tip popups in context of Windows then these are different. These show a lot of text requiring a scrollbar. Scrollbar shows when you move the mouse caret into the popup area.
This popup also shows on top left corner a button to show the attributes and methods of the class whose documentation is on display inside the popup window. If you hover mouse on it it will show TooTip text: "Open Declaration". If you click on this button you will see all the methods and attributes of class on right hand side panel.
In using in-built help like this same priniciple of keeping focussed applies.
Best rituals are those which produce useful information as a by product. Writer's block can affect anyone at the beginning of project or when project gets interrupted. Getting back into the momentum is key result we are looking for. Best rituals are those that make it easy for you to put your past projects in "History" folder and make you current project your current obsession. Every programmer has his own systematics. Good employers are those who foster anxiety-free environment and let individuality be freely expressed. On programmers' side there should be readiness to discard old rituals which don't seem to work any more and make new ones in hope that they will be working better. Systematics satisfy neurotic programmers' urge to have rituals while at the same time they produce results.