*/
public Object deserialize(Element element) {
String perspectiveId = element.getAttribute(PersistenceConstants.PERSPECTIVE_ATTRIBUTE_ID);
String perspectiveName = element.getAttribute(PersistenceConstants.PERSPECTIVE_ATTRIBUTE_NAME);
Perspective perspective = new Perspective(perspectiveId, perspectiveName);
NodeList layoutNodeList = element.getElementsByTagName(PersistenceConstants.LAYOUT_ELEMENT_NAME);
ISerializer layoutSerializer = SerializerRegistry.getSerializer(Layout.class);
if (layoutNodeList.getLength() > 0 && layoutNodeList.item(0) instanceof Element) {
Element layoutElement = (Element) layoutNodeList.item(0);
Layout layout = (Layout) layoutSerializer.deserialize(layoutElement);
perspective.setLayout(layout);
}
NodeList layoutSequenceNodeList = element.getElementsByTagName(PersistenceConstants.LAYOUT_SEQUENCE_ELEMENT_NAME);
ISerializer layoutSequenceSerializer = SerializerRegistry.getSerializer(LayoutSequence.class);
if (layoutSequenceNodeList.getLength() > 0 && layoutSequenceNodeList.item(0) instanceof Element) {
Element layoutSequenceElement = (Element) layoutSequenceNodeList.item(0);
LayoutSequence layoutSequence = (LayoutSequence) layoutSequenceSerializer.deserialize(layoutSequenceElement);
perspective.setInitialSequence(layoutSequence);
}
return perspective;
}