public IInOutImageState Get(InOutImageId id, bool nullAllowed) { IInOutImageState state = CurrentSession.Get <InOutImageState>(id); if (!nullAllowed && state == null) { state = new InOutImageState(); (state as InOutImageState).InOutImageId = id; } if (ReadOnlyProxyGenerator != null && state != null) { return(ReadOnlyProxyGenerator.CreateProxy <IInOutImageState>(state, new Type[] { }, _readOnlyPropertyNames)); } return(state); }
public virtual IInOutImageState GetInOutImage(string inOutDocumentNumber, string sequenceId) { var entityId = new InOutImageId(inOutDocumentNumber, sequenceId); return(CurrentSession.Get <InOutImageState>(entityId)); }