You cannot post messages because only members can post, and you are not currently a member.
|
Refactor Heaven
|
| |
[[link]] One of the reasons I considered creating Trogger (The Travel Log) is that it has a lot of common functionality with Golf Adept - for both the mobile application and the server side. Modern development thinking is that we should not write code that is not needed. With modern refactoring IDEs this is now not only possible but a pleasure. Look at... more »
|
|
User Management
|
| |
Adept is a browser-based system. As such it is inherently multi-user. With more than one operator, the need for user management becomes manifest. The Adept Library provides this support with a User object - a persistent DAO. The User object contains a name and password for authentication. Authentication is not enough. Any system that needs... more »
|
|
Disk Caches and Notebooks
|
| |
Now that I am working in a research job again I will be reviving my blogging. As Software Manager I just did not have time or enough excess energy. While I am thinking up a list of topics I will start off with a complaint session. With the new contract I bought a Macbook Pro with wireless broadband so I could access things like Safari Books Online... more »
|
|
Time Sensitive Caches
|
| |
Nothing is forever. If you have a program that is short-lived compared to the mean time between change of the data being cached, then a LRU cache will be more than adequate. If the program is an application server and could be left running for days, weeks or even months - then there's a good chance that the data being cached will need to be changed. Enter the time sensitive cache.... more »
|
|
JavaScript Events - Part 4 - Event Library Source
|
| |
As promised, here it is. Refer to the earlier articles if you want to know the hows and whys.
/*
* Created on 5/11/4
*
* Copyright 2004 Paul Marrington
* All rights reserved - [link]
* PROPRIETARY/CONFIDENTIAL
* Use is subject to license terms - p...@marrington.net... more »
|
|
JavaScript Events - Part 3 - An Event Library
|
| |
My first attempt at an event library allowed a single event to be attached to multiple elements, as well as multiple event methods to a single event on a single element. This is very useful when you want to track the mouse since you need to register the same even for multiple windows or frames. However, it did require the creation of a special event object and then to have that object attached. Consequently - except for the special mouse tracking case - most of my events were set in the time honoured way:... more »
|
|
JavaScript Events - Part 2 - The Event Object
|
| |
I've no intention to describe the event object in detail. After all, the subject could easily fill a book (and it has). Given the depth to which I use this object, I will describe the browser differences I've found and how I've overcome them.
Retrieving The Event Object In Mozilla the event object is passed to the event function as the one and only parameter. IE, however, has a nasty global variable called event. Does that make IE single threaded? Probably. I don't want to even think of the havoc multiple threads running the same Java code would cause. I think Mozilla must handle it. I can set a breakpoint in an event manager and have setTimeout() JavaScript trigger while still stopped in the debugger.... more »
|
|
The LRU Cache
|
| |
In truth, all caches created using the Cache class are LRU caches. If you need to use the other caching properties without restricting the number of elements, give it a huge size or use the default constructor.
// Once 50 elements are cached the least recently accessed will be discarded.
Cache cache = new Cache( 50);... more »
|
|
JavaScript Events - Part 1 - Setting Events
|
| |
This is part 1 of a 3 part series.
* Part 1: Setting Events
* Part 2: The Event Object.
* Part 3: A General Usable Event Manager.
I've just refactored the JavaScript events system for Adept. I initially chose to implement the menu system by generating HTML rather than by building objects. Bad choice. It highlighted the operational inconsistencies between 3 completely different ways to add an event to an element.... more »
|
|
Coding Standards and Breaking the Rules - Part 3, Exceptions
|
| |
While we are talking about going overboard while following a standard, let's talk about exceptions. Exceptions were introduced late into the C++ standard and so for many years were virtually ignored. Existing code had other mechanisms, libraries did not use them and few developers understood them. Java was developed after that. The development team decided to implement and use (or dare I say overuse) exceptions.... more »
|
|
|