Ejemplo n.º 1
0
 protected virtual void WriteHeader(string name, DateTime lastModificationTime, long count, string userName, string groupName, int mode)
 {
     var tarHeader = new UsTarHeader()
     {
         FileName = name,
         LastModification = lastModificationTime,
         SizeInBytes = count,
         UserId = userName.GetHashCode(),
         UserName = userName,
         GroupId = groupName.GetHashCode(),
         GroupName = groupName,
         Mode = mode
     };
     OutStream.Write(tarHeader.GetHeaderValue(), 0, tarHeader.HeaderSize);
 }
Ejemplo n.º 2
0
 protected override void WriteHeader(string name, DateTime lastModificationTime, long count, int userId, int groupId, int mode)
 {
     var tarHeader = new UsTarHeader()
     {
         FileName = name,
         LastModification = lastModificationTime,
         SizeInBytes = count,
         UserId = userId,
         UserName = Convert.ToString(userId,8),
         GroupId = groupId,
         GroupName = Convert.ToString(groupId,8),
         Mode = mode
     };
     OutStream.Write(tarHeader.GetHeaderValue(), 0, tarHeader.HeaderSize);
 }
Ejemplo n.º 3
0
        protected virtual void WriteHeader(string name, DateTime lastModificationTime, long count, string userName, string groupName, int mode)
        {
            var tarHeader = new UsTarHeader()
            {
                FileName         = name,
                LastModification = lastModificationTime,
                SizeInBytes      = count,
                UserId           = userName.GetHashCode(),
                UserName         = userName,
                GroupId          = groupName.GetHashCode(),
                GroupName        = groupName,
                Mode             = mode
            };

            OutStream.Write(tarHeader.GetHeaderValue(), 0, tarHeader.HeaderSize);
        }
Ejemplo n.º 4
0
        protected override void WriteHeader(string name, DateTime lastModificationTime, long count, int userId, int groupId, int mode)
        {
            var tarHeader = new UsTarHeader()
            {
                FileName         = name,
                LastModification = lastModificationTime,
                SizeInBytes      = count,
                UserId           = userId,
                UserName         = Convert.ToString(userId, 8),
                GroupId          = groupId,
                GroupName        = Convert.ToString(groupId, 8),
                Mode             = mode
            };

            OutStream.Write(tarHeader.GetHeaderValue(), 0, tarHeader.HeaderSize);
        }