public Subject(SubjectID primary, Node memberNode) throws XPathExpressionException {

		// Get the restrictions.
		this.restrictions = null;
		String restrictions = Utilities.getAttributeValue(memberNode, "restrictions");
		if(!Utilities.isNullOrWhitespace(restrictions)) {
			this.restrictions = Restrictions.valueOf(restrictions);
		}
		
		// Decode the unique ids.
		this.ids = new ArrayList<SubjectID>();
		this.ids.add(primary);
		NodeList idNodes = Utilities.selectNodes(memberNode, "./m:UniqueID", XMLLabels.STANDARD_NAMESPACES);
		for(int i = 0; i < idNodes.getLength(); ++i) {
			Node id = idNodes.item(i);
			String domain = Utilities.getAttributeValue(id, "domain");
			
			if(domain != null) {
				Contributor contributor = Contributor.findContributor(domain);
				
				String idVal =  id.getTextContent();
				SubjectID sid = new SubjectID(contributor, idVal);
				if(!this.ids.contains(sid)) {
					this.ids.add(sid);
				}
			}
		}
		
		// Decode the name.
		this.name = new SubjectName(Utilities.selectSingleNode(memberNode, "./m:Name", XMLLabels.STANDARD_NAMESPACES));
		
		// Address
		// Education
		// Certification
		// License
		// Disciplinary
		// Clinical Status
		// Occupation
		// Personal
		// Membership
		// Attachement
		// Modified Date
		// Xtensible
		
		// Other... XPath to all:
		// "./.[namespace-uri() != \"" + namespaces.get("m") + "\" & name()]"
	}