Ruang penulis
SEBUAH JURNAL TENTANG TEKNOLOGI

Belajar hal baru.
Tulis. Bagikan.

Ruang untuk merangkai pengetahuan, satu baris kode setiap hari.
Temukan tutorial, ide, dan catatan dari perjalanan belajar.

1914 catatan & terus bertumbuh
PILIHAN EDITOR
Java

Memahami Java Stream: olah koleksi dengan lebih ringkas

Pelajari alur filter, map, dan collect untuk mengolah data Java dengan kode yang mudah dibaca.

D Tim Diary Coding · 1 menit baca
UNTUK RASA INGIN TAHUMU

Catatan terbaru.

BASIC / CATATAN</>
Basic30 Sep 2010

How do I create custom exception class?

You can define your own exception class for your application specific purposes. The exception class is created by extending the java.lang.Exception class for checked exception or java.lang.RuntimeException for unchecked exception. By creating your own Exception classes, you could identify the problem more precisely. package org.kodejava.basic; public class CustomExceptionExample { public static void main(String[] args) { […]

Wayan · 1 menit baca
BASIC / CATATAN</>
Basic30 Sep 2010

How do I use checked and unchecked exception?

By throwing a checked exception, you force the caller to handle the exception in a catch block. If a method throws a checked exception, it must declare that it throw the exception in the method declaration. All exceptions are checked exceptions, except for those indicated by java.lang.Error, java.lang.RuntimeException, and their subclasses. Runtime exception are exceptional […]

Wayan · 2 menit baca
CORE API / CATATAN</>
Core API30 Sep 2010

How do I convert raw IP address to String?

This example show you how to convert a raw IP address, an array of byte, returned by InetAddress.getAddress() method call to its string representation. package org.kodejava.net; import java.net.InetAddress; import java.net.UnknownHostException; public class RawIPToString { public static void main(String[] args) { byte[] ip = new byte[0]; try { InetAddress address = InetAddress.getLocalHost(); ip = address.getAddress(); } […]

Wayan · 1 menit baca
SWING / CATATAN</>
Swing28 Sep 2010

How do I create a vertical JSlider?

To create a vertical JSlider set the orientation on the JSlider‘s constructor to JSlider.VERTICAL. If you do not pass JSlider.VERTICAL as a constructor parameter use the setOrientation() method instead. package org.kodejava.swing; import javax.swing.*; import java.awt.*; public class JSliderVertical extends JPanel { public JSliderVertical() { initializeUI(); } public static void showFrame() { JPanel panel = new […]

Wayan · 1 menit baca
SWING / CATATAN</>
Swing28 Sep 2010

How do I use a JSlider component?

This simple example show you how to use the JSlider component. A JSlider component is intended to let the user easily enter a numeric value bounded by a minimum and maximum value. There are a couples properties that you need to set when creating a JSlider. These include setting setMinorTickSpacing(), setMajorTickSpacing(), setPaintTicks() and setPaintLabels(). These […]

Wayan · 2 menit baca
SWING / CATATAN</>
Swing27 Sep 2010

How do I create a scrollable JTable component?

To create a scrollable JTable component we have to use a JScrollPane as the container of the JTable. Besides, that we also need to set the table auto resize mode to JTable.AUTO_RESIZE_OFF so that a horizontal scroll bar displayed by the scroll pane when needed. If we do not turn off the auto resize mode, […]

Wayan · 2 menit baca

Pengetahuan tumbuh ketika dibagikan.

Simpan rasa ingin tahu. Selalu ada hal baru untuk dipelajari.

Jelajahi catatan ↗
Putu Adi Guna Permana
TENTANG PENULIS

Dr (C). Ir. Putu Adi Guna Permana, S.Kom., M.Kom., IPM., ASEAN Eng.

Penulis dan pendiri Diary Coding — berbagi catatan, tutorial, dan pengalaman seputar pemrograman untuk siapa pun yang ingin terus belajar.