public void addLine(Line line) { if (m_lines == Collections.EMPTY_LIST) { m_lines = new ArrayList<Line>(); } int max = getModel().getMaxLineCount(); if (m_lines.size() >= max) { throw new MaxLinesException("Maximum number of allowed lines is " + max); } line.setPhone(this); m_lines.add(line); line.initialize(); }
public Line createSpecialPhoneProvisionUserLine() { Line line = createLine(); line.setUser(m_phoneContext.createSpecialPhoneProvisionUser(getSerialNumber())); line.setPhone(this); return line; }
public Line createLine() { Line line = new Line(); line.setPhone(this); line.setModelFilesContext(getModelFilesContext()); return line; }