Oracle® WebCenter Interaction Development Kit 10.3.3.0.0

IDocumentManager.CheckInDocument Method 

Checks in a new version of a document that is currently in the checked-out state.

void CheckInDocument(
   IDocument document,
   string checkInComment,
   Stream inStream,
   string language,
   bool keepCheckedOut
);

Parameters

document
The document that is being checked in; cannot be null.
checkInComment
A string containing a comment that will be inserted into the document history as a check-in comment of the new version; cannot be null.
inStream
A Stream from which the contents of the new version of the document will be read; cannot be null.
language
The document content language. This is the ISO 639-1 language code, i.e. en for english. Specifying a null language will set the language to that of the current user.
keepCheckedOut
True to automatically check in and subsequently check out the document. The document will finish in the checked-out state.

Remarks

This includes saving a new version of the document, incrementing the current version number and making a new entry in the document's history.

Note: To use any document upload/download functionality, including this method, you must install WSE 2.0 (http://msdn.microsoft.com/webservices/building/wse/).

The following sample code demonstrates how to check in a new document version.
//Open an inputstream for the document contents - this can be any readable Stream
Stream fileInputStream = File.OpenRead("c:\\MyNewDocument.doc");
//Check in the new version
documentManager.CheckInDocument(checkedOutDocument, "this is an updated version of the document", fileInputStream, "en", false);

Exceptions

Exception TypeCondition
PermissionDeniedException The user does not have permission to check-in the document, or the user does not currently have the document checked out.
CollaborationException The method call resulted in an error or the the user does not have access to the document.
SoapException There was a communication problem during the execution of the remote method call.
InvalidOperationException The document is not checked out, has not yet been inserted, or has already been removed.

See Also

IDocumentManager Interface | Plumtree.Remote.PRC.Collaboration.Document Namespace