<< Click to Display Table of Contents >>
CheckIn
아이템을 체크인합니다.
Prototype
bool CheckIn(string ItemLocalFullPath, string ItemServerFullPath, [bool KeepCheckout], string Comment)
bool CheckIn(array ItemLocalFullPaths, array ItemServerFullPaths, array ErrorCodes, [array KeepCheckouts], string Comment)
bool CheckIn(object Item, string ItemServerFullPath, [bool KeepCheckout], string Comment)
bool CheckIn(array Items, array ItemServerFullPaths, array ErrorCodes, [array KeepCheckouts], string Comment)
Parameters
ItemLocalFullPath |
로컬 파일 전체 경로 |
ItemServerFullPath |
서버 전체 경로 |
KeepCheckout |
체크아웃 상태 유지 여부 |
Comment |
주석 |
ItemLocalFullPaths |
로컬 파일 전체 경로를 가진 배열 |
ItemServerFullPaths |
서버 전체 경로를 가진 배열 |
ErrorCodes |
에러 코드를 가져올 배열 |
KeepCheckouts |
체크아웃 상태 유지 여부를 가진 배열 |
Item |
아이템 오즈 바이너리 객체로 설정하여야 함 |
Items |
아이템을 가진 배열 오즈 바이너리 객체를 가진 배열로 설정하여야 함 |
Reference
체크인이 성공한 경우 true가 리턴되고, 실패한 경우 false가 리턴됩니다.
에러가 발생한 아이템의 인덱스에 에러 코드 값을 리턴하며, 성공한 경우에는 에러 코드 값에 0을 리턴합니다.
Example 1
function checkIn(){
var rep = OZCreator.GetBuiltInObject(OZBuiltInObject.REPOSITORY);
var login = rep.Login("admin","admin");
if (login) {
var itemLocalFullPath = "c:/parameter_test.odi";
var itemServerFullPath = "/abc/parameter_test.odi";
var result = rep.CheckIn(itemLocalFullPath, itemServerFullPath, "comment");
if (result == true) {
_DEBUG("result="+result);
} else {
_DEBUG("result="+result+"["+rep.GetLastErrorCode()+"] "+rep.GetErrorMessageByCode(rep.GetLastErrorCode()));
}
rep.Logout();
}
}
Example 2
function checkIn(){
var rep = OZCreator.GetBuiltInObject(OZBuiltInObject.REPOSITORY);
var login = rep.Login("admin","admin");
if (login) {
var itemlocalFullPaths = new Array();
itemlocalFullPaths[0] = "c:/parameter_test.odi";
itemlocalFullPaths[1] = "c:/parameter_test.ozr";
var serverFullPaths = new Array();
serverFullPaths[0] = "/abc/parameter_test.odi";
serverFullPaths[1] = "/abc/parameter_test.ozr";
var errorCodes = new Array();
var keepCheckouts = new Array();
keepCheckouts[0] = true;
keepCheckouts[1] = true;
var result = rep.CheckIn(itemlocalFullPaths, serverFullPaths, errorCodes, keepCheckouts, "comment");
if (result == true) {
_DEBUG("result="+result);
} else {
for (i=0; i < errorCodes.length; i++) {
_DEBUG("i="+i+" ["+errorCodes[i]+"] "+rep.GetErrorMessageByCode(errorCodes[i]));
}
}
rep.Logout();
}
}
Example 3
function checkIn(){
var rep = OZCreator.GetBuiltInObject(OZBuiltInObject.REPOSITORY);
var login = rep.Login("admin","admin");
if (login) {
var item = OZCreator.GetBuiltInObject(OZBuiltInObject.BINARY);
item.ReadFromFile("c:/parameter_test.odi");
var itemServerFullPath = "/abc/parameter_test.odi";
var keepCheckout = true;
var result = rep.CheckIn(item, itemServerFullPath, keepCheckout, "comment");
if (result == true) {
_DEBUG("result="+result);
} else {
_DEBUG("result="+result+"["+rep.GetLastErrorCode()+"] "+rep.GetErrorMessageByCode(rep.GetLastErrorCode()));
}
rep.Logout();
}
}
Example 4
function checkIn(){
var rep = OZCreator.GetBuiltInObject(OZBuiltInObject.REPOSITORY);
var login = rep.Login("admin","admin");
if (login) {
var items = new Array();
items[0] = OZCreator.GetBuiltInObject(OZBuiltInObject.BINARY);
items[0].ReadFromFile("c:/parameter_test.odi");
items[1] = OZCreator.GetBuiltInObject(OZBuiltInObject.BINARY);
items[1].ReadFromFile("c:/parameter_test.ozr");
var itemServerFullPaths = new Array();
itemServerFullPaths[0] = "/data/parameter_test.odi";
itemServerFullPaths[1] = "/report/parameter_test.ozr";
var errorCodes = new Array();
var keepCheckout = new Array();
keepCheckout[0] = true;
keepCheckout[1] = true;
var result = rep.CheckIn(items, itemServerFullPaths, errorCodes, keepCheckout, "comment");
if (result == true) {
_DEBUG("result="+result);
} else {
for (i=0; i < errorCodes.length; i++) {
_DEBUG("i="+i+" ["+errorCodes[i]+"] "+rep.GetErrorMessageByCode(errorCodes[i]));
}
}
rep.Logout();
}
}
See Also