public CreateOrUpdateDocumentWorkflow(NetherpadDataManager context, Document document, string content) : base(context) { if (string.IsNullOrEmpty(document.Identifier)) { this.Add(new GenerateUniqueIdentifierStep(context), 1); this.Add(new CreateNewDocumentStep(context, document), 2); } else { this.Add(new UpdateDocumentStep(context, document, content), 1); } }
public UpdateDocumentStep(NetherpadDataManager db, Document document, string content) { this.db = db; this.document = document; this.content = content; }
public GenerateUniqueIdentifierStep(NetherpadDataManager db) { this.db = db; }
public DeleteDocumentStep(NetherpadDataManager db, Document document) { this.db = db; this.document = document; }
public DocumentsController() { this.dataManager = new NetherpadDataManager(new NetherpadEntities()); }
public CreateNewDocumentStep(NetherpadDataManager db, Document document) { this.db = db; this.document = document; }
public DeleteDocumentWorkflow(NetherpadDataManager context, Document document) : base(context) { this.Add(new DeleteDocumentStep(context, document),1); }
public DeleteDocumentWorkflow(NetherpadDataManager context, Document document) : base(context) { this.Add(new DeleteDocumentStep(context, document), 1); }