annotate rep/RPanel.java @ 170:30cf7747d134

*** empty log message ***
author pin
date Thu, 28 Aug 2008 18:56:46 +0900
parents 01062be677e9
children a097b1d619a1
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
1 package rep;
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
2
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
3 import java.awt.Dimension;
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
4 import java.awt.event.ActionEvent;
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
5 import java.awt.event.ActionListener;
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
6 import java.nio.channels.SocketChannel;
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
7
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
8 import javax.swing.JButton;
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
9 import javax.swing.JComboBox;
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
10 import javax.swing.JLabel;
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
11 import javax.swing.JPanel;
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
12 import javax.swing.JScrollPane;
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
13 import javax.swing.JTable;
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
14 import javax.swing.JTextArea;
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
15 import javax.swing.JTextField;
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
16 import javax.swing.table.DefaultTableModel;
134
4ad47fad8fa4 *** empty log message ***
kent
parents: 122
diff changeset
17
4ad47fad8fa4 *** empty log message ***
kent
parents: 122
diff changeset
18 import rep.channel.REPSocketChannel;
4ad47fad8fa4 *** empty log message ***
kent
parents: 122
diff changeset
19
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
20 import java.util.*;
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
21
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
22 public class RPanel extends JPanel implements ActionListener {
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
23
140
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
24 /**
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
25 *
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
26 */
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
27 private static final long serialVersionUID = 1L;
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
28 private JButton button;
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
29 private JTextField textField;
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
30 private String host;
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
31 private JLabel label;
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
32 private JTextArea textArea;
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
33 //private JScrollPane scrollPane;
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
34 private SessionViewer sessionViewer;
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
35 //private JScrollPane viewerPane;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
36 private JTable session_table;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
37 private JScrollPane s_sp;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
38 private JTable editor_table;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
39 private JScrollPane e_sp;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
40 private String[] session_column = {"HOST", "PORT", "FILE", "SID", "EID"};
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
41 private String[] editor_column = {"EID", "SOCKET_CHANNEL"};
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
42 private DefaultTableModel s_tableModel = new DefaultTableModel(session_column, 0);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
43 private DefaultTableModel e_tableModel = new DefaultTableModel(editor_column, 0);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
44 LinkedList<SessionPlus> s_list = new LinkedList<SessionPlus>();
140
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
45 LinkedList<EditorPlus<REPCommand>> e_list = new LinkedList<EditorPlus<REPCommand>>();
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
46 private String s_host;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
47 private String s_port;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
48 private String s_file;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
49 private String s_sid;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
50 private String s_eid;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
51 private String e_eid;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
52 private String e_socketchannel;
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
53 private ConnectionListener listener;
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
54 private JComboBox comboEditor;
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
55 private JComboBox comboSession;
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
56 private JButton buttonSelect;
140
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
57 private REPActionListener<REPCommand> actionListener;
122
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
58 private JButton buttonUndo;
140
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
59 private REPActionListener<REPCommand> undoListener;
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
60
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
61 public RPanel() {
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
62 button = new JButton("Connect");
6
bdb91f4cea26 It Can connect SessionManagers each other.
pin
parents: 2
diff changeset
63 textField = new JTextField("firefly.cr.ie.u-ryukyu.ac.jp");
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
64 textArea = new JTextArea();
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
65 label = new JLabel("test");
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
66 //scrollPane = new JScrollPane(textArea);
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
67 sessionViewer = new SessionViewer();
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
68 //viewerPane = new JScrollPane(sessionViewer.getTree());
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
69 session_table = new JTable(s_tableModel);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
70 s_sp = new JScrollPane(session_table);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
71 editor_table = new JTable(e_tableModel);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
72 e_sp = new JScrollPane(editor_table);
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
73 //scrollBar = new JScrollBar(JScrollBar.VERTICAL);
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
74 comboEditor = new JComboBox();
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
75 comboSession = new JComboBox();
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
76 buttonSelect = new JButton("Select");
122
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
77 buttonUndo = new JButton("Undo");
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
78
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
79
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
80 button.setBounds(160, 5, 100, 20);
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
81 textField.setBounds(5, 5, 150, 20);
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
82 textArea.setEditable(false);
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
83 textArea.setLineWrap(false);
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
84 //scrollPane.setBounds(5, 30, 200, 200);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
85 //scrollPane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
86 //viewerPane.setBounds(5, 30, 200, 200);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
87 //viewerPane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
88 session_table.setBounds(5,30,400,200);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
89 s_sp.setPreferredSize(new Dimension(200, 200));
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
90 s_sp.setBounds(5,30,400,100);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
91 e_sp.setPreferredSize(new Dimension(200, 200));
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
92 e_sp.setBounds(5,140,400,100);
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
93 //scrollPane.setPreferredSize(new Dimension(200, 200));
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
94 //textArea.setBounds(5, 30, 200, 200);
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
95 //textArea.add(scrollBar, BorderLayout.EAST);
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
96 comboEditor.setBounds(450, 50, 100, 50);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
97 comboSession.setBounds(450, 100, 100, 50);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
98 buttonSelect.setBounds(450, 180, 100, 20);
122
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
99 buttonUndo.setBounds(450, 140, 100, 20);
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
100
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
101
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
102 this.setLayout(null);
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
103 this.add(textField);
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
104 this.add( button);
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
105 this.add(label);
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
106 //this.add(textArea);
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
107 //this.add(scrollPane, BorderLayout.CENTER);
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
108 ///this.add(viewerPane, BorderLayout.CENTER);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
109 this.add(s_sp);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
110 this.add(e_sp);
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
111 //this.add(label, BorderLayout.CENTER);
61
491962300d0a Slect button for table is made
chiaki
parents: 56
diff changeset
112 //this.add(comboEditor);
491962300d0a Slect button for table is made
chiaki
parents: 56
diff changeset
113 //this.add(comboSession);
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
114 this.add(buttonSelect);
122
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
115 this.add(buttonUndo);
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
116
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
117 button.addActionListener(this);
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
118 buttonSelect.addActionListener(this);
122
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
119 buttonUndo.addActionListener(this);
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
120 }
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
121
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
122 public void addSessionTree(int SID){
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
123 sessionViewer.addSessionTree(SID);
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
124 }
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
125
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
126 public void actionPerformed(ActionEvent event) {
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
127 if (event.getSource() == button) {
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
128 host = textField.getText();
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
129 listener.connectionOccured(new ConnectionEvent(host));
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
130 }else if(event.getSource() == buttonSelect){
61
491962300d0a Slect button for table is made
chiaki
parents: 56
diff changeset
131 /*
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
132 actionListener.ActionOccured(new REPActionEvent((EditorPlus) comboEditor.getSelectedItem(),
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
133 (SessionPlus)comboSession.getSelectedItem()));
61
491962300d0a Slect button for table is made
chiaki
parents: 56
diff changeset
134 */
140
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
135 actionListener.ActionOccured(new REPActionEvent<REPCommand>((EditorPlus<REPCommand>) e_list.get(editor_table.getSelectedRow()),
61
491962300d0a Slect button for table is made
chiaki
parents: 56
diff changeset
136 (SessionPlus)s_list.get(session_table.getSelectedRow())));
122
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
137 }else if(event.getSource() == buttonUndo){
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
138 //System.out.println("Undo!");
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
139 actionListener.undo();
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
140 }
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
141 }
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
142
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
143 public void addConnectionListener(ConnectionListener listener) {
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
144 System.out.println(listener.toString());
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
145 this.listener = listener;
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
146 }
122
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
147
140
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
148 public void addUndoListener(REPActionListener<REPCommand> listener3){
122
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
149 undoListener = listener3;
790c8dd42a7b *** empty log message ***
kono
parents: 61
diff changeset
150 }
2
02fa9a68d9a2 *** empty log message ***
pin
parents: 1
diff changeset
151
134
4ad47fad8fa4 *** empty log message ***
kent
parents: 122
diff changeset
152 public void setComboEditor(int eid, REPSocketChannel<REPCommand> channel) {
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
153 //comboEditor.addItem("Editor:"+eid);
140
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
154 comboEditor.addItem(new EditorPlus<REPCommand>(eid, channel));
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
155 }
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
156
140
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
157 public void addREPActionListener(REPActionListener<REPCommand> listener2) {
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
158 this.actionListener = listener2;
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
159 }
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
160
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
161 public void setComboSession(int sessionID, String string) {
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
162 comboSession.addItem(new SessionPlus(sessionID, string));
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
163 }
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
164
134
4ad47fad8fa4 *** empty log message ***
kent
parents: 122
diff changeset
165 public void setTableEditor(int eid, REPSocketChannel<REPCommand> channel) {
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
166 //comboEditor.addItem("Editor:"+eid);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
167
140
01062be677e9 *** empty log message ***
kono
parents: 134
diff changeset
168 EditorPlus<REPCommand> ep = new EditorPlus<REPCommand>(eid, channel);
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
169 e_list.add(ep);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
170 Vector editor = new Vector();
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
171 e_eid = "Editor : " + eid;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
172 e_socketchannel = "SocketChannel : " + channel;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
173 editor.add(e_eid);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
174 editor.add(e_socketchannel);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
175 e_tableModel.addRow(editor);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
176 }
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
177
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
178 public void setTableSession(int sessionID, String string) {
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
179 SessionPlus sp = new SessionPlus(sessionID, string);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
180 s_list.add(sp);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
181 Vector session = new Vector();
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
182 s_host = " ";
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
183 s_port = " ";
61
491962300d0a Slect button for table is made
chiaki
parents: 56
diff changeset
184 s_file = "" + string;
54
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
185 s_sid = "" + sessionID;
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
186 s_eid = " ";
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
187 session.add(s_host);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
188 session.add(s_port);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
189 session.add(s_file);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
190 session.add(s_sid);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
191 session.add(s_eid);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
192 s_tableModel.addRow(session);
ece6aaddfec4 add Table of Editor and Session
chiaki
parents: 8
diff changeset
193 }
8
b774b87cc2c1 *** empty log message ***
pin
parents: 6
diff changeset
194
1
3f5bf0255f5e *** empty log message ***
pin
parents:
diff changeset
195 }