11 rekayasa perangkat lunak arsitektur perangkat lunak
DESCRIPTION
Rekayasa Perangkat LunakTRANSCRIPT
16/05/2013
1
REKAYASA PERANGKAT LUNAKREKAYASA PERANGKAT LUNAK
ARSITEKTUR PERANGKAT LUNAK
2
DEFINISI (1)DEFINISI (1)
• An abstract system specification consisting primarily of functional components described in terms of their behaviors and interfaces and component-component interconnections. The interconnections define provide by which components interact.
• How the system is decomposed and organized into components and must describe the interfaces between these components.
16/05/2013
2
3
DEFINISI (2)DEFINISI (2)
• The organizational structure of a software system including components, connections, constraints, and rationale. Components can be small pieces of code, such as modules, or
larger chunks, such a stand-alone programs like database management systems.
Connections in an architecture are abstractions for how components interact in a system, e.g., procedure calls, pipes, and remote procedure calls.
An architecture has various constraints and rationalesassociated with it, including the constraints on component selection and the rationale for choosing a specific componentin a given situation.
4
DEFINISI (3)DEFINISI (3)
• Gambaran bagaimana elemen/komponen fungsional perangkat lunak disusun, diorganisasi dan distrukturkan sehingga: Hubungan antar elemen/komponen dapat
dijelaskan. Interface yang menghubungkan elemen/komponen
dapat didefinisikan. Wujud dan penempatan elemen/komponen dalam
tempat penyimpanan sekunder secara fisik dapat ditetapkan.
16/05/2013
3
5
STRUCTURE CHARTSTRUCTURE CHART
• Diagram untuk menggambarkan arsitektur perangkat lunak secara keseluruhantanpa memperlihatkan proses pemilihan dan pengulangannya secara rinci.
• Menggambarkan arsitektur perangkat lunak seperti diagram organisasi sebuah perusahaan.
6
SIMBOL STRUCTURE CHARTSIMBOL STRUCTURE CHART
Simbol Arti
• Modul
• Pemanggilan modul
• Data atau elemen kontrol yang dikirimkan atau diterima dari satu modul
• Pengulangan di dalam modul
• Penyeleksian kondisi di dalam modul
16/05/2013
4
7
CONTOH STRUCTURE CHART (1) : PASCALCONTOH STRUCTURE CHART (1) : PASCAL
• Modul A memanggil modul B dengan data x dan y sebagai parameternya.
• Modul B mengirimkan data p dan q sebagai return value ke modul A.
A
B
modul pemanggil
modul yang dipanggil
p, q notasi untuk parameter output yang diberikan pada modul pemanggil
x, y
notasi untuk parameter input yang dikirimkan kepada modul yang dipanggil
Procedure A;Var p, q : Real;Procedure B(x, y : Real);Begin
p := ... { manipulasi nilai p }q := ... { manipulasi nilai q }
End;BeginB(x, y); { call procedure B }
End;
Potongan kode program dalam bahasa Pascal
8
CONTOH STRUCTURE CHART (2) : PASCALCONTOH STRUCTURE CHART (2) : PASCAL
• Modul A akan memanggil modul B jika kondisi dalam modul A dipenuhi.
• Modul A akan memanggil modul C secara berulang.
Procedure C;Begin...
End;Procedure B;Begin...
End;Procedure A;BeginIf True Then B; {call procedure B}While True Do C; {call procedure C}
End;
Potongan kode program dalam bahasa Pascal
A
B C
16/05/2013
5
9
CONTOH STRUCTURE CHART (3) : PHPCONTOH STRUCTURE CHART (3) : PHP
<html>
...
<form method=post action=Rekam.php>...
</html>
<?
// Rekam.php
function getId() {
}
function saveId(id) {
}
id = getId();
saveId(id)
?>
FormInput.html
Rekam.php
FormInput
Rekam
getId saveId
id id
10
CONTOH STRUCTURE CHART (4) : DELPHICONTOH STRUCTURE CHART (4) : DELPHI
unit main;...varForm1: TForm1;
implementationuses Rekam;
procedure TForm1.Click(Sender: TObject);beginfrmRekam.Show;
end;
end.
unit Rekam;...varfrmRekam: TForm1;
implementation...end.
main.pas
rekam.pas
Main
Rekam
16/05/2013
6
11
id_supplier
rec_supplier
rec_supplier
rec_barang
id_barang
Bagian Penjualan
Barang
Supplier
1
Tambah Data Barang
2Tambah
Data Supplier
CONTOH ARSITEKTUR PERANGKAT LUNAKCONTOH ARSITEKTUR PERANGKAT LUNAK
Baca Id_Supplier
Rekam Supplier
Tambah Data Supplier
id_supplier rec_supplier
Baca Id_Barang
Rekam Barang
Tambah Data Barang
id_barang rec_barang
Kelola Data Induk
Model Analisis (DFD level atomik)
Proses 2.0Proses 1.0
Modul Pemanggil
Arsitektur Perangkat Lunak(Structure Chart)
Modul-modul atomik (procedure, function)
supplier