Module: DFC
Overview
- Copyright
-
Copyright 2015 - 2018 巧夺天宫版权所有
Constants:
-
FOLDER # -> 根目录(安装目录/DFC_BIM)
-
VERSION # -> 版本,格式 x.x.x,例:2.1.0(每次发布用户版时会改变)
-
CURRENT_VERSION # -> 版本,格式 xxx_xxx_xxx,例:002_001_002(每次发布用户版时会改变)
-
DEBUG # -> 发布版该值为 false,开发及测试版该值为 true
-
HOME_PAGE # -> 巧夺天宫主页
-
SUPPORTED_VERSION # -> 支持的最低 su 版本(目前最低是 2017)
-
COPYRIGHT # -> 版权声明
-
DOMAIN # -> 专业
-
RELEASE_DATE # -> 版本发布日期
-
VENDOR_USER # -> 商家版用户
-
DESIGN_USER # -> 设计版用户
Defined Under Namespace
Modules: Attribute, Common, EnvInfo, FaceBool, FloorInfo, Image, ModelAttribute, ModuleInterface, ObserverReloader, ReleasedVersion, ToDoList Classes: CURL, Crypt, CurrentPosition, CurrentPositionObserver, Cursor, Database, Debug, ErrorRecord, FloorParams, FloorParamsObserver, LibObserver, Log, MouseCursor, POI, Path, PathHandler, Progress, RootEntities, Screen, SketchupUtil, TgkApi, TimeReport, Valid, Window
Constant Summary #
- DFC::DOMAIN
- DFC::VENDOR_USER
- DFC::DESIGN_USER
- DFC::MEP
- DFC::FULL_FUNCTION
- DFC::INTERIOR_DECORETION
- DFC::DFC_Floor
Class Method Summary # collapse
-
.add_observer(object) ⇒ True
封装了 Sketchup::add_observer,因为 Sketchup 的这个功能执行顺序是乱的,而我们的观察者是需要顺序的.
-
.dfc_file_loaded(filename) ⇒ True
设置指定文件为已加载.
-
.dfc_file_loaded?(filename) ⇒ Boolean
判断文件是否已经加载过.
-
.dfc_require(*strings) ⇒ Boolean, Nil
DFC 专用的 require,会把捕获到的异常写入记录文件,同时会继续执行,不会因加载异常导致 DFC 无法启动.
-
.remove_observer(object) ⇒ True
移除观察者.
-
.soft_type ⇒ Symbol
获取软件版本类型.
-
.user_type ⇒ Symbol
获取用户类型(也是用于判断 DFC 的商家与设计师版本类型).
-
.version ⇒ String
获取软件版本号.
Class Method Details
↑ .add_observer(object) ⇒ True
不建议使用这个,而是使用 DFC::ObserverReloader
封装了 Sketchup::add_observer,因为 Sketchup 的这个功能执行顺序是乱的,而我们的观察者是需要顺序的
只需要把 Sketchup::add_observer 替换为 DFC::add_observer 即可,可观察内容参考 Sketchup::AppObserver
↑ .dfc_file_loaded(filename) ⇒ True
设置指定文件为已加载
↑ .dfc_file_loaded?(filename) ⇒ Boolean
判断文件是否已经加载过
↑ .dfc_require(*strings) ⇒ Boolean, Nil
DFC 专用的 require,会把捕获到的异常写入记录文件,同时会继续执行,不会因加载异常导致 DFC 无法启动
不是所有情况都可以使用,所以大家看着用吧
↑ .remove_observer(object) ⇒ True
移除观察者
↑ .soft_type ⇒ Symbol
获取软件版本类型
MEP # -> 机电版
FULL_FUNCTION # -> 全功能版
INTERIOR_DECORETION # -> 内装版
↑ .user_type ⇒ Symbol
获取用户类型(也是用于判断 DFC 的商家与设计师版本类型)
VENDOR_USER # -> 商家版
DESIGN_USER # -> 设计师版
↑ .version ⇒ String
获取软件版本号