Artikel mit Tag java

myndian.de

Artikel mit Tag java

Verwandte Tags

web development documentation internet mozilla strindtemplate jsp web-applikationen model driven software development velocity javascript xml mvc dynamic typing configuration test strong typing groovy spring framework ibatis sql maps sql oracle database tools ms sql server jdbc fun literatur disco satire internet explorer video projekt apple safari scala netscape familie firefox c# web wissenschaft werbung bus & bahn montag tussis framework optimization object orientation performance antipattern fehlerbehandlung nice mixins jade composition rpg traits adom groocy language gallerien blogs foren kommunikation grails windows enttäuschung book mocks tests tutorial unittests eclipse myndian.de songbird itunes web2.0 tagging view open source

Mittwoch, 31. Oktober 2007

last language war language trolling

Sorry, I could not get around. I had to post this. :-D

(via Ted Newards Blog Ride)
Geschrieben von Jörg in Softwaretechnik um 16:51 | Kommentare (0) | Trackbacks (0)
Tags für diesen Artikel: c#, fun, java, scala

Montag, 2. Juli 2007

Dynamic two dimensional array in Java

I need a dynamic two dimensional array in Java. I thought I might not be the only one, so I searched with regular search engines and the code searches. Surprisingly I did not find any free implementation. I thought this would be a such common case, that the JRE or at least the Jakarta Commons Collections might contain it. No, they do not.

It seems the rest of the world builds their own implementation or uses the javax.swing.table.TableModel and javax.swing.table.DefaultTableModel. The public API of the latter gets near to what I want, but it’s not exactly what I was looking for.

I thought about something like this:

interface TwoDimensionalArray<T>
{
T set(int x, int y, T value);
boolean add(int x, int y, T value);
T get(int x, int y);
Iterator<Iterable<T>> iterator();
boolean isEmpty();
/** returning the overall element count */
int size();
}
Geschrieben von Jörg in Softwaretechnik um 08:02 | Kommentare (0) | Trackbacks (0)
Tags für diesen Artikel: java, open source

Montag, 15. Mai 2006

static vs. dynamic typed configuration

This mornig I had to think a little about how to configure a particular system. Some parts of the system use different implementations of specific modules defined by interfaces. If there should be used a special implementation among the standard one, it is configured in a properties file. The value is the full qualified name of the implementing class, which is loaded and instanciated via reflection. Because we use Java and Java is a statically typed language, we have to cast the instance from Object to the interface.

This is a common pattern, I think. It is used by log4j for example.

Because we use a property configuration, which is not typed and validated against anything, the implementations can be configured as needed.

The opposite may be an XML configuration, which is validated against a schema. If we would use this and wanted to use it continuous for all modules, we had to design an universal schema for all modules or one for every implementation, which is imported into the main configuration.

It is very clear which one is faster and improves development speed. I have seen this pattern with dynamic configurations (even with an xml like syntax) several times in different Java applications and frameworks, but I just remember one with a statically typed, xml based configuration. But even this one used a universal, not really typed schema for the dynamic modules. So I think it’s just the same.

Applications, developed in a statically typed language, but dynamically typed. As I think about it, a common error in those applications are wrong configurations, mostly these little typos you do not find very fast and drive you crazy. Much like in dynamic languages. But would a strong and statically typed configuration, validated against some genius schemas, be worth the effort?

Just a little a thought, that crossed my mind.
Geschrieben von Jörg in Softwaretechnik um 12:29 | Kommentare (0) | Trackbacks (0)
Tags für diesen Artikel: configuration, dynamic typing, java, strong typing

Montag, 6. Februar 2006

notice: JDBC batch updates

Lesson for today: Do not update 341443 records at once. :-)
java.sql.BatchUpdateException: I/O Error: Connection reset by peer: socket write error
Better split the update in parts.
Geschrieben von Jörg in Softwaretechnik um 12:38 | Kommentare (0) | Trackbacks (0)
Tags für diesen Artikel: database, java, jdbc, ms sql server, sql

Freitag, 3. Februar 2006

the framework framework

This nice arcticle from Angsuman Chakraborty was annoucend in the Java Lobby Newsletter and is fun to read. :-)

Perhaps the “framework framework” should be done by some bootstrapping, so the framework will be build with the framework itself. Perhaps this could be done by a “framework bootstrapping framework”, which is also build with the “framework framework”. ;-)
Geschrieben von Jörg in Internet, Softwaretechnik um 09:29 | Kommentare (0) | Trackbacks (0)
Tags für diesen Artikel: framework, fun, java
« vorherige Seite   (Seite 2 von 3, insgesamt 12 Einträge) » nächste Seite

Suche

Statische Seiten

Startseite
Galerien
Impressum

Kategorien

  • XML Alltag
  • XML Internet
  • XML Musik
  • XML Politik
  • XML Reise
  • XML Softwaretechnik
  • XML Sonstiges
  • XML Visuelles

Alle Kategorien

Archive

Mai 2012
April 2012
März 2012
Das Neueste ...
Älteres ...

Blog abonnieren

XML RSS 2.0 feed
ATOM/XML ATOM 1.0 feed
XML RSS 2.0 Kommentare

Login

Verwaltung des Blogs

Login

Aktuelle Einträge

Netzwerkkultur verändert die Gesellschaft
Dienstag, 17. November

Absolute and relative date and time
Sonntag, 18. Oktober

Oren Lavie - Her Morning Elegance
Dienstag, 6. Oktober

Twitter & Blogroll
Samstag, 8. August

Read It Later: Round-Trip-Integration mit Firefox und Google-Reader
Montag, 3. August

Blogroll

* Jörg bei Twitter
* Jens bei Twitter
* Nils bei Twitter

* Beetlebum
* a life less ordinary?
* Martin Fowler's Bliki
* Springify
* BILDblog
* Plazeboalarm
* LawBlog
* ADOM Blog
* Being busy
* Dr. Gero Presser

Links

* Heise
* The Scala Programming Language
Nils' Fotos bei fotocommunity.de
Jogi auf Qype
Get Firefox!
Use OpenOffice.org

Heise News

* Nintendo DS steuert Navi im Auto fern

* Streit um Itanium spitzt sich zu

* Facebook: Der schwache 100-Milliarden-Dollar-Start

* Juristen sehen ACTA-Prozedere in den USA als verfassungswidrig an

* Sicherheitslücke bei Kreditkartendienstleister größer als gedacht

kostenloser Counter