/// <summary> /// Акцессор до исходного мапинга /// </summary> public MappingInfo GetMappingInfo() { if (null == _info) { if (!File.Exists(_fileName)) { _info = CreateNewInfo(_hash); } else { _info = LoadInfo(_fileName); } _info.Normalize(); } return(_info); }
private static void ReadCommits(XElement xml, MappingInfo result) { var commits = xml.Element(Const.COMMITSELEMENT); if (null != commits) { foreach (var e in commits.Elements()) { var commit = new Commit(); commit.Hash = e.Name.LocalName; ReadCommitAuthorInfo(commit, e); ReadCommitSourceInfo(commit, e); result.Commits[commit.Hash] = commit; } } }
/// <summary> /// Отменяет изменения и сбрасывает MappingInfo /// </summary> public void Cancel() { _info = null; _commited = false; }