using System;
|
using System.Collections.Generic;
|
using System.Linq;
|
using System.Text;
|
|
namespace IStation.Bimface
|
{
|
/// <summary>
|
/// 转换源
|
/// </summary>
|
public class TranslateSource
|
{
|
public TranslateSource()
|
{
|
this.compressed = false;
|
this.rootName = null;
|
}
|
|
/// <summary>
|
/// 文件Id,即调用上传文件API返回的fileId
|
/// </summary>
|
public long fileId { get; set; }
|
|
/// <summary>
|
/// 是否为压缩文件,默认为false
|
/// </summary>
|
public bool compressed { get; set; }
|
|
/// <summary>
|
/// 如果是压缩文件,必须指定压缩包中哪一个是主文件。(例如:root.rvt)。
|
/// 如果不是压缩,则设置为 null
|
/// </summary>
|
public string rootName { get; set; }
|
|
/// <summary>
|
/// 获取JSON字典
|
/// </summary>
|
/// <returns></returns>
|
public virtual Dictionary<string, object> GetJsonDict()
|
{
|
var dic = new Dictionary<string, object>();
|
dic.Add("fileId", this.fileId);
|
dic.Add("compressed", this.compressed);
|
if (!string.IsNullOrEmpty(this.rootName))
|
{
|
dic.Add("rootName", this.rootName);
|
}
|
return dic;
|
}
|
|
|
|
}
|
}
|