diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml index ec0a27c60..980064dac 100644 --- a/.github/FUNDING.yml +++ b/.github/FUNDING.yml @@ -1,8 +1,8 @@ # These are supported funding model platforms github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2] -patreon: pyrevit -open_collective: # Replace with a single Open Collective username +patreon: # pyrevit +open_collective: pyrevitlabs ko_fi: # Replace with a single Ko-fi username tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry diff --git a/.github/ISSUE_TEMPLATE/BUG_REPORT.md b/.github/ISSUE_TEMPLATE/BUG_REPORT.md deleted file mode 100644 index 646b2d216..000000000 --- a/.github/ISSUE_TEMPLATE/BUG_REPORT.md +++ /dev/null @@ -1,49 +0,0 @@ ---- -name: Bug report -about: Create a report to help us improve - ---- ---- - -**🚧 If you have SentinelOne installed as an antivirus, look no further. You will need to create exceptions for Revit and pyRevit, both on the software and the %appdata% folders.** - ---- - -**🙏 Please use the search in the issue section before filing a new issue** - ---- - -# 🐞 Describe the bug - -Replace these lines with your description. Be as specific as possible and list steps to reproduce the issue. If you have any suggestions for the solution please list that as well. - -If you have installed pyRevit, and the installation completed with no errors but pyRevit doesn't load, please run the command below in terminal / command line. This should fix the issue on your machine, however, please continue filing the issue with instructions below. - -👉 `pyrevit attach master 2711 --installed` - -If it does not work, try to disable your revit addins, all of them. Then, one at a time, reactivate them and restart Revit to figure out which one is interacting badly with pyRevit and Report. - - -# ♻️ To Reproduce -Steps to reproduce the behavior: -1. Go to '...' -2. Click on '....' -3. Scroll down to '....' -4. See error - -# ⏲️ Expected behavior -A clear and concise description of what you expected to happen. - -# 🖼 Screenshots of the issue -If applicable, add screenshots to help explain your problem. - -# 🖥️ Hardware and Software Setup (please complete the following information): - - OS: [e.g. iOS] - - pyRevit Version [e.g. 22] - - pyRevit Environment: Open a command prompt 🖥 and run the command below. Replace these lines with the results. Take a look at this markdown guide and wrap the command results in ``` when pasting here for correct formatting. - -👉 `pyrevit env` - -# Additional context -Add any other context about the problem here. - diff --git a/.github/ISSUE_TEMPLATE/BUG_REPORT.yml b/.github/ISSUE_TEMPLATE/BUG_REPORT.yml new file mode 100644 index 000000000..59c52dbcc --- /dev/null +++ b/.github/ISSUE_TEMPLATE/BUG_REPORT.yml @@ -0,0 +1,70 @@ +--- +name: Bug report +description: Thanks for taking the time to report a bug! +title: "[Bug]: " +labels: [Bug] +body: + - type: markdown + attributes: + value: | + > **🚧 If you have SentinelOne installed as an antivirus, look no further.** + > **You will need to create exceptions for Revit and pyRevit, both on the software and the %appdata% folders.** + - type: checkboxes + id: preflight + attributes: + label: ✈ Pre-Flight checks + description: before submitting an issue, make sure you've checked the following + options: + - label: I **don't have SentinelOne** antivirus installed (see above for the solution) + required: true + - label: I have **searched in the issues** (open and closed) but couldn't find a similar issue + required: true + - label: I have **searched in the [pyRevit Forum](https://discourse.pyrevitlabs.io)** for similar issues + required: true + - label: I already **followed the [installation troubleshooting guide](https://pyrevitlabs.notion.site/Installation-issues-f6495adb56254e9e8021f8a68e3b2ab7) thoroughly** + required: true + - label: I am using the **latest pyRevit Version** + required: true + - type: textarea + id: description + attributes: + label: 🐞 Describe the bug + description: Be as specific as possible and list steps to reproduce the issue. + validations: + required: true + - type: textarea + id: error-message + attributes: + label: ⌨ Error/Debug Message + description: If you have any suggestions for the solution, please list that as well. Issues related to tools/scripts, I tried to run them in debug mode (CTRL+click on the button) and copy over the contents of the output window. + render: shell + validations: + required: true + - type: textarea + id: reproduce-steps + attributes: + label: ♻️ To Reproduce + description: Steps to reproduce the behavior + placeholder: | + 1. Go to '...' + 2. Click on '....' + 3. Scroll down to '....' + 4. See error + - type: textarea + id: expected-behavior + attributes: + label: ⏲️ Expected behavior + description: A clear and concise description of what you expected to happen. + - type: textarea + id: env + attributes: + label: 🖥️ Hardware and Software Setup (please complete the following information) + description: Open a command prompt 🖥 and run the command `pyrevit env`. Paste the output here. + render: shell + validations: + required: true + - type: textarea + id: context + attributes: + label: Additional context + description: Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md b/.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md index 066b2d920..d700a8c4f 100644 --- a/.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md +++ b/.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md @@ -1,17 +1,21 @@ --- name: Feature request about: Suggest an idea for this project - +labels: "New Feature" --- -**Is your feature request related to a problem? Please describe.** -A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] +## Is your feature request related to a problem? Please describe + + + +## Describe the solution you'd like + + + +## Describe alternatives you've considered -**Describe the solution you'd like** -A clear and concise description of what you want to happen. + -**Describe alternatives you've considered** -A clear and concise description of any alternative solutions or features you've considered. +## Additional context -**Additional context** -Add any other context or screenshots about the feature request here. + diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 000000000..3ba13e0ce --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1 @@ +blank_issues_enabled: false diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 97d086637..da2a4ea34 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -3,15 +3,22 @@ updates: - package-ecosystem: "pip" directory: "/" schedule: - interval: "weekly" + interval: "monthly" # Check for npm updates on Sundays day: "sunday" # Raise pull requests for version updates - # to pip against the `develop` branch - target-branch: "develop" + # to pip against the `develop-4` branch + target-branch: "develop-4" - package-ecosystem: "gomod" # directory required https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#vendor directory: "/" - target-branch: "develop" + target-branch: "develop-4" schedule: - interval: "weekly" + interval: "monthly" + # Set update schedule for GitHub Actions + - package-ecosystem: "github-actions" + directory: "/" + schedule: + # Check for updates to GitHub Actions every week + interval: "monthly" + target-branch: "develop-4" diff --git a/.github/slash-commands.yml b/.github/slash-commands.yml new file mode 100644 index 000000000..984a7f7fa --- /dev/null +++ b/.github/slash-commands.yml @@ -0,0 +1,27 @@ +issues: + more-info: + label: + - needs-more-info + + install-fix: + comment: > + Hi @{{ author }}, Try these steps: + + 1. Uninstall pyRevit + + 2. Delete C:\ProgramData and %AppData%\ pyRevit and pyrevit-master folders + + 3. Move all Revit addins to a temporary location. Usual addins locations include: + - %AppData%\Autodesk\Revit\Addins + - %AppData%\Autodesk\ApplicationPlugins + - %ProgramData%\Autodesk\Revit\Addins + - %ProgramData%\Autodesk\ApplicationPlugins + + 4. [Reboot computer] + + 5. Reinstall pyRevit + + 6. Started each version of Revit confirming pyRevit successfully compiled at startup. + + 7. Move all Revit addins that were moved in step 3 back to their original location. + You may want to add them one at a time and start a revit session everytime to figure out which ones are causing the issue. diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index 17de0c967..b14fdd88f 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -11,24 +11,54 @@ jobs: uses: actions/checkout@v4 with: fetch-depth: 0 - ref: ${{ github.head_ref }} - - - name: Checkout Submodules - uses: snickerbockers/submodules-init@7ce9774442c0c2d4728e6d3f66141df2102e4cbc + submodules: recursive - name: Prepare Python 3.10 - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.10' - + - name: Prepare pipenv run: | pip install pipenv pipenv install + # needs for MahApps XamlColorSchemeGenerator + - name: Prepare .NET 3.1 + uses: actions/setup-dotnet@v4 + with: + dotnet-version: 3.1.x + + - name: Prepare .NET 8.0 + uses: actions/setup-dotnet@v4 + with: + dotnet-version: 8.0.x + - name: Prepare msbuild - uses: microsoft/setup-msbuild@v1.1 + uses: microsoft/setup-msbuild@v2 - name: Build Products run: | pipenv run pyrevit build products + + - name: Build Installers + run: | + pipenv run pyrevit build installers + + - name: Get Install Version + id: installversion + uses: juliangruber/read-file-action@v1 + with: + path: release/version + + - name: Upload Installers + uses: actions/upload-artifact@v4 + with: + name: pyrevit-installers + path: | + dist/pyRevit_${{ steps.installversion.outputs.content }}_signed.exe + dist/pyRevit_${{ steps.installversion.outputs.content }}_admin_signed.exe + dist/pyRevit_CLI_${{ steps.installversion.outputs.content }}_signed.exe + dist/pyRevit_CLI_${{ steps.installversion.outputs.content }}_admin_signed.exe + dist/pyRevit_CLI_${{ steps.installversion.outputs.content }}_admin_signed.msi + dist/pyrevit-cli.${{ steps.installversion.outputs.content }}.nupkg diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index b01d38850..c40760d5a 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -4,10 +4,20 @@ on: push: branches: - docs + paths: + - 'mkdocs.yml' + - 'docs/**' + - 'pyrevitlib/**' + - '*.md' # when PR from develop->master is created pull_request: branches: - master + paths: + - 'mkdocs.yml' + - 'docs/**' + - 'pyrevitlib/**' + - '*.md' # manual run workflow_dispatch: @@ -15,10 +25,10 @@ jobs: docs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Prepare Python 3.10 - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.10' diff --git a/.github/workflows/issues-manager.yml b/.github/workflows/issues-manager.yml new file mode 100644 index 000000000..fba46c08d --- /dev/null +++ b/.github/workflows/issues-manager.yml @@ -0,0 +1,20 @@ +name: issues-manager +on: + issue_comment: + types: [created] + +jobs: + issue_commented: + runs-on: ubuntu-latest + steps: + - name: Custom Slash Commands + uses: wow-actions/slash-commands@v1.1.0 + with: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + CONFIG_FILE: .github/slash-commands.yml + + - name: Pending Response Follow Up + uses: siegerts/pending-response@v1.0 + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + pending-response-label: needs-more-info diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index fa07bea91..a7ab0528d 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,15 +1,27 @@ name: pyRevitCI on: # when PRs from forked repos are merged - # eirannejad 02/12/2024: disabled develop ci/cd builds for pyRevit 5 - # we will reactivate when changes are ready to build on every commit - # push: - # branches: - # - develop + push: + branches: + - develop-4 + paths: + - 'bin/**' + - 'dev/**' + - 'extensions/**' + - 'pyrevitlib/**' + - 'release/**' + - 'site-packages/**' # when PR from develop->master is created pull_request: branches: - master + paths: + - 'bin/**' + - 'dev/**' + - 'extensions/**' + - 'pyrevitlib/**' + - 'release/**' + - 'site-packages/**' # manual run workflow_dispatch: @@ -18,7 +30,7 @@ env: jobs: build: - if: github.repository == 'eirannejad/pyRevit' + if: github.repository == 'pyrevitlabs/pyRevit' runs-on: windows-latest steps: - name: Report Context @@ -40,10 +52,10 @@ jobs: ref: ${{ github.head_ref }} - name: Checkout Submodules - uses: snickerbockers/submodules-init@7ce9774442c0c2d4728e6d3f66141df2102e4cbc + uses: jmcouffin/submodules-init@ae47afe19152906d341ee759b39034176873f8ff - name: Prepare Python 3.10 - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.10' @@ -53,7 +65,7 @@ jobs: pipenv install - name: Prepare msbuild - uses: microsoft/setup-msbuild@v1.1 + uses: microsoft/setup-msbuild@v2 - name: Prepare git uses: fregante/setup-git-user@v2 @@ -131,7 +143,7 @@ jobs: # default retention period is 90 days # https://github.com/marketplace/actions/upload-a-build-artifact#retention-period - name: Upload Installers - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: pyrevit-installers path: | @@ -141,7 +153,6 @@ jobs: dist/pyRevit_CLI_${{ steps.installversion.outputs.content }}_admin_signed.exe dist/pyRevit_CLI_${{ steps.installversion.outputs.content }}_admin_signed.msi dist/pyrevit-cli.${{ steps.installversion.outputs.content }}.nupkg - - name: Generate Release Notes (Release) if: (github.base_ref == env.ReleaseBranch) env: @@ -160,7 +171,7 @@ jobs: - name: Publish Release (Release) id: publish_release if: (github.base_ref == env.ReleaseBranch) - uses: softprops/action-gh-release@v1 + uses: softprops/action-gh-release@v2 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: diff --git a/.github/workflows/stale-issues.yml b/.github/workflows/stale-issues.yml index 10cbfa46d..422155efe 100644 --- a/.github/workflows/stale-issues.yml +++ b/.github/workflows/stale-issues.yml @@ -10,11 +10,17 @@ jobs: issues: write pull-requests: write steps: - - uses: actions/stale@v9.0.0 + - uses: actions/stale@v9 with: days-before-issue-stale: 60 days-before-issue-close: 14 - stale-issue-message: "This issue is stale because it has been open for 60 days with no activity." + stale-issue-message: | + "👋 Hi there! It looks like there hasn't been any activity on this issue for the past 60 days. We understand that things can get busy. + Just a friendly reminder that this issue is scheduled to be automatically closed in 14 days if there's no further activity. + If you still need assistance or have additional information to share, please feel free to comment, and we'll be happy to help! 🚀 + Thanks for your understanding!" close-issue-message: "This issue was closed because it has been inactive for 14 days since being marked as stale." + any-of-issue-labels: needs-more-info days-before-pr-stale: -1 days-before-pr-close: -1 + diff --git a/.gitignore b/.gitignore index 790954c0c..b26c5bfd1 100644 --- a/.gitignore +++ b/.gitignore @@ -11,13 +11,13 @@ extensions/* !extensions/extensions.json !extensions/README.md !extensions/pyRevitBundlesCreatorExtension.extension/ -bin/* -!bin/engines -!bin/pyrevit.svg -!bin/pyrevit_outputwindow.png -!bin/pyrevit_settings.png -!bin/pyrevit-hosts.json -!bin/pyrevit-products.json +#bin/* +#!bin/engines +#!bin/pyrevit.svg +#!bin/pyrevit_outputwindow.png +#!bin/pyrevit_settings.png +#!bin/pyrevit-hosts.json +#!bin/pyrevit-products.json # ignore visual studio files **/.vs @@ -59,3 +59,4 @@ dist/ # misc .idea site/ +*.pdb diff --git a/.gitmodules b/.gitmodules index 19d215343..babd674f7 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,18 +1,23 @@ [submodule "dev/modules/pyRevitLabs.Python.Net"] path = dev/modules/pyRevitLabs.Python.Net url = https://github.com/pyrevitlabs/pythonnet.git + branch = pyrevit-5-main [submodule "dev/modules/pyRevitLabs.dlr"] path = dev/modules/pyRevitLabs.dlr url = https://github.com/pyrevitlabs/dlr.git + branch = pyrevit-5-main [submodule "dev/modules/pyRevitLabs.ironpython2"] path = dev/modules/pyRevitLabs.ironpython2 url = https://github.com/pyrevitlabs/ironpython2.git + branch = pyrevit-5-main [submodule "dev/modules/pyRevitLabs.dlr3"] path = dev/modules/pyRevitLabs.dlr3 url = https://github.com/pyrevitlabs/dlr.git + branch = pyrevit-5-main [submodule "dev/modules/pyRevitLabs.ironpython3"] path = dev/modules/pyRevitLabs.ironpython3 url = https://github.com/pyrevitlabs/ironpython3.git + branch = pyrevit-5-main [submodule "dev/modules/pyRevitLabs.MahApps.Metro"] path = dev/modules/pyRevitLabs.MahApps.Metro url = https://github.com/pyrevitlabs/MahApps.Metro.git diff --git a/Pipfile b/Pipfile index 87adc2dc7..3ef54c671 100644 --- a/Pipfile +++ b/Pipfile @@ -5,7 +5,7 @@ verify_ssl = true [dev-packages] mypy = "*" -pylint = "==3.0.3" +pylint = "==3.1.0" black = "*" [packages] @@ -14,7 +14,7 @@ requests = "*" pygount = "*" pyyaml = ">=5.4" black = "*" -setuptools = "==69.0.3" +setuptools = "==72.1.0" mkdocs = "*" mkdocstrings = "*" mkdocstrings-python = "*" diff --git a/Pipfile.lock b/Pipfile.lock index e19600c40..1f91cf23b 100644 --- a/Pipfile.lock +++ b/Pipfile.lock @@ -1,7 +1,7 @@ { "_meta": { "hash": { - "sha256": "4a05fcd6ff09175ef16f51dcd849390599b4a474af803a07ce7cd59f1292fe61" + "sha256": "f08cf7d47bb9c290f4778741c6598d672dcceb0cd7ec8e4e70f5a5dbedce247f" }, "pipfile-spec": 6, "requires": { @@ -18,48 +18,56 @@ "default": { "babel": { "hashes": [ - "sha256:6919867db036398ba21eb5c7a0f6b28ab8cbc3ae7a73a44ebe34ae74a4e7d363", - "sha256:efb1a25b7118e67ce3a259bed20545c29cb68be8ad2c784c83689981b7a57287" + "sha256:08706bdad8d0a3413266ab61bd6c34d0c28d6e1e7badf40a2cebe67644e2e1fb", + "sha256:8daf0e265d05768bc6c7a314cf1321e9a123afc328cc635c18622a2f30a04413" ], - "markers": "python_version >= '3.7'", - "version": "==2.14.0" + "markers": "python_version >= '3.8'", + "version": "==2.15.0" + }, + "backports-strenum": { + "hashes": [ + "sha256:77c52407342898497714f0596e86188bb7084f89063226f4ba66863482f42414", + "sha256:cdcfe36dc897e2615dc793b7d3097f54d359918fc448754a517e6f23044ccf83" + ], + "markers": "python_version < '3.11'", + "version": "==1.3.1" }, "black": { "hashes": [ - "sha256:0269dfdea12442022e88043d2910429bed717b2d04523867a85dacce535916b8", - "sha256:07204d078e25327aad9ed2c64790d681238686bce254c910de640c7cc4fc3aa6", - "sha256:08b34e85170d368c37ca7bf81cf67ac863c9d1963b2c1780c39102187ec8dd62", - "sha256:1a95915c98d6e32ca43809d46d932e2abc5f1f7d582ffbe65a5b4d1588af7445", - "sha256:2588021038bd5ada078de606f2a804cadd0a3cc6a79cb3e9bb3a8bf581325a4c", - "sha256:2fa6a0e965779c8f2afb286f9ef798df770ba2b6cee063c650b96adec22c056a", - "sha256:34afe9da5056aa123b8bfda1664bfe6fb4e9c6f311d8e4a6eb089da9a9173bf9", - "sha256:3897ae5a21ca132efa219c029cce5e6bfc9c3d34ed7e892113d199c0b1b444a2", - "sha256:40657e1b78212d582a0edecafef133cf1dd02e6677f539b669db4746150d38f6", - "sha256:48b5760dcbfe5cf97fd4fba23946681f3a81514c6ab8a45b50da67ac8fbc6c7b", - "sha256:5242ecd9e990aeb995b6d03dc3b2d112d4a78f2083e5a8e86d566340ae80fec4", - "sha256:5cdc2e2195212208fbcae579b931407c1fa9997584f0a415421748aeafff1168", - "sha256:5d7b06ea8816cbd4becfe5f70accae953c53c0e53aa98730ceccb0395520ee5d", - "sha256:7258c27115c1e3b5de9ac6c4f9957e3ee2c02c0b39222a24dc7aa03ba0e986f5", - "sha256:854c06fb86fd854140f37fb24dbf10621f5dab9e3b0c29a690ba595e3d543024", - "sha256:a21725862d0e855ae05da1dd25e3825ed712eaaccef6b03017fe0853a01aa45e", - "sha256:a83fe522d9698d8f9a101b860b1ee154c1d25f8a82ceb807d319f085b2627c5b", - "sha256:b3d64db762eae4a5ce04b6e3dd745dcca0fb9560eb931a5be97472e38652a161", - "sha256:e298d588744efda02379521a19639ebcd314fba7a49be22136204d7ed1782717", - "sha256:e2c8dfa14677f90d976f68e0c923947ae68fa3961d61ee30976c388adc0b02c8", - "sha256:ecba2a15dfb2d97105be74bbfe5128bc5e9fa8477d8c46766505c1dda5883aac", - "sha256:fc1ec9aa6f4d98d022101e015261c056ddebe3da6a8ccfc2c792cbe0349d48b7" + "sha256:257d724c2c9b1660f353b36c802ccece186a30accc7742c176d29c146df6e474", + "sha256:37aae07b029fa0174d39daf02748b379399b909652a806e5708199bd93899da1", + "sha256:415e686e87dbbe6f4cd5ef0fbf764af7b89f9057b97c908742b6008cc554b9c0", + "sha256:48a85f2cb5e6799a9ef05347b476cce6c182d6c71ee36925a6c194d074336ef8", + "sha256:7768a0dbf16a39aa5e9a3ded568bb545c8c2727396d063bbaf847df05b08cd96", + "sha256:7e122b1c4fb252fd85df3ca93578732b4749d9be076593076ef4d07a0233c3e1", + "sha256:88c57dc656038f1ab9f92b3eb5335ee9b021412feaa46330d5eba4e51fe49b04", + "sha256:8e537d281831ad0e71007dcdcbe50a71470b978c453fa41ce77186bbe0ed6021", + "sha256:98e123f1d5cfd42f886624d84464f7756f60ff6eab89ae845210631714f6db94", + "sha256:accf49e151c8ed2c0cdc528691838afd217c50412534e876a19270fea1e28e2d", + "sha256:b1530ae42e9d6d5b670a34db49a94115a64596bc77710b1d05e9801e62ca0a7c", + "sha256:b9176b9832e84308818a99a561e90aa479e73c523b3f77afd07913380ae2eab7", + "sha256:bdde6f877a18f24844e381d45e9947a49e97933573ac9d4345399be37621e26c", + "sha256:be8bef99eb46d5021bf053114442914baeb3649a89dc5f3a555c88737e5e98fc", + "sha256:bf10f7310db693bb62692609b397e8d67257c55f949abde4c67f9cc574492cc7", + "sha256:c872b53057f000085da66a19c55d68f6f8ddcac2642392ad3a355878406fbd4d", + "sha256:d36ed1124bb81b32f8614555b34cc4259c3fbc7eec17870e8ff8ded335b58d8c", + "sha256:da33a1a5e49c4122ccdfd56cd021ff1ebc4a1ec4e2d01594fef9b6f267a9e741", + "sha256:dd1b5a14e417189db4c7b64a6540f31730713d173f0b63e55fabd52d61d8fdce", + "sha256:e151054aa00bad1f4e1f04919542885f89f5f7d086b8a59e5000e6c616896ffb", + "sha256:eaea3008c281f1038edb473c1aa8ed8143a5535ff18f978a318f10302b254063", + "sha256:ef703f83fc32e131e9bcc0a5094cfe85599e7109f896fe8bc96cc402f3eb4b6e" ], "index": "pypi", "markers": "python_version >= '3.8'", - "version": "==24.1.1" + "version": "==24.4.2" }, "certifi": { "hashes": [ - "sha256:0569859f95fc761b18b45ef421b1290a0f65f147e92a1e5eb3e635f9a5e4e66f", - "sha256:dc383c07b76109f368f6106eee2b593b04a011ea4d55f652c6ca24a754d1cdd1" + "sha256:5a1e7645bc0ec61a09e26c36f6106dd4cf40c6db3a1fb6352b0244e7fb057c7b", + "sha256:c198e21b1289c2ab85ee4e67bb4b4ef3ead0892059901a8d5b622f24a1101e90" ], "markers": "python_version >= '3.6'", - "version": "==2024.2.2" + "version": "==2024.7.4" }, "chardet": { "hashes": [ @@ -205,44 +213,43 @@ }, "gitpython": { "hashes": [ - "sha256:c36b6634d069b3f719610175020a9aed919421c87552185b085e04fbbdb10b7c", - "sha256:ed66e624884f76df22c8e16066d567aaa5a37d5b5fa19db2c6df6f7156db9048" + "sha256:35f314a9f878467f5453cc1fee295c3e18e52f1b99f10f6cf5b1682e968a9e7c", + "sha256:eec7ec56b92aad751f9912a73404bc02ba212a23adb2c7098ee668417051a1ff" ], - "index": "pypi", "markers": "python_version >= '3.7'", - "version": "==3.1.41" + "version": "==3.1.43" }, "griffe": { "hashes": [ - "sha256:34461730c975a31c4ffa413bdad841f217a5d1a1c611b95f6110ed0f2b2fc04d", - "sha256:b5e2f249d86feaad1d3068b33b1c8c2ecf39cb870bf292f2af3a4311891a4835" + "sha256:f099461c02f016b6be4af386d5aa92b01fb4efe6c1c2c360dda9a5d0a863bb7f", + "sha256:f944c6ff7bd31cf76f264adcd6ab8f3d00a2f972ae5cc8db2d7b6dcffeff65a2" ], "markers": "python_version >= '3.8'", - "version": "==0.39.0" + "version": "==0.48.0" }, "idna": { "hashes": [ - "sha256:9ecdbbd083b06798ae1e86adcbfe8ab1479cf864e4ee30fe4e46a003d12491ca", - "sha256:c05567e9c24a6b9faaa835c4821bad0590fbb9d5779e7caa6e1cc4978e7eb24f" + "sha256:028ff3aadf0609c1fd278d8ea3089299412a7a8b9bd005dd08b9f8285bcb5cfc", + "sha256:82fee1fc78add43492d3a1898bfa6d8a904cc97d8427f683ed8e798d07761aa0" ], "markers": "python_version >= '3.5'", - "version": "==3.6" + "version": "==3.7" }, "jinja2": { "hashes": [ - "sha256:7d6d50dd97d52cbc355597bd845fabfbac3f551e1f99619e39a35ce8c370b5fa", - "sha256:ac8bd6544d4bb2c9792bf3a159e80bba8fda7f07e81bc3aed565432d5925ba90" + "sha256:4a3aee7acbbe7303aede8e9648d13b8bf88a429282aa6122a993f0ac800cb369", + "sha256:bc5dd2abb727a5319567b7a813e6a2e7318c39f4f487cfe6c89c6f9c7d25197d" ], "markers": "python_version >= '3.7'", - "version": "==3.1.3" + "version": "==3.1.4" }, "markdown": { "hashes": [ - "sha256:d43323865d89fc0cb9b20c75fc8ad313af307cc087e84b657d9eec768eddeadd", - "sha256:e1ac7b3dc550ee80e602e71c1d168002f062e49f1b11e26a36264dafd4df2ef8" + "sha256:48f276f4d8cfb8ce6527c8f79e2ee29708508bf4d40aa410fbc3b4ee832c850f", + "sha256:ed4f41f6daecbeeb96e576ce414c41d2d876daa9a16cb35fa8ed8c2ddfad0224" ], "markers": "python_version >= '3.8'", - "version": "==3.5.2" + "version": "==3.6" }, "markdown-it-py": { "hashes": [ @@ -336,20 +343,20 @@ }, "mkdocs": { "hashes": [ - "sha256:3b3a78e736b31158d64dbb2f8ba29bd46a379d0c6e324c2246c3bc3d2189cfc1", - "sha256:eb7c99214dcb945313ba30426c2451b735992c73c2e10838f76d09e39ff4d0e2" + "sha256:1eb5cb7676b7d89323e62b56235010216319217d4af5ddc543a91beb8d125ea7", + "sha256:a73f735824ef83a4f3bcb7a231dcab23f5a838f88b7efc54a0eef5fbdbc3c512" ], "index": "pypi", - "markers": "python_version >= '3.7'", - "version": "==1.5.3" + "markers": "python_version >= '3.8'", + "version": "==1.6.0" }, "mkdocs-autorefs": { "hashes": [ - "sha256:7930fcb8ac1249f10e683967aeaddc0af49d90702af111a5e390e8b20b3d97ff", - "sha256:9a5054a94c08d28855cfab967ada10ed5be76e2bfad642302a610b252c3274c0" + "sha256:aacdfae1ab197780fb7a2dac92ad8a3d8f7ca8049a9cbe56a4218cd52e8da570", + "sha256:f684edf847eced40b570b57846b15f0bf57fb93ac2c510450775dcf16accb971" ], "markers": "python_version >= '3.8'", - "version": "==0.5.0" + "version": "==1.0.1" }, "mkdocs-exclude": { "hashes": [ @@ -367,6 +374,14 @@ "markers": "python_version >= '3.7'", "version": "==0.5.0" }, + "mkdocs-get-deps": { + "hashes": [ + "sha256:162b3d129c7fad9b19abfdcb9c1458a651628e4b1dea628ac68790fb3061c60c", + "sha256:2bf11d0b133e77a0dd036abeeb06dec8775e46efa526dc70667d8863eefc6134" + ], + "markers": "python_version >= '3.8'", + "version": "==0.2.0" + }, "mkdocs-literate-nav": { "hashes": [ "sha256:78a7ab6d878371728acb0cdc6235c9b0ffc6e83c997b037f4a5c6ff7cef7d759", @@ -378,12 +393,12 @@ }, "mkdocs-material": { "hashes": [ - "sha256:635df543c01c25c412d6c22991872267723737d5a2f062490f33b2da1c013c6d", - "sha256:a5d62b73b3b74349e45472bfadc129c871dd2d4add68d84819580597b2f50d5d" + "sha256:3fd417dd42d679e3ba08b9e2d72cd8b8af142cc4a3969676ad6b00993dd182ec", + "sha256:fc070689c5250a180e9b9d79d8491ef9a3a7acb240db0728728d6c31eeb131d4" ], "index": "pypi", "markers": "python_version >= '3.8'", - "version": "==9.5.9" + "version": "==9.5.30" }, "mkdocs-material-extensions": { "hashes": [ @@ -395,30 +410,30 @@ }, "mkdocs-section-index": { "hashes": [ - "sha256:823d298d78bc1e73e23678ff60889f3c369c2167b03dba73fea88bd0e268a60d", - "sha256:bbd209f0da79441baf136ef3a9c40665bb9681d1fb62c73ca2f116fd1388a404" + "sha256:5e5eb288e8d7984d36c11ead5533f376fdf23498f44e903929d72845b24dfe34", + "sha256:b66128d19108beceb08b226ee1ba0981840d14baf8a652b6c59e650f3f92e4f8" ], "index": "pypi", - "markers": "python_version >= '3.7'", - "version": "==0.3.8" + "markers": "python_version >= '3.8'", + "version": "==0.3.9" }, "mkdocstrings": { "hashes": [ - "sha256:222b1165be41257b494a9d29b14135d2b7ca43f38161d5b10caae03b87bd4f7e", - "sha256:f4908560c10f587326d8f5165d1908817b2e280bbf707607f601c996366a2264" + "sha256:5cf57ad7f61e8be3111a2458b4e49c2029c9cb35525393b179f9c916ca8042dc", + "sha256:9e2cda5e2e12db8bb98d21e3410f3f27f8faab685a24b03b06ba7daa5b92abfc" ], "index": "pypi", "markers": "python_version >= '3.8'", - "version": "==0.24.0" + "version": "==0.25.2" }, "mkdocstrings-python": { "hashes": [ - "sha256:1488bddf50ee42c07d9a488dddc197f8e8999c2899687043ec5dd1643d057192", - "sha256:4209970cc90bec194568682a535848a8d8489516c6ed4adbe58bbc67b699ca9d" + "sha256:8999acb8e2cb6ae5edb844ce1ed6a5fcc14285f85cfd9df374d9a0f0be8a40b6", + "sha256:bfb5e29acfc69c9177d2b11c18d3127d16e553b8da9bb6d184e428d54795600b" ], "index": "pypi", "markers": "python_version >= '3.8'", - "version": "==1.8.0" + "version": "==1.10.7" }, "mypy-extensions": { "hashes": [ @@ -430,11 +445,11 @@ }, "packaging": { "hashes": [ - "sha256:048fb0e9405036518eaaf48a55953c750c11e1a1b68e0dd1a9d62ed0c092cfc5", - "sha256:8c491190033a9af7e1d931d0b5dacc2ef47509b34dd0de67ed209b5203fc88c7" + "sha256:026ed72c8ed3fcce5bf8950572258698927fd1dbda10a5e981cdf0ac37f4f002", + "sha256:5b8f2217dbdbd2f7f384c41c628544e6d52f2d0f53c6d0c3ea61aa5d1d7ff124" ], - "markers": "python_version >= '3.7'", - "version": "==23.2" + "markers": "python_version >= '3.8'", + "version": "==24.1" }, "paginate": { "hashes": [ @@ -452,102 +467,104 @@ }, "platformdirs": { "hashes": [ - "sha256:0614df2a2f37e1a662acbd8e2b25b92ccf8632929bc6d43467e17fe89c75e068", - "sha256:ef0cc731df711022c174543cb70a9b5bd22e5a9337c8624ef2c2ceb8ddad8768" + "sha256:2d7a1657e36a80ea911db832a8a6ece5ee53d8de21edd5cc5879af6530b1bfee", + "sha256:38b7b51f512eed9e84a22788b4bce1de17c0adb134d6becb09836e37d8654cd3" ], "markers": "python_version >= '3.8'", - "version": "==4.2.0" + "version": "==4.2.2" }, "pygments": { "hashes": [ - "sha256:b27c2826c47d0f3219f29554824c30c5e8945175d888647acd804ddd04af846c", - "sha256:da46cec9fd2de5be3a8a784f434e4c4ab670b4ff54d605c4c2717e9d49c4c367" + "sha256:786ff802f32e91311bff3889f6e9a86e81505fe99f2735bb6d60ae0c5004f199", + "sha256:b8e6aca0523f3ab76fee51799c488e38782ac06eafcf95e7ba832985c8e7b13a" ], - "markers": "python_version >= '3.7'", - "version": "==2.17.2" + "markers": "python_version >= '3.8'", + "version": "==2.18.0" }, "pygount": { "hashes": [ - "sha256:85b1d06d51398150fe6de3ec39feca867e95dc9c7a1a45f4dee731ab43177bcf", - "sha256:fac00c6bd61ab6d7633fe8724ae73943cde169de4f2a014244a488037a14d385" + "sha256:a1c530a8ff473c99dc7cd24b034f382d60f51efcac3a1d2181642124dbda2173", + "sha256:bb4e27ae3709674a91e349f503240ffeaef7efa59d1e026c7e4b2278dd3deb7f" ], "index": "pypi", - "markers": "python_version >= '3.8' and python_version < '4'", - "version": "==1.6.1" + "markers": "python_version < '3.13' and python_version >= '3.8'", + "version": "==1.8.0" }, "pymdown-extensions": { "hashes": [ - "sha256:6ca215bc57bc12bf32b414887a68b810637d039124ed9b2e5bd3325cbb2c050c", - "sha256:c0d64d5cf62566f59e6b2b690a4095c931107c250a8c8e1351c1de5f6b036deb" + "sha256:6ff740bcd99ec4172a938970d42b96128bdc9d4b9bcad72494f29921dc69b753", + "sha256:d323f7e90d83c86113ee78f3fe62fc9dee5f56b54d912660703ea1816fed5626" ], "markers": "python_version >= '3.8'", - "version": "==10.7" + "version": "==10.9" }, "python-dateutil": { "hashes": [ - "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86", - "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9" + "sha256:37dd54208da7e1cd875388217d5e00ebd4179249f90fb72437e91a35459a0ad3", + "sha256:a8b2bc7bffae282281c8140a97d3aa9c14da0b136dfe83f850eea9a5f7470427" ], "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'", - "version": "==2.8.2" + "version": "==2.9.0.post0" }, "pyyaml": { "hashes": [ - "sha256:04ac92ad1925b2cff1db0cfebffb6ffc43457495c9b3c39d3fcae417d7125dc5", - "sha256:062582fca9fabdd2c8b54a3ef1c978d786e0f6b3a1510e0ac93ef59e0ddae2bc", - "sha256:0d3304d8c0adc42be59c5f8a4d9e3d7379e6955ad754aa9d6ab7a398b59dd1df", - "sha256:1635fd110e8d85d55237ab316b5b011de701ea0f29d07611174a1b42f1444741", - "sha256:184c5108a2aca3c5b3d3bf9395d50893a7ab82a38004c8f61c258d4428e80206", - "sha256:18aeb1bf9a78867dc38b259769503436b7c72f7a1f1f4c93ff9a17de54319b27", - "sha256:1d4c7e777c441b20e32f52bd377e0c409713e8bb1386e1099c2415f26e479595", - "sha256:1e2722cc9fbb45d9b87631ac70924c11d3a401b2d7f410cc0e3bbf249f2dca62", - "sha256:1fe35611261b29bd1de0070f0b2f47cb6ff71fa6595c077e42bd0c419fa27b98", - "sha256:28c119d996beec18c05208a8bd78cbe4007878c6dd15091efb73a30e90539696", - "sha256:326c013efe8048858a6d312ddd31d56e468118ad4cdeda36c719bf5bb6192290", - "sha256:40df9b996c2b73138957fe23a16a4f0ba614f4c0efce1e9406a184b6d07fa3a9", - "sha256:42f8152b8dbc4fe7d96729ec2b99c7097d656dc1213a3229ca5383f973a5ed6d", - "sha256:49a183be227561de579b4a36efbb21b3eab9651dd81b1858589f796549873dd6", - "sha256:4fb147e7a67ef577a588a0e2c17b6db51dda102c71de36f8549b6816a96e1867", - "sha256:50550eb667afee136e9a77d6dc71ae76a44df8b3e51e41b77f6de2932bfe0f47", - "sha256:510c9deebc5c0225e8c96813043e62b680ba2f9c50a08d3724c7f28a747d1486", - "sha256:5773183b6446b2c99bb77e77595dd486303b4faab2b086e7b17bc6bef28865f6", - "sha256:596106435fa6ad000c2991a98fa58eeb8656ef2325d7e158344fb33864ed87e3", - "sha256:6965a7bc3cf88e5a1c3bd2e0b5c22f8d677dc88a455344035f03399034eb3007", - "sha256:69b023b2b4daa7548bcfbd4aa3da05b3a74b772db9e23b982788168117739938", - "sha256:6c22bec3fbe2524cde73d7ada88f6566758a8f7227bfbf93a408a9d86bcc12a0", - "sha256:704219a11b772aea0d8ecd7058d0082713c3562b4e271b849ad7dc4a5c90c13c", - "sha256:7e07cbde391ba96ab58e532ff4803f79c4129397514e1413a7dc761ccd755735", - "sha256:81e0b275a9ecc9c0c0c07b4b90ba548307583c125f54d5b6946cfee6360c733d", - "sha256:855fb52b0dc35af121542a76b9a84f8d1cd886ea97c84703eaa6d88e37a2ad28", - "sha256:8d4e9c88387b0f5c7d5f281e55304de64cf7f9c0021a3525bd3b1c542da3b0e4", - "sha256:9046c58c4395dff28dd494285c82ba00b546adfc7ef001486fbf0324bc174fba", - "sha256:9eb6caa9a297fc2c2fb8862bc5370d0303ddba53ba97e71f08023b6cd73d16a8", - "sha256:a08c6f0fe150303c1c6b71ebcd7213c2858041a7e01975da3a99aed1e7a378ef", - "sha256:a0cd17c15d3bb3fa06978b4e8958dcdc6e0174ccea823003a106c7d4d7899ac5", - "sha256:afd7e57eddb1a54f0f1a974bc4391af8bcce0b444685d936840f125cf046d5bd", - "sha256:b1275ad35a5d18c62a7220633c913e1b42d44b46ee12554e5fd39c70a243d6a3", - "sha256:b786eecbdf8499b9ca1d697215862083bd6d2a99965554781d0d8d1ad31e13a0", - "sha256:ba336e390cd8e4d1739f42dfe9bb83a3cc2e80f567d8805e11b46f4a943f5515", - "sha256:baa90d3f661d43131ca170712d903e6295d1f7a0f595074f151c0aed377c9b9c", - "sha256:bc1bf2925a1ecd43da378f4db9e4f799775d6367bdb94671027b73b393a7c42c", - "sha256:bd4af7373a854424dabd882decdc5579653d7868b8fb26dc7d0e99f823aa5924", - "sha256:bf07ee2fef7014951eeb99f56f39c9bb4af143d8aa3c21b1677805985307da34", - "sha256:bfdf460b1736c775f2ba9f6a92bca30bc2095067b8a9d77876d1fad6cc3b4a43", - "sha256:c8098ddcc2a85b61647b2590f825f3db38891662cfc2fc776415143f599bb859", - "sha256:d2b04aac4d386b172d5b9692e2d2da8de7bfb6c387fa4f801fbf6fb2e6ba4673", - "sha256:d483d2cdf104e7c9fa60c544d92981f12ad66a457afae824d146093b8c294c54", - "sha256:d858aa552c999bc8a8d57426ed01e40bef403cd8ccdd0fc5f6f04a00414cac2a", - "sha256:e7d73685e87afe9f3b36c799222440d6cf362062f78be1013661b00c5c6f678b", - "sha256:f003ed9ad21d6a4713f0a9b5a7a0a79e08dd0f221aff4525a2be4c346ee60aab", - "sha256:f22ac1c3cac4dbc50079e965eba2c1058622631e526bd9afd45fedd49ba781fa", - "sha256:faca3bdcf85b2fc05d06ff3fbc1f83e1391b3e724afa3feba7d13eeab355484c", - "sha256:fca0e3a251908a499833aa292323f32437106001d436eca0e6e7833256674585", - "sha256:fd1592b3fdf65fff2ad0004b5e363300ef59ced41c2e6b3a99d4089fa8c5435d", - "sha256:fd66fc5d0da6d9815ba2cebeb4205f95818ff4b79c3ebe268e75d961704af52f" + "sha256:0101357af42f5c9fc7e9acc5c5ab8c3049f50db7425de175b6c7a5959cb6023d", + "sha256:0ae563b7e3ed5e918cd0184060e28b48b7e672b975bf7c6f4a892cee9d886ada", + "sha256:0fe2c1c5401a3a98f06337fed48f57340cf652a685484834b44f5ceeadb772ba", + "sha256:1eb00dd3344da80264261ab126c95481824669ed9e5ecc82fb2d88b1fce668ee", + "sha256:2086b30215c433c1e480c08c1db8b43c1edd36c59cf43d36b424e6f35fcaf1ad", + "sha256:29b4a67915232f79506211e69943e3102e211c616181ceff0adf34e21b469357", + "sha256:2e9bc8a34797f0621f56160b961d47a088644370f79d34bedc934fb89e3f47dd", + "sha256:30ec6b9afc17353a9abcff109880edf6e8d5b924eb1eeed7fe9376febc1f9800", + "sha256:31573d7e161d2f905311f036b12e65c058389b474dbd35740f4880b91e2ca2be", + "sha256:36d7bf63558843ea2a81de9d0c3e9c56c353b1df8e6c1faaec86df5adedf2e02", + "sha256:3af6b36bc195d741cd5b511810246cad143b99c953b4591e679e194a820d7b7c", + "sha256:414629800a1ddccd7303471650843fc801801cc579a195d2fe617b5b455409e3", + "sha256:459113f2b9cd68881201a3bd1a858ece3281dc0e92ece6e917d23b128f0fcb31", + "sha256:46e4fae38d00b40a62d32d60f1baa1b9ef33aff28c2aafd96b05d5cc770f1583", + "sha256:4bf821ccd51e8d5bc1a4021b8bd85a92b498832ac1cd1a53b399f0eb7c1c4258", + "sha256:50bd6560a6df3de59336b9a9086cbdea5aa9eee5361661448ee45c21eeb0da68", + "sha256:53056b51f111223e603bed1db5367f54596d44cacfa50f07e082a11929612957", + "sha256:53c5f0749a93e3296078262c9acf632de246241ff2f22bbedfe49d4b55e9bbdd", + "sha256:54c754cee6937bb9b72d6a16163160dec80b93a43020ac6fc9f13729c030c30b", + "sha256:58cc18ccbade0c48fb55102aa971a5b4e571e2b22187d083dda33f8708fa4ee7", + "sha256:5921fd128fbf27ab7c7ad1a566d2cd9557b84ade130743a7c110a55e7dec3b3c", + "sha256:5c758cc29713c9166750a30156ca3d90ac2515d5dea3c874377ae8829cf03087", + "sha256:60bf91e73354c96754220a9c04a9502c2ad063231cd754b59f8e4511157e32e2", + "sha256:6f0f728a88c6eb58a3b762726b965bb6acf12d97f8ea2cb4fecf856a727f9bdc", + "sha256:6f31c5935310da69ea0efe996a962d488f080312f0eb43beff1717acb5fe9bed", + "sha256:728b447d0cedec409ea1a3f0ad1a6cc3cec0a8d086611b45f038a9230a2242f3", + "sha256:72ffbc5c0cc71877104387548a450f2b7b7c4926b40dc9443e7598fe92aa13d9", + "sha256:73d8b233309ecd45c33c51cd55aa1be1dcab1799a9e54f6c753d8cab054b8c34", + "sha256:765029d1cf96e9e761329ee1c20f1ca2de8644e7350a151b198260698b96e30f", + "sha256:7ee3d180d886a3bc50f753b76340f1c314f9e8c507f5b107212112214c3a66fd", + "sha256:826fb4d5ac2c48b9d6e71423def2669d4646c93b6c13612a71b3ac7bb345304b", + "sha256:84c39ceec517cd8f01cb144efb08904a32050be51c55b7a59bc7958c8091568d", + "sha256:88bfe675bb19ae12a9c77c52322a28a8e2a8d3d213fbcfcded5c3f5ca3ead352", + "sha256:8e0a1ebd5c5842595365bf90db3ef7e9a8d6a79c9aedb1d05b675c81c7267fd3", + "sha256:9426067a10b369474396bf57fdf895b899045a25d1848798844693780b147436", + "sha256:9c5c0de7ec50d4df88b62f4b019ab7b3bb2883c826a1044268e9afb344c57b17", + "sha256:ad0c172fe15beffc32e3a8260f18e6708eb0e15ae82c9b3f80fbe04de0ef5729", + "sha256:ad206c7f5f08d393b872d3399f597246fdc6ebebff09c5ae5268ac45aebf4f8d", + "sha256:b0a163f4f84d1e0fe6a07ccad3b02e9b243790b8370ff0408ae5932c50c4d96d", + "sha256:b0dd9c7497d60126445e79e542ff01351c6b6dc121299d89787f5685b382c626", + "sha256:b1de10c488d6f02e498eb6956b89081bea31abf3133223c17749e7137734da75", + "sha256:b408f36eeb4e2be6f802f1be82daf1b578f3de5a51917c6e467aedb46187d827", + "sha256:bae077a01367e4bf5fddf00fd6c8b743e676385911c7c615e29e1c45ace8813b", + "sha256:bc3c3600fec6c2a719106381d6282061d8c108369cdec58b6f280610eba41e09", + "sha256:c16522bf91daa4ea9dedc1243b56b5a226357ab98b3133089ca627ef99baae6f", + "sha256:ca5136a77e2d64b4cf5106fb940376650ae232c74c09a8ff29dbb1e262495b31", + "sha256:d6e0f7ee5f8d851b1d91149a3e5074dbf5aacbb63e4b771fcce16508339a856f", + "sha256:e7930a0612e74fcca37019ca851b50d73b5f0c3dab7f3085a7c15d2026118315", + "sha256:e8e6dd230a158a836cda3cc521fcbedea16f22b16b8cfa8054d0c6cea5d0a531", + "sha256:eee36bf4bc11e39e3f17c171f25cdedff3d7c73b148aedc8820257ce2aa56d3b", + "sha256:f07adc282d51aaa528f3141ac1922d16d32fe89413ee59bfb8a73ed689ad3d23", + "sha256:f09816c047fdb588dddba53d321f1cb8081e38ad2a40ea6a7560a88b7a2f0ea8", + "sha256:fea4c4310061cd70ef73b39801231b9dc3dc638bb8858e38364b144fbd335a1a" ], "index": "pypi", "markers": "python_version >= '3.6'", - "version": "==6.0.1" + "version": "==6.0.2rc1" }, "pyyaml-env-tag": { "hashes": [ @@ -559,152 +576,138 @@ }, "regex": { "hashes": [ - "sha256:0694219a1d54336fd0445ea382d49d36882415c0134ee1e8332afd1529f0baa5", - "sha256:086dd15e9435b393ae06f96ab69ab2d333f5d65cbe65ca5a3ef0ec9564dfe770", - "sha256:094ba386bb5c01e54e14434d4caabf6583334090865b23ef58e0424a6286d3dc", - "sha256:09da66917262d9481c719599116c7dc0c321ffcec4b1f510c4f8a066f8768105", - "sha256:0ecf44ddf9171cd7566ef1768047f6e66975788258b1c6c6ca78098b95cf9a3d", - "sha256:0fda75704357805eb953a3ee15a2b240694a9a514548cd49b3c5124b4e2ad01b", - "sha256:11a963f8e25ab5c61348d090bf1b07f1953929c13bd2309a0662e9ff680763c9", - "sha256:150c39f5b964e4d7dba46a7962a088fbc91f06e606f023ce57bb347a3b2d4630", - "sha256:1b9d811f72210fa9306aeb88385b8f8bcef0dfbf3873410413c00aa94c56c2b6", - "sha256:1e0eabac536b4cc7f57a5f3d095bfa557860ab912f25965e08fe1545e2ed8b4c", - "sha256:22a86d9fff2009302c440b9d799ef2fe322416d2d58fc124b926aa89365ec482", - "sha256:22f3470f7524b6da61e2020672df2f3063676aff444db1daa283c2ea4ed259d6", - "sha256:263ef5cc10979837f243950637fffb06e8daed7f1ac1e39d5910fd29929e489a", - "sha256:283fc8eed679758de38fe493b7d7d84a198b558942b03f017b1f94dda8efae80", - "sha256:29171aa128da69afdf4bde412d5bedc335f2ca8fcfe4489038577d05f16181e5", - "sha256:298dc6354d414bc921581be85695d18912bea163a8b23cac9a2562bbcd5088b1", - "sha256:2aae8101919e8aa05ecfe6322b278f41ce2994c4a430303c4cd163fef746e04f", - "sha256:2f4e475a80ecbd15896a976aa0b386c5525d0ed34d5c600b6d3ebac0a67c7ddf", - "sha256:34e4af5b27232f68042aa40a91c3b9bb4da0eeb31b7632e0091afc4310afe6cb", - "sha256:37f8e93a81fc5e5bd8db7e10e62dc64261bcd88f8d7e6640aaebe9bc180d9ce2", - "sha256:3a17d3ede18f9cedcbe23d2daa8a2cd6f59fe2bf082c567e43083bba3fb00347", - "sha256:3b1de218d5375cd6ac4b5493e0b9f3df2be331e86520f23382f216c137913d20", - "sha256:43f7cd5754d02a56ae4ebb91b33461dc67be8e3e0153f593c509e21d219c5060", - "sha256:4558410b7a5607a645e9804a3e9dd509af12fb72b9825b13791a37cd417d73a5", - "sha256:4719bb05094d7d8563a450cf8738d2e1061420f79cfcc1fa7f0a44744c4d8f73", - "sha256:4bfc2b16e3ba8850e0e262467275dd4d62f0d045e0e9eda2bc65078c0110a11f", - "sha256:518440c991f514331f4850a63560321f833979d145d7d81186dbe2f19e27ae3d", - "sha256:51f4b32f793812714fd5307222a7f77e739b9bc566dc94a18126aba3b92b98a3", - "sha256:531ac6cf22b53e0696f8e1d56ce2396311254eb806111ddd3922c9d937151dae", - "sha256:5cd05d0f57846d8ba4b71d9c00f6f37d6b97d5e5ef8b3c3840426a475c8f70f4", - "sha256:5dd58946bce44b53b06d94aa95560d0b243eb2fe64227cba50017a8d8b3cd3e2", - "sha256:60080bb3d8617d96f0fb7e19796384cc2467447ef1c491694850ebd3670bc457", - "sha256:636ba0a77de609d6510235b7f0e77ec494d2657108f777e8765efc060094c98c", - "sha256:67d3ccfc590e5e7197750fcb3a2915b416a53e2de847a728cfa60141054123d4", - "sha256:68191f80a9bad283432385961d9efe09d783bcd36ed35a60fb1ff3f1ec2efe87", - "sha256:7502534e55c7c36c0978c91ba6f61703faf7ce733715ca48f499d3dbbd7657e0", - "sha256:7aa47c2e9ea33a4a2a05f40fcd3ea36d73853a2aae7b4feab6fc85f8bf2c9704", - "sha256:7d2af3f6b8419661a0c421584cfe8aaec1c0e435ce7e47ee2a97e344b98f794f", - "sha256:7e316026cc1095f2a3e8cc012822c99f413b702eaa2ca5408a513609488cb62f", - "sha256:88ad44e220e22b63b0f8f81f007e8abbb92874d8ced66f32571ef8beb0643b2b", - "sha256:88d1f7bef20c721359d8675f7d9f8e414ec5003d8f642fdfd8087777ff7f94b5", - "sha256:89723d2112697feaa320c9d351e5f5e7b841e83f8b143dba8e2d2b5f04e10923", - "sha256:8a0ccf52bb37d1a700375a6b395bff5dd15c50acb745f7db30415bae3c2b0715", - "sha256:8c2c19dae8a3eb0ea45a8448356ed561be843b13cbc34b840922ddf565498c1c", - "sha256:905466ad1702ed4acfd67a902af50b8db1feeb9781436372261808df7a2a7bca", - "sha256:9852b76ab558e45b20bf1893b59af64a28bd3820b0c2efc80e0a70a4a3ea51c1", - "sha256:98a2636994f943b871786c9e82bfe7883ecdaba2ef5df54e1450fa9869d1f756", - "sha256:9aa1a67bbf0f957bbe096375887b2505f5d8ae16bf04488e8b0f334c36e31360", - "sha256:9eda5f7a50141291beda3edd00abc2d4a5b16c29c92daf8d5bd76934150f3edc", - "sha256:a6d1047952c0b8104a1d371f88f4ab62e6275567d4458c1e26e9627ad489b445", - "sha256:a9b6d73353f777630626f403b0652055ebfe8ff142a44ec2cf18ae470395766e", - "sha256:a9cc99d6946d750eb75827cb53c4371b8b0fe89c733a94b1573c9dd16ea6c9e4", - "sha256:ad83e7545b4ab69216cef4cc47e344d19622e28aabec61574b20257c65466d6a", - "sha256:b014333bd0217ad3d54c143de9d4b9a3ca1c5a29a6d0d554952ea071cff0f1f8", - "sha256:b43523d7bc2abd757119dbfb38af91b5735eea45537ec6ec3a5ec3f9562a1c53", - "sha256:b521dcecebc5b978b447f0f69b5b7f3840eac454862270406a39837ffae4e697", - "sha256:b77e27b79448e34c2c51c09836033056a0547aa360c45eeeb67803da7b0eedaf", - "sha256:b7a635871143661feccce3979e1727c4e094f2bdfd3ec4b90dfd4f16f571a87a", - "sha256:b7fca9205b59c1a3d5031f7e64ed627a1074730a51c2a80e97653e3e9fa0d415", - "sha256:ba1b30765a55acf15dce3f364e4928b80858fa8f979ad41f862358939bdd1f2f", - "sha256:ba99d8077424501b9616b43a2d208095746fb1284fc5ba490139651f971d39d9", - "sha256:c25a8ad70e716f96e13a637802813f65d8a6760ef48672aa3502f4c24ea8b400", - "sha256:c3c4a78615b7762740531c27cf46e2f388d8d727d0c0c739e72048beb26c8a9d", - "sha256:c40281f7d70baf6e0db0c2f7472b31609f5bc2748fe7275ea65a0b4601d9b392", - "sha256:c7ad32824b7f02bb3c9f80306d405a1d9b7bb89362d68b3c5a9be53836caebdb", - "sha256:cb3fe77aec8f1995611f966d0c656fdce398317f850d0e6e7aebdfe61f40e1cd", - "sha256:cc038b2d8b1470364b1888a98fd22d616fba2b6309c5b5f181ad4483e0017861", - "sha256:cc37b9aeebab425f11f27e5e9e6cf580be7206c6582a64467a14dda211abc232", - "sha256:cc6bb9aa69aacf0f6032c307da718f61a40cf970849e471254e0e91c56ffca95", - "sha256:d126361607b33c4eb7b36debc173bf25d7805847346dd4d99b5499e1fef52bc7", - "sha256:d15b274f9e15b1a0b7a45d2ac86d1f634d983ca40d6b886721626c47a400bf39", - "sha256:d166eafc19f4718df38887b2bbe1467a4f74a9830e8605089ea7a30dd4da8887", - "sha256:d498eea3f581fbe1b34b59c697512a8baef88212f92e4c7830fcc1499f5b45a5", - "sha256:d6f7e255e5fa94642a0724e35406e6cb7001c09d476ab5fce002f652b36d0c39", - "sha256:d78bd484930c1da2b9679290a41cdb25cc127d783768a0369d6b449e72f88beb", - "sha256:d865984b3f71f6d0af64d0d88f5733521698f6c16f445bb09ce746c92c97c586", - "sha256:d902a43085a308cef32c0d3aea962524b725403fd9373dea18110904003bac97", - "sha256:d94a1db462d5690ebf6ae86d11c5e420042b9898af5dcf278bd97d6bda065423", - "sha256:da695d75ac97cb1cd725adac136d25ca687da4536154cdc2815f576e4da11c69", - "sha256:db2a0b1857f18b11e3b0e54ddfefc96af46b0896fb678c85f63fb8c37518b3e7", - "sha256:df26481f0c7a3f8739fecb3e81bc9da3fcfae34d6c094563b9d4670b047312e1", - "sha256:e14b73607d6231f3cc4622809c196b540a6a44e903bcfad940779c80dffa7be7", - "sha256:e2610e9406d3b0073636a3a2e80db05a02f0c3169b5632022b4e81c0364bcda5", - "sha256:e692296c4cc2873967771345a876bcfc1c547e8dd695c6b89342488b0ea55cd8", - "sha256:e693e233ac92ba83a87024e1d32b5f9ab15ca55ddd916d878146f4e3406b5c91", - "sha256:e81469f7d01efed9b53740aedd26085f20d49da65f9c1f41e822a33992cb1590", - "sha256:e8c7e08bb566de4faaf11984af13f6bcf6a08f327b13631d41d62592681d24fe", - "sha256:ed19b3a05ae0c97dd8f75a5d8f21f7723a8c33bbc555da6bbe1f96c470139d3c", - "sha256:efb2d82f33b2212898f1659fb1c2e9ac30493ac41e4d53123da374c3b5541e64", - "sha256:f44dd4d68697559d007462b0a3a1d9acd61d97072b71f6d1968daef26bc744bd", - "sha256:f72cbae7f6b01591f90814250e636065850c5926751af02bb48da94dfced7baa", - "sha256:f7bc09bc9c29ebead055bcba136a67378f03d66bf359e87d0f7c759d6d4ffa31", - "sha256:ff100b203092af77d1a5a7abe085b3506b7eaaf9abf65b73b7d6905b6cb76988" + "sha256:01b689e887f612610c869421241e075c02f2e3d1ae93a037cb14f88ab6a8934c", + "sha256:04ce29e2c5fedf296b1a1b0acc1724ba93a36fb14031f3abfb7abda2806c1535", + "sha256:0ffe3f9d430cd37d8fa5632ff6fb36d5b24818c5c986893063b4e5bdb84cdf24", + "sha256:18300a1d78cf1290fa583cd8b7cde26ecb73e9f5916690cf9d42de569c89b1ce", + "sha256:185e029368d6f89f36e526764cf12bf8d6f0e3a2a7737da625a76f594bdfcbfc", + "sha256:19c65b00d42804e3fbea9708f0937d157e53429a39b7c61253ff15670ff62cb5", + "sha256:228b0d3f567fafa0633aee87f08b9276c7062da9616931382993c03808bb68ce", + "sha256:23acc72f0f4e1a9e6e9843d6328177ae3074b4182167e34119ec7233dfeccf53", + "sha256:25419b70ba00a16abc90ee5fce061228206173231f004437730b67ac77323f0d", + "sha256:2dfbb8baf8ba2c2b9aa2807f44ed272f0913eeeba002478c4577b8d29cde215c", + "sha256:2f1baff13cc2521bea83ab2528e7a80cbe0ebb2c6f0bfad15be7da3aed443908", + "sha256:33e2614a7ce627f0cdf2ad104797d1f68342d967de3695678c0cb84f530709f8", + "sha256:3426de3b91d1bc73249042742f45c2148803c111d1175b283270177fdf669024", + "sha256:382281306e3adaaa7b8b9ebbb3ffb43358a7bbf585fa93821300a418bb975281", + "sha256:3d974d24edb231446f708c455fd08f94c41c1ff4f04bcf06e5f36df5ef50b95a", + "sha256:3f3b6ca8eae6d6c75a6cff525c8530c60e909a71a15e1b731723233331de4169", + "sha256:3fac296f99283ac232d8125be932c5cd7644084a30748fda013028c815ba3364", + "sha256:416c0e4f56308f34cdb18c3f59849479dde5b19febdcd6e6fa4d04b6c31c9faa", + "sha256:438d9f0f4bc64e8dea78274caa5af971ceff0f8771e1a2333620969936ba10be", + "sha256:43affe33137fcd679bdae93fb25924979517e011f9dea99163f80b82eadc7e53", + "sha256:44fc61b99035fd9b3b9453f1713234e5a7c92a04f3577252b45feefe1b327759", + "sha256:45104baae8b9f67569f0f1dca5e1f1ed77a54ae1cd8b0b07aba89272710db61e", + "sha256:4fdd1384619f406ad9037fe6b6eaa3de2749e2e12084abc80169e8e075377d3b", + "sha256:538d30cd96ed7d1416d3956f94d54e426a8daf7c14527f6e0d6d425fcb4cca52", + "sha256:558a57cfc32adcf19d3f791f62b5ff564922942e389e3cfdb538a23d65a6b610", + "sha256:5eefee9bfe23f6df09ffb6dfb23809f4d74a78acef004aa904dc7c88b9944b05", + "sha256:64bd50cf16bcc54b274e20235bf8edbb64184a30e1e53873ff8d444e7ac656b2", + "sha256:65fd3d2e228cae024c411c5ccdffae4c315271eee4a8b839291f84f796b34eca", + "sha256:66b4c0731a5c81921e938dcf1a88e978264e26e6ac4ec96a4d21ae0354581ae0", + "sha256:68a8f8c046c6466ac61a36b65bb2395c74451df2ffb8458492ef49900efed293", + "sha256:6a1141a1dcc32904c47f6846b040275c6e5de0bf73f17d7a409035d55b76f289", + "sha256:6b9fc7e9cc983e75e2518496ba1afc524227c163e43d706688a6bb9eca41617e", + "sha256:6f51f9556785e5a203713f5efd9c085b4a45aecd2a42573e2b5041881b588d1f", + "sha256:7214477bf9bd195894cf24005b1e7b496f46833337b5dedb7b2a6e33f66d962c", + "sha256:731fcd76bbdbf225e2eb85b7c38da9633ad3073822f5ab32379381e8c3c12e94", + "sha256:74007a5b25b7a678459f06559504f1eec2f0f17bca218c9d56f6a0a12bfffdad", + "sha256:7a5486ca56c8869070a966321d5ab416ff0f83f30e0e2da1ab48815c8d165d46", + "sha256:7c479f5ae937ec9985ecaf42e2e10631551d909f203e31308c12d703922742f9", + "sha256:7df9ea48641da022c2a3c9c641650cd09f0cd15e8908bf931ad538f5ca7919c9", + "sha256:7e37e809b9303ec3a179085415cb5f418ecf65ec98cdfe34f6a078b46ef823ee", + "sha256:80c811cfcb5c331237d9bad3bea2c391114588cf4131707e84d9493064d267f9", + "sha256:836d3cc225b3e8a943d0b02633fb2f28a66e281290302a79df0e1eaa984ff7c1", + "sha256:84c312cdf839e8b579f504afcd7b65f35d60b6285d892b19adea16355e8343c9", + "sha256:86b17ba823ea76256b1885652e3a141a99a5c4422f4a869189db328321b73799", + "sha256:871e3ab2838fbcb4e0865a6e01233975df3a15e6fce93b6f99d75cacbd9862d1", + "sha256:88ecc3afd7e776967fa16c80f974cb79399ee8dc6c96423321d6f7d4b881c92b", + "sha256:8bc593dcce679206b60a538c302d03c29b18e3d862609317cb560e18b66d10cf", + "sha256:8fd5afd101dcf86a270d254364e0e8dddedebe6bd1ab9d5f732f274fa00499a5", + "sha256:945352286a541406f99b2655c973852da7911b3f4264e010218bbc1cc73168f2", + "sha256:973335b1624859cb0e52f96062a28aa18f3a5fc77a96e4a3d6d76e29811a0e6e", + "sha256:994448ee01864501912abf2bad9203bffc34158e80fe8bfb5b031f4f8e16da51", + "sha256:9cfd009eed1a46b27c14039ad5bbc5e71b6367c5b2e6d5f5da0ea91600817506", + "sha256:a2ec4419a3fe6cf8a4795752596dfe0adb4aea40d3683a132bae9c30b81e8d73", + "sha256:a4997716674d36a82eab3e86f8fa77080a5d8d96a389a61ea1d0e3a94a582cf7", + "sha256:a512eed9dfd4117110b1881ba9a59b31433caed0c4101b361f768e7bcbaf93c5", + "sha256:a82465ebbc9b1c5c50738536fdfa7cab639a261a99b469c9d4c7dcbb2b3f1e57", + "sha256:ae2757ace61bc4061b69af19e4689fa4416e1a04840f33b441034202b5cd02d4", + "sha256:b16582783f44fbca6fcf46f61347340c787d7530d88b4d590a397a47583f31dd", + "sha256:ba2537ef2163db9e6ccdbeb6f6424282ae4dea43177402152c67ef869cf3978b", + "sha256:bf7a89eef64b5455835f5ed30254ec19bf41f7541cd94f266ab7cbd463f00c41", + "sha256:c0abb5e4e8ce71a61d9446040c1e86d4e6d23f9097275c5bd49ed978755ff0fe", + "sha256:c414cbda77dbf13c3bc88b073a1a9f375c7b0cb5e115e15d4b73ec3a2fbc6f59", + "sha256:c51edc3541e11fbe83f0c4d9412ef6c79f664a3745fab261457e84465ec9d5a8", + "sha256:c5e69fd3eb0b409432b537fe3c6f44ac089c458ab6b78dcec14478422879ec5f", + "sha256:c918b7a1e26b4ab40409820ddccc5d49871a82329640f5005f73572d5eaa9b5e", + "sha256:c9bb87fdf2ab2370f21e4d5636e5317775e5d51ff32ebff2cf389f71b9b13750", + "sha256:ca5b2028c2f7af4e13fb9fc29b28d0ce767c38c7facdf64f6c2cd040413055f1", + "sha256:d0a07763776188b4db4c9c7fb1b8c494049f84659bb387b71c73bbc07f189e96", + "sha256:d33a0021893ede5969876052796165bab6006559ab845fd7b515a30abdd990dc", + "sha256:d55588cba7553f0b6ec33130bc3e114b355570b45785cebdc9daed8c637dd440", + "sha256:dac8e84fff5d27420f3c1e879ce9929108e873667ec87e0c8eeb413a5311adfe", + "sha256:eaef80eac3b4cfbdd6de53c6e108b4c534c21ae055d1dbea2de6b3b8ff3def38", + "sha256:eb462f0e346fcf41a901a126b50f8781e9a474d3927930f3490f38a6e73b6950", + "sha256:eb563dd3aea54c797adf513eeec819c4213d7dbfc311874eb4fd28d10f2ff0f2", + "sha256:f273674b445bcb6e4409bf8d1be67bc4b58e8b46fd0d560055d515b8830063cd", + "sha256:f6442f0f0ff81775eaa5b05af8a0ffa1dda36e9cf6ec1e0d3d245e8564b684ce", + "sha256:fb168b5924bef397b5ba13aabd8cf5df7d3d93f10218d7b925e360d436863f66", + "sha256:fbf8c2f00904eaf63ff37718eb13acf8e178cb940520e47b2f05027f5bb34ce3", + "sha256:fe4ebef608553aff8deb845c7f4f1d0740ff76fa672c011cc0bacb2a00fbde86" ], - "markers": "python_version >= '3.7'", - "version": "==2023.12.25" + "markers": "python_version >= '3.8'", + "version": "==2024.7.24" }, "requests": { "hashes": [ - "sha256:58cd2187c01e70e6e26505bca751777aa9f2ee0b7f4300988b709f44e013003f", - "sha256:942c5a758f98d790eaed1a29cb6eefc7ffb0d1cf7af05c3d2791656dbd6ad1e1" + "sha256:55365417734eb18255590a9ff9eb97e9e1da868d4ccd6402399eaf68af20a760", + "sha256:70761cfe03c773ceb22aa2f671b4757976145175cdfca038c02654d061d6dcc6" ], "index": "pypi", - "markers": "python_version >= '3.7'", - "version": "==2.31.0" + "markers": "python_version >= '3.8'", + "version": "==2.32.3" }, "rich": { "hashes": [ - "sha256:2b38e2fe9ca72c9a00170a1a2d20c63c790d0e10ef1fe35eba76e1e7b1d7d245", - "sha256:5c14d22737e6d5084ef4771b62d5d4363165b403455a30a1c8ca39dc7b644bef" + "sha256:4edbae314f59eb482f54e9e30bf00d33350aaa94f4bfcd4e9e3110e64d0d7222", + "sha256:9be308cb1fe2f1f57d67ce99e95af38a1e2bc71ad9813b0e247cf7ffbcc3a432" ], "markers": "python_full_version >= '3.7.0'", - "version": "==13.6.0" + "version": "==13.7.1" }, "ruff": { "hashes": [ - "sha256:0034d5b6323e6e8fe91b2a1e55b02d92d0b582d2953a2b37a67a2d7dedbb7acc", - "sha256:00a818e2db63659570403e44383ab03c529c2b9678ba4ba6c105af7854008105", - "sha256:0a725823cb2a3f08ee743a534cb6935727d9e47409e4ad72c10a3faf042ad5ba", - "sha256:13471684694d41ae0f1e8e3a7497e14cd57ccb7dd72ae08d56a159d6c9c3e30e", - "sha256:3b42b5d8677cd0c72b99fcaf068ffc62abb5a19e71b4a3b9cfa50658a0af02f1", - "sha256:6b95ac9ce49b4fb390634d46d6ece32ace3acdd52814671ccaf20b7f60adb232", - "sha256:7022d66366d6fded4ba3889f73cd791c2d5621b2ccf34befc752cb0df70f5fad", - "sha256:a11567e20ea39d1f51aebd778685582d4c56ccb082c1161ffc10f79bebe6df35", - "sha256:be60592f9d218b52f03384d1325efa9d3b41e4c4d55ea022cd548547cc42cd2b", - "sha256:c92db7101ef5bfc18e96777ed7bc7c822d545fa5977e90a585accac43d22f18a", - "sha256:dc586724a95b7d980aa17f671e173df00f0a2eef23f8babbeee663229a938fec", - "sha256:dd81b911d28925e7e8b323e8d06951554655021df8dd4ac3045d7212ac4ba080", - "sha256:e3affdcbc2afb6f5bd0eb3130139ceedc5e3f28d206fe49f63073cb9e65988e0", - "sha256:e5cb5526d69bb9143c2e4d2a115d08ffca3d8e0fddc84925a7b54931c96f5c02", - "sha256:efababa8e12330aa94a53e90a81eb6e2d55f348bc2e71adbf17d9cad23c03ee6", - "sha256:f3ef052283da7dec1987bba8d8733051c2325654641dfe5877a4022108098683", - "sha256:fbd2288890b88e8aab4499e55148805b58ec711053588cc2f0196a44f6e3d855" + "sha256:07fc80bbb61e42b3b23b10fda6a2a0f5a067f810180a3760c5ef1b456c21b9db", + "sha256:10f2204b9a613988e3484194c2c9e96a22079206b22b787605c255f130db5ed7", + "sha256:10f973d521d910e5f9c72ab27e409e839089f955be8a4c8826601a6323a89753", + "sha256:13a1768b0691619822ae6d446132dbdfd568b700ecd3652b20d4e8bc1e498f78", + "sha256:2331d2b051dc77a289a653fcc6a42cce357087c5975738157cd966590b18b5e1", + "sha256:50e9651578b629baec3d1513b2534de0ac7ed7753e1382272b8d609997e27e83", + "sha256:59c3d110970001dfa494bcd95478e62286c751126dfb15c3c46e7915fc49694f", + "sha256:769e5a51df61e07e887b81e6f039e7ed3573316ab7dd9f635c5afaa310e4030e", + "sha256:8874a9df7766cb956b218a0a239e0a5d23d9e843e4da1e113ae1d27ee420877a", + "sha256:9e3ab684ad403a9ed1226894c32c3ab9c2e0718440f6f50c7c5829932bc9e054", + "sha256:a7c0083febdec17571455903b184a10026603a1de078428ba155e7ce9358c5f6", + "sha256:ad1b20e66a44057c326168437d680a2166c177c939346b19c0d6b08a62a37589", + "sha256:b9de9a6e49f7d529decd09381c0860c3f82fa0b0ea00ea78409b785d2308a567", + "sha256:cbf5d818553add7511c38b05532d94a407f499d1a76ebb0cad0374e32bc67202", + "sha256:e089371c67892a73b6bb1525608e89a2aca1b77b5440acf7a71dda5dac958f9e", + "sha256:fa4dafe3fe66d90e2e2b63fa1591dd6e3f090ca2128daa0be33db894e6c18648", + "sha256:fa9773c6c00f4958f73b317bc0fd125295110c3776089f6ef318f4b775f0abe4" ], "index": "pypi", "markers": "python_version >= '3.7'", - "version": "==0.2.1" + "version": "==0.4.7" }, "setuptools": { "hashes": [ - "sha256:385eb4edd9c9d5c17540511303e39a147ce2fc04bc55289c322b9e5904fe2c05", - "sha256:be1af57fc409f93647f2e8e4573a142ed38724b8cdd389706a867bb4efcf1e78" + "sha256:5a03e1860cf56bb6ef48ce186b0e557fdba433237481a9a625176c2831be15d1", + "sha256:8d243eff56d095e5817f796ede6ae32941278f542e0f941867cc05ae52b162ec" ], "index": "pypi", "markers": "python_version >= '3.8'", - "version": "==69.0.3" + "version": "==72.1.0" }, "six": { "hashes": [ @@ -732,64 +735,67 @@ }, "typing-extensions": { "hashes": [ - "sha256:23478f88c37f27d76ac8aee6c905017a143b0b1b886c3c9f66bc2fd94f9f5783", - "sha256:af72aea155e91adfc61c3ae9e0e342dbc0cba726d6cba4b6c72c1f34e47291cd" + "sha256:04e5ca0351e0f3f85c6853954072df659d0d13fac324d0072316b67d7794700d", + "sha256:1a7ead55c7e559dd4dee8856e3a88b41225abfe1ce8df57b7c13915fe121ffb8" ], "markers": "python_version < '3.11'", - "version": "==4.9.0" + "version": "==4.12.2" }, "urllib3": { "hashes": [ - "sha256:051d961ad0c62a94e50ecf1af379c3aba230c66c710493493560c0c223c49f20", - "sha256:ce3711610ddce217e6d113a2732fafad960a03fd0318c91faa79481e35c11224" + "sha256:a448b2f64d686155468037e1ace9f2d2199776e17f0a46610480d311f73e3472", + "sha256:dd505485549a7a552833da5e6063639d0d177c04f23bc3864e41e5dc5f612168" ], "markers": "python_version >= '3.8'", - "version": "==2.2.0" + "version": "==2.2.2" }, "watchdog": { "hashes": [ - "sha256:11e12fafb13372e18ca1bbf12d50f593e7280646687463dd47730fd4f4d5d257", - "sha256:2895bf0518361a9728773083908801a376743bcc37dfa252b801af8fd281b1ca", - "sha256:39cb34b1f1afbf23e9562501673e7146777efe95da24fab5707b88f7fb11649b", - "sha256:45cc09cc4c3b43fb10b59ef4d07318d9a3ecdbff03abd2e36e77b6dd9f9a5c85", - "sha256:4986db5e8880b0e6b7cd52ba36255d4793bf5cdc95bd6264806c233173b1ec0b", - "sha256:5369136a6474678e02426bd984466343924d1df8e2fd94a9b443cb7e3aa20d19", - "sha256:557ba04c816d23ce98a06e70af6abaa0485f6d94994ec78a42b05d1c03dcbd50", - "sha256:6a4db54edea37d1058b08947c789a2354ee02972ed5d1e0dca9b0b820f4c7f92", - "sha256:6a80d5cae8c265842c7419c560b9961561556c4361b297b4c431903f8c33b269", - "sha256:6a9c71a0b02985b4b0b6d14b875a6c86ddea2fdbebd0c9a720a806a8bbffc69f", - "sha256:6c47bdd680009b11c9ac382163e05ca43baf4127954c5f6d0250e7d772d2b80c", - "sha256:6e949a8a94186bced05b6508faa61b7adacc911115664ccb1923b9ad1f1ccf7b", - "sha256:73c7a935e62033bd5e8f0da33a4dcb763da2361921a69a5a95aaf6c93aa03a87", - "sha256:76ad8484379695f3fe46228962017a7e1337e9acadafed67eb20aabb175df98b", - "sha256:8350d4055505412a426b6ad8c521bc7d367d1637a762c70fdd93a3a0d595990b", - "sha256:87e9df830022488e235dd601478c15ad73a0389628588ba0b028cb74eb72fed8", - "sha256:8f9a542c979df62098ae9c58b19e03ad3df1c9d8c6895d96c0d51da17b243b1c", - "sha256:8fec441f5adcf81dd240a5fe78e3d83767999771630b5ddfc5867827a34fa3d3", - "sha256:9a03e16e55465177d416699331b0f3564138f1807ecc5f2de9d55d8f188d08c7", - "sha256:ba30a896166f0fee83183cec913298151b73164160d965af2e93a20bbd2ab605", - "sha256:c17d98799f32e3f55f181f19dd2021d762eb38fdd381b4a748b9f5a36738e935", - "sha256:c522392acc5e962bcac3b22b9592493ffd06d1fc5d755954e6be9f4990de932b", - "sha256:d0f9bd1fd919134d459d8abf954f63886745f4660ef66480b9d753a7c9d40927", - "sha256:d18d7f18a47de6863cd480734613502904611730f8def45fc52a5d97503e5101", - "sha256:d31481ccf4694a8416b681544c23bd271f5a123162ab603c7d7d2dd7dd901a07", - "sha256:e3e7065cbdabe6183ab82199d7a4f6b3ba0a438c5a512a68559846ccb76a78ec", - "sha256:eed82cdf79cd7f0232e2fdc1ad05b06a5e102a43e331f7d041e5f0e0a34a51c4", - "sha256:f970663fa4f7e80401a7b0cbeec00fa801bf0287d93d48368fc3e6fa32716245", - "sha256:f9b2fdca47dc855516b2d66eef3c39f2672cbf7e7a42e7e67ad2cbfcd6ba107d" + "sha256:0144c0ea9997b92615af1d94afc0c217e07ce2c14912c7b1a5731776329fcfc7", + "sha256:03e70d2df2258fb6cb0e95bbdbe06c16e608af94a3ffbd2b90c3f1e83eb10767", + "sha256:093b23e6906a8b97051191a4a0c73a77ecc958121d42346274c6af6520dec175", + "sha256:123587af84260c991dc5f62a6e7ef3d1c57dfddc99faacee508c71d287248459", + "sha256:17e32f147d8bf9657e0922c0940bcde863b894cd871dbb694beb6704cfbd2fb5", + "sha256:206afc3d964f9a233e6ad34618ec60b9837d0582b500b63687e34011e15bb429", + "sha256:4107ac5ab936a63952dea2a46a734a23230aa2f6f9db1291bf171dac3ebd53c6", + "sha256:4513ec234c68b14d4161440e07f995f231be21a09329051e67a2118a7a612d2d", + "sha256:611be3904f9843f0529c35a3ff3fd617449463cb4b73b1633950b3d97fa4bfb7", + "sha256:62c613ad689ddcb11707f030e722fa929f322ef7e4f18f5335d2b73c61a85c28", + "sha256:667f3c579e813fcbad1b784db7a1aaa96524bed53437e119f6a2f5de4db04235", + "sha256:6e8c70d2cd745daec2a08734d9f63092b793ad97612470a0ee4cbb8f5f705c57", + "sha256:7577b3c43e5909623149f76b099ac49a1a01ca4e167d1785c76eb52fa585745a", + "sha256:998d2be6976a0ee3a81fb8e2777900c28641fb5bfbd0c84717d89bca0addcdc5", + "sha256:a3c2c317a8fb53e5b3d25790553796105501a235343f5d2bf23bb8649c2c8709", + "sha256:ab998f567ebdf6b1da7dc1e5accfaa7c6992244629c0fdaef062f43249bd8dee", + "sha256:ac7041b385f04c047fcc2951dc001671dee1b7e0615cde772e84b01fbf68ee84", + "sha256:bca36be5707e81b9e6ce3208d92d95540d4ca244c006b61511753583c81c70dd", + "sha256:c9904904b6564d4ee8a1ed820db76185a3c96e05560c776c79a6ce5ab71888ba", + "sha256:cad0bbd66cd59fc474b4a4376bc5ac3fc698723510cbb64091c2a793b18654db", + "sha256:d10a681c9a1d5a77e75c48a3b8e1a9f2ae2928eda463e8d33660437705659682", + "sha256:d4925e4bf7b9bddd1c3de13c9b8a2cdb89a468f640e66fbfabaf735bd85b3e35", + "sha256:d7b9f5f3299e8dd230880b6c55504a1f69cf1e4316275d1b215ebdd8187ec88d", + "sha256:da2dfdaa8006eb6a71051795856bedd97e5b03e57da96f98e375682c48850645", + "sha256:dddba7ca1c807045323b6af4ff80f5ddc4d654c8bce8317dde1bd96b128ed253", + "sha256:e7921319fe4430b11278d924ef66d4daa469fafb1da679a2e48c935fa27af193", + "sha256:e93f451f2dfa433d97765ca2634628b789b49ba8b504fdde5837cdcf25fdb53b", + "sha256:eebaacf674fa25511e8867028d281e602ee6500045b57f43b08778082f7f8b44", + "sha256:ef0107bbb6a55f5be727cfc2ef945d5676b97bffb8425650dadbb184be9f9a2b", + "sha256:f0de0f284248ab40188f23380b03b59126d1479cd59940f2a34f8852db710625", + "sha256:f27279d060e2ab24c0aa98363ff906d2386aa6c4dc2f1a374655d4e02a6c5e5e", + "sha256:f8affdf3c0f0466e69f5b3917cdd042f89c8c63aebdb9f7c078996f607cdb0f5" ], "markers": "python_version >= '3.8'", - "version": "==4.0.0" + "version": "==4.0.1" } }, "develop": { "astroid": { "hashes": [ - "sha256:4a61cf0a59097c7bb52689b0fd63717cd2a8a14dc9f1eee97b82d814881c8c91", - "sha256:d6e62862355f60e716164082d6b4b041d38e2a8cf1c7cd953ded5108bac8ff5c" + "sha256:951798f922990137ac090c53af473db7ab4e70c770e6d7fae0cec59f74411819", + "sha256:ac248253bfa4bd924a0de213707e7ebeeb3138abeb48d798784ead1e56d419d4" ], "markers": "python_full_version >= '3.8.0'", - "version": "==3.0.2" + "version": "==3.1.0" }, "black": { "hashes": [ @@ -834,11 +840,11 @@ }, "dill": { "hashes": [ - "sha256:76b122c08ef4ce2eedcd4d1abd8e641114bfc6c2867f49f3c41facf65bf19f5e", - "sha256:cc1c8b182eb3013e24bd475ff2e9295af86c1a38eb1aff128dac8962a9ce3c03" + "sha256:3ebe3c479ad625c4553aca177444d89b486b1d84982eeacded644afc0cf797ca", + "sha256:c36ca9ffb54365bdd2f8eb3eff7d2a21237f8452b57ace88b1ac615b7e815bd7" ], "markers": "python_version < '3.11'", - "version": "==0.3.7" + "version": "==0.3.8" }, "isort": { "hashes": [ @@ -900,37 +906,37 @@ }, "mypy": { "hashes": [ - "sha256:028cf9f2cae89e202d7b6593cd98db6759379f17a319b5faf4f9978d7084cdc6", - "sha256:2afecd6354bbfb6e0160f4e4ad9ba6e4e003b767dd80d85516e71f2e955ab50d", - "sha256:2b5b6c721bd4aabaadead3a5e6fa85c11c6c795e0c81a7215776ef8afc66de02", - "sha256:42419861b43e6962a649068a61f4a4839205a3ef525b858377a960b9e2de6e0d", - "sha256:42c6680d256ab35637ef88891c6bd02514ccb7e1122133ac96055ff458f93fc3", - "sha256:485a8942f671120f76afffff70f259e1cd0f0cfe08f81c05d8816d958d4577d3", - "sha256:4c886c6cce2d070bd7df4ec4a05a13ee20c0aa60cb587e8d1265b6c03cf91da3", - "sha256:4e6d97288757e1ddba10dd9549ac27982e3e74a49d8d0179fc14d4365c7add66", - "sha256:4ef4be7baf08a203170f29e89d79064463b7fc7a0908b9d0d5114e8009c3a259", - "sha256:51720c776d148bad2372ca21ca29256ed483aa9a4cdefefcef49006dff2a6835", - "sha256:52825b01f5c4c1c4eb0db253ec09c7aa17e1a7304d247c48b6f3599ef40db8bd", - "sha256:538fd81bb5e430cc1381a443971c0475582ff9f434c16cd46d2c66763ce85d9d", - "sha256:5c1538c38584029352878a0466f03a8ee7547d7bd9f641f57a0f3017a7c905b8", - "sha256:6ff8b244d7085a0b425b56d327b480c3b29cafbd2eff27316a004f9a7391ae07", - "sha256:7178def594014aa6c35a8ff411cf37d682f428b3b5617ca79029d8ae72f5402b", - "sha256:720a5ca70e136b675af3af63db533c1c8c9181314d207568bbe79051f122669e", - "sha256:7f1478736fcebb90f97e40aff11a5f253af890c845ee0c850fe80aa060a267c6", - "sha256:855fe27b80375e5c5878492f0729540db47b186509c98dae341254c8f45f42ae", - "sha256:8963b83d53ee733a6e4196954502b33567ad07dfd74851f32be18eb932fb1cb9", - "sha256:9261ed810972061388918c83c3f5cd46079d875026ba97380f3e3978a72f503d", - "sha256:99b00bc72855812a60d253420d8a2eae839b0afa4938f09f4d2aa9bb4654263a", - "sha256:ab3c84fa13c04aeeeabb2a7f67a25ef5d77ac9d6486ff33ded762ef353aa5592", - "sha256:afe3fe972c645b4632c563d3f3eff1cdca2fa058f730df2b93a35e3b0c538218", - "sha256:d19c413b3c07cbecf1f991e2221746b0d2a9410b59cb3f4fb9557f0365a1a817", - "sha256:df9824ac11deaf007443e7ed2a4a26bebff98d2bc43c6da21b2b64185da011c4", - "sha256:e46f44b54ebddbeedbd3d5b289a893219065ef805d95094d16a0af6630f5d410", - "sha256:f5ac9a4eeb1ec0f1ccdc6f326bcdb464de5f80eb07fb38b5ddd7b0de6bc61e55" + "sha256:0624bdb940255d2dd24e829d99a13cfeb72e4e9031f9492148f410ed30bcab54", + "sha256:0bc71d1fb27a428139dd78621953effe0d208aed9857cb08d002280b0422003a", + "sha256:0bd53faf56de9643336aeea1c925012837432b5faf1701ccca7fde70166ccf72", + "sha256:11965c2f571ded6239977b14deebd3f4c3abd9a92398712d6da3a772974fad69", + "sha256:1a81cf05975fd61aec5ae16501a091cfb9f605dc3e3c878c0da32f250b74760b", + "sha256:2684d3f693073ab89d76da8e3921883019ea8a3ec20fa5d8ecca6a2db4c54bbe", + "sha256:2c63350af88f43a66d3dfeeeb8d77af34a4f07d760b9eb3a8697f0386c7590b4", + "sha256:45df906e8b6804ef4b666af29a87ad9f5921aad091c79cc38e12198e220beabd", + "sha256:4c956b49c5d865394d62941b109728c5c596a415e9c5b2be663dd26a1ff07bc0", + "sha256:64f4a90e3ea07f590c5bcf9029035cf0efeae5ba8be511a8caada1a4893f5525", + "sha256:749fd3213916f1751fff995fccf20c6195cae941dc968f3aaadf9bb4e430e5a2", + "sha256:79c07eb282cb457473add5052b63925e5cc97dfab9812ee65a7c7ab5e3cb551c", + "sha256:7b6343d338390bb946d449677726edf60102a1c96079b4f002dedff375953fc5", + "sha256:886c9dbecc87b9516eff294541bf7f3655722bf22bb898ee06985cd7269898de", + "sha256:a2b43895a0f8154df6519706d9bca8280cda52d3d9d1514b2d9c3e26792a0b74", + "sha256:a32fc80b63de4b5b3e65f4be82b4cfa362a46702672aa6a0f443b4689af7008c", + "sha256:a707ec1527ffcdd1c784d0924bf5cb15cd7f22683b919668a04d2b9c34549d2e", + "sha256:a831671bad47186603872a3abc19634f3011d7f83b083762c942442d51c58d58", + "sha256:b639dce63a0b19085213ec5fdd8cffd1d81988f47a2dec7100e93564f3e8fb3b", + "sha256:b868d3bcff720dd7217c383474008ddabaf048fad8d78ed948bb4b624870a417", + "sha256:c1952f5ea8a5a959b05ed5f16452fddadbaae48b5d39235ab4c3fc444d5fd411", + "sha256:d44be7551689d9d47b7abc27c71257adfdb53f03880841a5db15ddb22dc63edb", + "sha256:e1e30dc3bfa4e157e53c1d17a0dad20f89dc433393e7702b813c10e200843b03", + "sha256:e4fe9f4e5e521b458d8feb52547f4bade7ef8c93238dfb5bbc790d9ff2d770ca", + "sha256:f39918a50f74dc5969807dcfaecafa804fa7f90c9d60506835036cc1bc891dc8", + "sha256:f404a0b069709f18bbdb702eb3dcfe51910602995de00bd39cea3050b5772d08", + "sha256:fca4a60e1dd9fd0193ae0067eaeeb962f2d79e0d9f0f66223a0682f26ffcc809" ], "index": "pypi", "markers": "python_version >= '3.8'", - "version": "==1.8.0" + "version": "==1.11.1" }, "mypy-extensions": { "hashes": [ @@ -958,20 +964,20 @@ }, "platformdirs": { "hashes": [ - "sha256:11c8f37bcca40db96d8144522d925583bdb7a31f7b0e37e3ed4318400a8e2380", - "sha256:906d548203468492d432bcb294d4bc2fff751bf84971fbb2c10918cc206ee420" + "sha256:0614df2a2f37e1a662acbd8e2b25b92ccf8632929bc6d43467e17fe89c75e068", + "sha256:ef0cc731df711022c174543cb70a9b5bd22e5a9337c8624ef2c2ceb8ddad8768" ], "markers": "python_version >= '3.8'", - "version": "==4.1.0" + "version": "==4.2.0" }, "pylint": { "hashes": [ - "sha256:58c2398b0301e049609a8429789ec6edf3aabe9b6c5fec916acd18639c16de8b", - "sha256:7a1585285aefc5165db81083c3e06363a27448f6b467b3b0f30dbd0ac1f73810" + "sha256:507a5b60953874766d8a366e8e8c7af63e058b26345cfcb5f91f89d987fd6b74", + "sha256:6a69beb4a6f63debebaab0a3477ecd0f559aa726af4954fc948c51f7a2549e23" ], "index": "pypi", "markers": "python_full_version >= '3.8.0'", - "version": "==3.0.3" + "version": "==3.1.0" }, "tomli": { "hashes": [ @@ -983,19 +989,19 @@ }, "tomlkit": { "hashes": [ - "sha256:75baf5012d06501f07bee5bf8e801b9f343e7aac5a92581f20f80ce632e6b5a4", - "sha256:b0a645a9156dc7cb5d3a1f0d4bab66db287fcb8e0430bdd4664a095ea16414ba" + "sha256:5cd82d48a3dd89dee1f9d64420aa20ae65cfbd00668d6f094d7578a78efbb77b", + "sha256:7ca1cfc12232806517a8515047ba66a19369e71edf2439d0f5824f91032b6cc3" ], "markers": "python_version >= '3.7'", - "version": "==0.12.3" + "version": "==0.12.4" }, "typing-extensions": { "hashes": [ - "sha256:23478f88c37f27d76ac8aee6c905017a143b0b1b886c3c9f66bc2fd94f9f5783", - "sha256:af72aea155e91adfc61c3ae9e0e342dbc0cba726d6cba4b6c72c1f34e47291cd" + "sha256:04e5ca0351e0f3f85c6853954072df659d0d13fac324d0072316b67d7794700d", + "sha256:1a7ead55c7e559dd4dee8856e3a88b41225abfe1ce8df57b7c13915fe121ffb8" ], "markers": "python_version >= '3.8'", - "version": "==4.9.0" + "version": "==4.12.2" }, "wrapt": { "hashes": [ diff --git a/README.md b/README.md index 733ac86ce..72204642b 100644 --- a/README.md +++ b/README.md @@ -2,9 +2,9 @@   -[![GitHub issues](https://img.shields.io/github/issues/eirannejad/pyRevit.svg?style=for-the-badge)](https://github.com/eirannejad/pyRevit/issues) -[![GitHub forks](https://img.shields.io/github/forks/eirannejad/pyRevit.svg?style=for-the-badge)](https://github.com/eirannejad/pyRevit/network) -[![GitHub stars](https://img.shields.io/github/stars/eirannejad/pyRevit.svg?style=for-the-badge&colorB=red)](https://github.com/eirannejad/pyRevit/stargazers) +[![GitHub issues](https://img.shields.io/github/issues/pyrevitlabs/pyRevit.svg?style=for-the-badge)](https://github.com/pyrevitlabs/pyRevit/issues) +[![GitHub forks](https://img.shields.io/github/forks/pyrevitlabs/pyRevit.svg?style=for-the-badge)](https://github.com/pyrevitlabs/pyRevit/network) +[![GitHub stars](https://img.shields.io/github/stars/pyrevitlabs/pyRevit.svg?style=for-the-badge&colorB=red)](https://github.com/pyrevitlabs/pyRevit/stargazers) [![License: GPL v3](https://img.shields.io/badge/License-GPL%20v3-blue.svg?style=for-the-badge)](http://www.gnu.org/licenses/gpl-3.0) [![made with love in portland](https://img.shields.io/badge/%3C%2F%3E%20with%20%3C3-Portland%2C%20OR-green.svg?style=for-the-badge)](https://en.wikipedia.org/wiki/Portland,_Oregon) @@ -48,7 +48,7 @@ pyRevit helps you quickly sketch out your automation and addon ideas, in whichev **↓** Read the pyRevit API reference to know everything about pyRevit available modules, functions, ... -[pyRevit API Reference](https://ein.sh/pyRevit/reference/pyrevit/) +[pyRevit API Reference](https://pyrevitlabs.github.io/pyRevit/reference/pyrevit/) **↓** Read the docs to know everything about pyRevit scripts, extensions, ... @@ -67,7 +67,7 @@ pyRevit helps you quickly sketch out your automation and addon ideas, in whichev # Staying Updated -Follow [pyRevit on Twitter](https://twitter.com/pyrevit) to stay notified about the upcoming changes and follow [pyRevit Release Notes](https://github.com/eirannejad/pyRevit/releases) for the breaking changes +Follow [pyRevit on Twitter](https://twitter.com/pyrevit) to stay notified about the upcoming changes and follow [pyRevit Release Notes](https://github.com/pyrevitlabs/pyRevit/releases) for the breaking changes **↓** Check out the blog for news @@ -81,7 +81,7 @@ Follow [pyRevit on Twitter](https://twitter.com/pyrevit) to stay notified about # Dealing with Issues -Check the list of [Currently Open](https://github.com/eirannejad/pyRevit/issues) and [Previously Reported Issues](https://github.com/eirannejad/pyRevit/issues?q=is%3Aissue+is%3Aclosed) for anything similar to yours. +Check the list of [Currently Open](https://github.com/pyrevitlabs/pyRevit/issues) and [Previously Reported Issues](https://github.com/pyrevitlabs/pyRevit/issues?q=is%3Aissue+is%3Aclosed) for anything similar to yours. **↓** See the FAQ page for questions @@ -127,6 +127,8 @@ Check the list of [Currently Open](https://github.com/eirannejad/pyRevit/issues) **↓** Help making pyRevit financially stronger +[Support on OpenCollective](https://opencollective.com/pyrevitlabs) + [Support on Patreon](https://www.notion.so/Support-on-Patreon-cdf92ba547154f7a85d32b526dc5e59b) [Supporters](https://www.notion.so/Supporters-4f3350243ba24dcd8228df6262723629) @@ -135,8 +137,8 @@ Check the list of [Currently Open](https://github.com/eirannejad/pyRevit/issues) Made with [contrib.rocks](https://contrib.rocks) - - + +   --- diff --git a/bin/cengines/CPY3123/LICENSE.txt b/bin/cengines/CPY3123/LICENSE.txt new file mode 100644 index 000000000..7a0193a1a --- /dev/null +++ b/bin/cengines/CPY3123/LICENSE.txt @@ -0,0 +1,702 @@ +A. HISTORY OF THE SOFTWARE +========================== + +Python was created in the early 1990s by Guido van Rossum at Stichting +Mathematisch Centrum (CWI, see https://www.cwi.nl) in the Netherlands +as a successor of a language called ABC. Guido remains Python's +principal author, although it includes many contributions from others. + +In 1995, Guido continued his work on Python at the Corporation for +National Research Initiatives (CNRI, see https://www.cnri.reston.va.us) +in Reston, Virginia where he released several versions of the +software. + +In May 2000, Guido and the Python core development team moved to +BeOpen.com to form the BeOpen PythonLabs team. In October of the same +year, the PythonLabs team moved to Digital Creations, which became +Zope Corporation. In 2001, the Python Software Foundation (PSF, see +https://www.python.org/psf/) was formed, a non-profit organization +created specifically to own Python-related Intellectual Property. +Zope Corporation was a sponsoring member of the PSF. + +All Python releases are Open Source (see https://opensource.org for +the Open Source Definition). Historically, most, but not all, Python +releases have also been GPL-compatible; the table below summarizes +the various releases. + + Release Derived Year Owner GPL- + from compatible? (1) + + 0.9.0 thru 1.2 1991-1995 CWI yes + 1.3 thru 1.5.2 1.2 1995-1999 CNRI yes + 1.6 1.5.2 2000 CNRI no + 2.0 1.6 2000 BeOpen.com no + 1.6.1 1.6 2001 CNRI yes (2) + 2.1 2.0+1.6.1 2001 PSF no + 2.0.1 2.0+1.6.1 2001 PSF yes + 2.1.1 2.1+2.0.1 2001 PSF yes + 2.1.2 2.1.1 2002 PSF yes + 2.1.3 2.1.2 2002 PSF yes + 2.2 and above 2.1.1 2001-now PSF yes + +Footnotes: + +(1) GPL-compatible doesn't mean that we're distributing Python under + the GPL. All Python licenses, unlike the GPL, let you distribute + a modified version without making your changes open source. The + GPL-compatible licenses make it possible to combine Python with + other software that is released under the GPL; the others don't. + +(2) According to Richard Stallman, 1.6.1 is not GPL-compatible, + because its license has a choice of law clause. According to + CNRI, however, Stallman's lawyer has told CNRI's lawyer that 1.6.1 + is "not incompatible" with the GPL. + +Thanks to the many outside volunteers who have worked under Guido's +direction to make these releases possible. + + +B. TERMS AND CONDITIONS FOR ACCESSING OR OTHERWISE USING PYTHON +=============================================================== + +Python software and documentation are licensed under the +Python Software Foundation License Version 2. + +Starting with Python 3.8.6, examples, recipes, and other code in +the documentation are dual licensed under the PSF License Version 2 +and the Zero-Clause BSD license. + +Some software incorporated into Python is under different licenses. +The licenses are listed with code falling under that license. + + +PYTHON SOFTWARE FOUNDATION LICENSE VERSION 2 +-------------------------------------------- + +1. This LICENSE AGREEMENT is between the Python Software Foundation +("PSF"), and the Individual or Organization ("Licensee") accessing and +otherwise using this software ("Python") in source or binary form and +its associated documentation. + +2. Subject to the terms and conditions of this License Agreement, PSF hereby +grants Licensee a nonexclusive, royalty-free, world-wide license to reproduce, +analyze, test, perform and/or display publicly, prepare derivative works, +distribute, and otherwise use Python alone or in any derivative version, +provided, however, that PSF's License Agreement and PSF's notice of copyright, +i.e., "Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, +2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023 Python Software Foundation; +All Rights Reserved" are retained in Python alone or in any derivative version +prepared by Licensee. + +3. In the event Licensee prepares a derivative work that is based on +or incorporates Python or any part thereof, and wants to make +the derivative work available to others as provided herein, then +Licensee hereby agrees to include in any such work a brief summary of +the changes made to Python. + +4. PSF is making Python available to Licensee on an "AS IS" +basis. PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR +IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND +DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS +FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON WILL NOT +INFRINGE ANY THIRD PARTY RIGHTS. + +5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON +FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS +A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON, +OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. + +6. This License Agreement will automatically terminate upon a material +breach of its terms and conditions. + +7. Nothing in this License Agreement shall be deemed to create any +relationship of agency, partnership, or joint venture between PSF and +Licensee. This License Agreement does not grant permission to use PSF +trademarks or trade name in a trademark sense to endorse or promote +products or services of Licensee, or any third party. + +8. By copying, installing or otherwise using Python, Licensee +agrees to be bound by the terms and conditions of this License +Agreement. + + +BEOPEN.COM LICENSE AGREEMENT FOR PYTHON 2.0 +------------------------------------------- + +BEOPEN PYTHON OPEN SOURCE LICENSE AGREEMENT VERSION 1 + +1. This LICENSE AGREEMENT is between BeOpen.com ("BeOpen"), having an +office at 160 Saratoga Avenue, Santa Clara, CA 95051, and the +Individual or Organization ("Licensee") accessing and otherwise using +this software in source or binary form and its associated +documentation ("the Software"). + +2. Subject to the terms and conditions of this BeOpen Python License +Agreement, BeOpen hereby grants Licensee a non-exclusive, +royalty-free, world-wide license to reproduce, analyze, test, perform +and/or display publicly, prepare derivative works, distribute, and +otherwise use the Software alone or in any derivative version, +provided, however, that the BeOpen Python License is retained in the +Software, alone or in any derivative version prepared by Licensee. + +3. BeOpen is making the Software available to Licensee on an "AS IS" +basis. BEOPEN MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR +IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, BEOPEN MAKES NO AND +DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS +FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE WILL NOT +INFRINGE ANY THIRD PARTY RIGHTS. + +4. BEOPEN SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF THE +SOFTWARE FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS +AS A RESULT OF USING, MODIFYING OR DISTRIBUTING THE SOFTWARE, OR ANY +DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. + +5. This License Agreement will automatically terminate upon a material +breach of its terms and conditions. + +6. This License Agreement shall be governed by and interpreted in all +respects by the law of the State of California, excluding conflict of +law provisions. Nothing in this License Agreement shall be deemed to +create any relationship of agency, partnership, or joint venture +between BeOpen and Licensee. This License Agreement does not grant +permission to use BeOpen trademarks or trade names in a trademark +sense to endorse or promote products or services of Licensee, or any +third party. As an exception, the "BeOpen Python" logos available at +http://www.pythonlabs.com/logos.html may be used according to the +permissions granted on that web page. + +7. By copying, installing or otherwise using the software, Licensee +agrees to be bound by the terms and conditions of this License +Agreement. + + +CNRI LICENSE AGREEMENT FOR PYTHON 1.6.1 +--------------------------------------- + +1. This LICENSE AGREEMENT is between the Corporation for National +Research Initiatives, having an office at 1895 Preston White Drive, +Reston, VA 20191 ("CNRI"), and the Individual or Organization +("Licensee") accessing and otherwise using Python 1.6.1 software in +source or binary form and its associated documentation. + +2. Subject to the terms and conditions of this License Agreement, CNRI +hereby grants Licensee a nonexclusive, royalty-free, world-wide +license to reproduce, analyze, test, perform and/or display publicly, +prepare derivative works, distribute, and otherwise use Python 1.6.1 +alone or in any derivative version, provided, however, that CNRI's +License Agreement and CNRI's notice of copyright, i.e., "Copyright (c) +1995-2001 Corporation for National Research Initiatives; All Rights +Reserved" are retained in Python 1.6.1 alone or in any derivative +version prepared by Licensee. Alternately, in lieu of CNRI's License +Agreement, Licensee may substitute the following text (omitting the +quotes): "Python 1.6.1 is made available subject to the terms and +conditions in CNRI's License Agreement. This Agreement together with +Python 1.6.1 may be located on the internet using the following +unique, persistent identifier (known as a handle): 1895.22/1013. This +Agreement may also be obtained from a proxy server on the internet +using the following URL: http://hdl.handle.net/1895.22/1013". + +3. In the event Licensee prepares a derivative work that is based on +or incorporates Python 1.6.1 or any part thereof, and wants to make +the derivative work available to others as provided herein, then +Licensee hereby agrees to include in any such work a brief summary of +the changes made to Python 1.6.1. + +4. CNRI is making Python 1.6.1 available to Licensee on an "AS IS" +basis. CNRI MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR +IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, CNRI MAKES NO AND +DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS +FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON 1.6.1 WILL NOT +INFRINGE ANY THIRD PARTY RIGHTS. + +5. CNRI SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON +1.6.1 FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS +A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON 1.6.1, +OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. + +6. This License Agreement will automatically terminate upon a material +breach of its terms and conditions. + +7. This License Agreement shall be governed by the federal +intellectual property law of the United States, including without +limitation the federal copyright law, and, to the extent such +U.S. federal law does not apply, by the law of the Commonwealth of +Virginia, excluding Virginia's conflict of law provisions. +Notwithstanding the foregoing, with regard to derivative works based +on Python 1.6.1 that incorporate non-separable material that was +previously distributed under the GNU General Public License (GPL), the +law of the Commonwealth of Virginia shall govern this License +Agreement only as to issues arising under or with respect to +Paragraphs 4, 5, and 7 of this License Agreement. Nothing in this +License Agreement shall be deemed to create any relationship of +agency, partnership, or joint venture between CNRI and Licensee. This +License Agreement does not grant permission to use CNRI trademarks or +trade name in a trademark sense to endorse or promote products or +services of Licensee, or any third party. + +8. By clicking on the "ACCEPT" button where indicated, or by copying, +installing or otherwise using Python 1.6.1, Licensee agrees to be +bound by the terms and conditions of this License Agreement. + + ACCEPT + + +CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2 +-------------------------------------------------- + +Copyright (c) 1991 - 1995, Stichting Mathematisch Centrum Amsterdam, +The Netherlands. All rights reserved. + +Permission to use, copy, modify, and distribute this software and its +documentation for any purpose and without fee is hereby granted, +provided that the above copyright notice appear in all copies and that +both that copyright notice and this permission notice appear in +supporting documentation, and that the name of Stichting Mathematisch +Centrum or CWI not be used in advertising or publicity pertaining to +distribution of the software without specific, written prior +permission. + +STICHTING MATHEMATISCH CENTRUM DISCLAIMS ALL WARRANTIES WITH REGARD TO +THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND +FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH CENTRUM BE LIABLE +FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT +OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + +ZERO-CLAUSE BSD LICENSE FOR CODE IN THE PYTHON DOCUMENTATION +---------------------------------------------------------------------- + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. + + + +Additional Conditions for this Windows binary build +--------------------------------------------------- + +This program is linked with and uses Microsoft Distributable Code, +copyrighted by Microsoft Corporation. The Microsoft Distributable Code +is embedded in each .exe, .dll and .pyd file as a result of running +the code through a linker. + +If you further distribute programs that include the Microsoft +Distributable Code, you must comply with the restrictions on +distribution specified by Microsoft. In particular, you must require +distributors and external end users to agree to terms that protect the +Microsoft Distributable Code at least as much as Microsoft's own +requirements for the Distributable Code. See Microsoft's documentation +(included in its developer tools and on its website at microsoft.com) +for specific details. + +Redistribution of the Windows binary build of the Python interpreter +complies with this agreement, provided that you do not: + +- alter any copyright, trademark or patent notice in Microsoft's +Distributable Code; + +- use Microsoft's trademarks in your programs' names or in a way that +suggests your programs come from or are endorsed by Microsoft; + +- distribute Microsoft's Distributable Code to run on a platform other +than Microsoft operating systems, run-time technologies or application +platforms; or + +- include Microsoft Distributable Code in malicious, deceptive or +unlawful programs. + +These restrictions apply only to the Microsoft Distributable Code as +defined above, not to Python itself or any programs running on the +Python interpreter. The redistribution of the Python interpreter and +libraries is governed by the Python Software License included with this +file, or by other licenses as marked. + + + +-------------------------------------------------------------------------- + +This program, "bzip2", the associated library "libbzip2", and all +documentation, are copyright (C) 1996-2019 Julian R Seward. All +rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +2. The origin of this software must not be misrepresented; you must + not claim that you wrote the original software. If you use this + software in a product, an acknowledgment in the product + documentation would be appreciated but is not required. + +3. Altered source versions must be plainly marked as such, and must + not be misrepresented as being the original software. + +4. The name of the author may not be used to endorse or promote + products derived from this software without specific prior written + permission. + +THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS +OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY +DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE +GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +Julian Seward, jseward@acm.org +bzip2/libbzip2 version 1.0.8 of 13 July 2019 + +-------------------------------------------------------------------------- + +libffi - Copyright (c) 1996-2022 Anthony Green, Red Hat, Inc and others. +See source files for details. + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +``Software''), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + + Apache License + Version 2.0, January 2004 + https://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + +This software is copyrighted by the Regents of the University of +California, Sun Microsystems, Inc., Scriptics Corporation, ActiveState +Corporation and other parties. The following terms apply to all files +associated with the software unless explicitly disclaimed in +individual files. + +The authors hereby grant permission to use, copy, modify, distribute, +and license this software and its documentation for any purpose, provided +that existing copyright notices are retained in all copies and that this +notice is included verbatim in any distributions. No written agreement, +license, or royalty fee is required for any of the authorized uses. +Modifications to this software may be copyrighted by their authors +and need not follow the licensing terms described here, provided that +the new terms are clearly indicated on the first page of each file where +they apply. + +IN NO EVENT SHALL THE AUTHORS OR DISTRIBUTORS BE LIABLE TO ANY PARTY +FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES +ARISING OUT OF THE USE OF THIS SOFTWARE, ITS DOCUMENTATION, OR ANY +DERIVATIVES THEREOF, EVEN IF THE AUTHORS HAVE BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. + +THE AUTHORS AND DISTRIBUTORS SPECIFICALLY DISCLAIM ANY WARRANTIES, +INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT. THIS SOFTWARE +IS PROVIDED ON AN "AS IS" BASIS, AND THE AUTHORS AND DISTRIBUTORS HAVE +NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR +MODIFICATIONS. + +GOVERNMENT USE: If you are acquiring this software on behalf of the +U.S. government, the Government shall have only "Restricted Rights" +in the software and related documentation as defined in the Federal +Acquisition Regulations (FARs) in Clause 52.227.19 (c) (2). If you +are acquiring the software on behalf of the Department of Defense, the +software shall be classified as "Commercial Computer Software" and the +Government shall have only "Restricted Rights" as defined in Clause +252.227-7014 (b) (3) of DFARs. Notwithstanding the foregoing, the +authors grant the U.S. Government and others acting in its behalf +permission to use and distribute the software in accordance with the +terms specified in this license. + +This software is copyrighted by the Regents of the University of +California, Sun Microsystems, Inc., Scriptics Corporation, ActiveState +Corporation, Apple Inc. and other parties. The following terms apply to +all files associated with the software unless explicitly disclaimed in +individual files. + +The authors hereby grant permission to use, copy, modify, distribute, +and license this software and its documentation for any purpose, provided +that existing copyright notices are retained in all copies and that this +notice is included verbatim in any distributions. No written agreement, +license, or royalty fee is required for any of the authorized uses. +Modifications to this software may be copyrighted by their authors +and need not follow the licensing terms described here, provided that +the new terms are clearly indicated on the first page of each file where +they apply. + +IN NO EVENT SHALL THE AUTHORS OR DISTRIBUTORS BE LIABLE TO ANY PARTY +FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES +ARISING OUT OF THE USE OF THIS SOFTWARE, ITS DOCUMENTATION, OR ANY +DERIVATIVES THEREOF, EVEN IF THE AUTHORS HAVE BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. + +THE AUTHORS AND DISTRIBUTORS SPECIFICALLY DISCLAIM ANY WARRANTIES, +INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT. THIS SOFTWARE +IS PROVIDED ON AN "AS IS" BASIS, AND THE AUTHORS AND DISTRIBUTORS HAVE +NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR +MODIFICATIONS. + +GOVERNMENT USE: If you are acquiring this software on behalf of the +U.S. government, the Government shall have only "Restricted Rights" +in the software and related documentation as defined in the Federal +Acquisition Regulations (FARs) in Clause 52.227.19 (c) (2). If you +are acquiring the software on behalf of the Department of Defense, the +software shall be classified as "Commercial Computer Software" and the +Government shall have only "Restricted Rights" as defined in Clause +252.227-7013 (b) (3) of DFARs. Notwithstanding the foregoing, the +authors grant the U.S. Government and others acting in its behalf +permission to use and distribute the software in accordance with the +terms specified in this license. + +Copyright (c) 1993-1999 Ioi Kim Lam. +Copyright (c) 2000-2001 Tix Project Group. +Copyright (c) 2004 ActiveState + +This software is copyrighted by the above entities +and other parties. The following terms apply to all files associated +with the software unless explicitly disclaimed in individual files. + +The authors hereby grant permission to use, copy, modify, distribute, +and license this software and its documentation for any purpose, provided +that existing copyright notices are retained in all copies and that this +notice is included verbatim in any distributions. No written agreement, +license, or royalty fee is required for any of the authorized uses. +Modifications to this software may be copyrighted by their authors +and need not follow the licensing terms described here, provided that +the new terms are clearly indicated on the first page of each file where +they apply. + +IN NO EVENT SHALL THE AUTHORS OR DISTRIBUTORS BE LIABLE TO ANY PARTY +FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES +ARISING OUT OF THE USE OF THIS SOFTWARE, ITS DOCUMENTATION, OR ANY +DERIVATIVES THEREOF, EVEN IF THE AUTHORS HAVE BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. + +THE AUTHORS AND DISTRIBUTORS SPECIFICALLY DISCLAIM ANY WARRANTIES, +INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT. THIS SOFTWARE +IS PROVIDED ON AN "AS IS" BASIS, AND THE AUTHORS AND DISTRIBUTORS HAVE +NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR +MODIFICATIONS. + +GOVERNMENT USE: If you are acquiring this software on behalf of the +U.S. government, the Government shall have only "Restricted Rights" +in the software and related documentation as defined in the Federal +Acquisition Regulations (FARs) in Clause 52.227.19 (c) (2). If you +are acquiring the software on behalf of the Department of Defense, the +software shall be classified as "Commercial Computer Software" and the +Government shall have only "Restricted Rights" as defined in Clause +252.227-7013 (c) (1) of DFARs. Notwithstanding the foregoing, the +authors grant the U.S. Government and others acting in its behalf +permission to use and distribute the software in accordance with the +terms specified in this license. + +---------------------------------------------------------------------- + +Parts of this software are based on the Tcl/Tk software copyrighted by +the Regents of the University of California, Sun Microsystems, Inc., +and other parties. The original license terms of the Tcl/Tk software +distribution is included in the file docs/license.tcltk. + +Parts of this software are based on the HTML Library software +copyrighted by Sun Microsystems, Inc. The original license terms of +the HTML Library software distribution is included in the file +docs/license.html_lib. + diff --git a/bin/cengines/CPY3123/_asyncio.pyd b/bin/cengines/CPY3123/_asyncio.pyd new file mode 100644 index 000000000..a99d0a241 Binary files /dev/null and b/bin/cengines/CPY3123/_asyncio.pyd differ diff --git a/bin/cengines/CPY3123/_bz2.pyd b/bin/cengines/CPY3123/_bz2.pyd new file mode 100644 index 000000000..67bf7c2a0 Binary files /dev/null and b/bin/cengines/CPY3123/_bz2.pyd differ diff --git a/bin/cengines/CPY3123/_ctypes.pyd b/bin/cengines/CPY3123/_ctypes.pyd new file mode 100644 index 000000000..2f874ac00 Binary files /dev/null and b/bin/cengines/CPY3123/_ctypes.pyd differ diff --git a/bin/cengines/CPY3123/_decimal.pyd b/bin/cengines/CPY3123/_decimal.pyd new file mode 100644 index 000000000..6ad2cff1b Binary files /dev/null and b/bin/cengines/CPY3123/_decimal.pyd differ diff --git a/bin/cengines/CPY3123/_elementtree.pyd b/bin/cengines/CPY3123/_elementtree.pyd new file mode 100644 index 000000000..a4f39e94b Binary files /dev/null and b/bin/cengines/CPY3123/_elementtree.pyd differ diff --git a/bin/cengines/CPY3123/_hashlib.pyd b/bin/cengines/CPY3123/_hashlib.pyd new file mode 100644 index 000000000..59e583ec3 Binary files /dev/null and b/bin/cengines/CPY3123/_hashlib.pyd differ diff --git a/bin/cengines/CPY3123/_lzma.pyd b/bin/cengines/CPY3123/_lzma.pyd new file mode 100644 index 000000000..4a9c68920 Binary files /dev/null and b/bin/cengines/CPY3123/_lzma.pyd differ diff --git a/bin/cengines/CPY3123/_msi.pyd b/bin/cengines/CPY3123/_msi.pyd new file mode 100644 index 000000000..d0ec53958 Binary files /dev/null and b/bin/cengines/CPY3123/_msi.pyd differ diff --git a/bin/cengines/CPY3123/_multiprocessing.pyd b/bin/cengines/CPY3123/_multiprocessing.pyd new file mode 100644 index 000000000..559d16768 Binary files /dev/null and b/bin/cengines/CPY3123/_multiprocessing.pyd differ diff --git a/bin/cengines/CPY3123/_overlapped.pyd b/bin/cengines/CPY3123/_overlapped.pyd new file mode 100644 index 000000000..a7ee3868e Binary files /dev/null and b/bin/cengines/CPY3123/_overlapped.pyd differ diff --git a/bin/cengines/CPY3123/_queue.pyd b/bin/cengines/CPY3123/_queue.pyd new file mode 100644 index 000000000..66791401d Binary files /dev/null and b/bin/cengines/CPY3123/_queue.pyd differ diff --git a/bin/cengines/CPY3123/_socket.pyd b/bin/cengines/CPY3123/_socket.pyd new file mode 100644 index 000000000..a9ba93b5e Binary files /dev/null and b/bin/cengines/CPY3123/_socket.pyd differ diff --git a/bin/cengines/CPY3123/_sqlite3.pyd b/bin/cengines/CPY3123/_sqlite3.pyd new file mode 100644 index 000000000..64eb1dc6b Binary files /dev/null and b/bin/cengines/CPY3123/_sqlite3.pyd differ diff --git a/bin/cengines/CPY3123/_ssl.pyd b/bin/cengines/CPY3123/_ssl.pyd new file mode 100644 index 000000000..33227dce1 Binary files /dev/null and b/bin/cengines/CPY3123/_ssl.pyd differ diff --git a/bin/cengines/CPY3123/_uuid.pyd b/bin/cengines/CPY3123/_uuid.pyd new file mode 100644 index 000000000..ec243aeeb Binary files /dev/null and b/bin/cengines/CPY3123/_uuid.pyd differ diff --git a/bin/cengines/CPY3123/_wmi.pyd b/bin/cengines/CPY3123/_wmi.pyd new file mode 100644 index 000000000..0fd9e7618 Binary files /dev/null and b/bin/cengines/CPY3123/_wmi.pyd differ diff --git a/bin/cengines/CPY3123/_zoneinfo.pyd b/bin/cengines/CPY3123/_zoneinfo.pyd new file mode 100644 index 000000000..ced6136d1 Binary files /dev/null and b/bin/cengines/CPY3123/_zoneinfo.pyd differ diff --git a/bin/cengines/CPY3123/libcrypto-3.dll b/bin/cengines/CPY3123/libcrypto-3.dll new file mode 100644 index 000000000..dd511fb26 Binary files /dev/null and b/bin/cengines/CPY3123/libcrypto-3.dll differ diff --git a/bin/cengines/CPY3123/libffi-8.dll b/bin/cengines/CPY3123/libffi-8.dll new file mode 100644 index 000000000..8ebbbe8d5 Binary files /dev/null and b/bin/cengines/CPY3123/libffi-8.dll differ diff --git a/bin/cengines/CPY3123/libssl-3.dll b/bin/cengines/CPY3123/libssl-3.dll new file mode 100644 index 000000000..b9bc6529e Binary files /dev/null and b/bin/cengines/CPY3123/libssl-3.dll differ diff --git a/bin/cengines/CPY3123/pyexpat.pyd b/bin/cengines/CPY3123/pyexpat.pyd new file mode 100644 index 000000000..906673a34 Binary files /dev/null and b/bin/cengines/CPY3123/pyexpat.pyd differ diff --git a/bin/cengines/CPY3123/python.cat b/bin/cengines/CPY3123/python.cat new file mode 100644 index 000000000..4ceadf65e Binary files /dev/null and b/bin/cengines/CPY3123/python.cat differ diff --git a/bin/engines/CPY385/python.exe b/bin/cengines/CPY3123/python.exe similarity index 78% rename from bin/engines/CPY385/python.exe rename to bin/cengines/CPY3123/python.exe index 5708db42b..ffe6d78cb 100644 Binary files a/bin/engines/CPY385/python.exe and b/bin/cengines/CPY3123/python.exe differ diff --git a/bin/cengines/CPY3123/python3.dll b/bin/cengines/CPY3123/python3.dll new file mode 100644 index 000000000..5f9d9c3c5 Binary files /dev/null and b/bin/cengines/CPY3123/python3.dll differ diff --git a/bin/engines/CPY378/python37._pth b/bin/cengines/CPY3123/python312._pth similarity index 81% rename from bin/engines/CPY378/python37._pth rename to bin/cengines/CPY3123/python312._pth index 1298e93f5..99b13f803 100644 --- a/bin/engines/CPY378/python37._pth +++ b/bin/cengines/CPY3123/python312._pth @@ -1,4 +1,4 @@ -python37.zip +python312.zip . # Uncomment to run site.main() automatically diff --git a/bin/cengines/CPY3123/python312.dll b/bin/cengines/CPY3123/python312.dll new file mode 100644 index 000000000..5ca128e71 Binary files /dev/null and b/bin/cengines/CPY3123/python312.dll differ diff --git a/bin/cengines/CPY3123/python312.zip b/bin/cengines/CPY3123/python312.zip new file mode 100644 index 000000000..4be5f74de Binary files /dev/null and b/bin/cengines/CPY3123/python312.zip differ diff --git a/bin/engines/CPY378/pythonw.exe b/bin/cengines/CPY3123/pythonw.exe similarity index 78% rename from bin/engines/CPY378/pythonw.exe rename to bin/cengines/CPY3123/pythonw.exe index 53c5fd4be..be1948ab1 100644 Binary files a/bin/engines/CPY378/pythonw.exe and b/bin/cengines/CPY3123/pythonw.exe differ diff --git a/bin/cengines/CPY3123/select.pyd b/bin/cengines/CPY3123/select.pyd new file mode 100644 index 000000000..9b78fffae Binary files /dev/null and b/bin/cengines/CPY3123/select.pyd differ diff --git a/bin/cengines/CPY3123/sqlite3.dll b/bin/cengines/CPY3123/sqlite3.dll new file mode 100644 index 000000000..bcb2cc08e Binary files /dev/null and b/bin/cengines/CPY3123/sqlite3.dll differ diff --git a/bin/cengines/CPY3123/unicodedata.pyd b/bin/cengines/CPY3123/unicodedata.pyd new file mode 100644 index 000000000..ad96372b4 Binary files /dev/null and b/bin/cengines/CPY3123/unicodedata.pyd differ diff --git a/bin/cengines/CPY3123/vcruntime140.dll b/bin/cengines/CPY3123/vcruntime140.dll new file mode 100644 index 000000000..a9ed5c4ca Binary files /dev/null and b/bin/cengines/CPY3123/vcruntime140.dll differ diff --git a/bin/cengines/CPY3123/vcruntime140_1.dll b/bin/cengines/CPY3123/vcruntime140_1.dll new file mode 100644 index 000000000..cb34ab6cc Binary files /dev/null and b/bin/cengines/CPY3123/vcruntime140_1.dll differ diff --git a/bin/cengines/CPY3123/winsound.pyd b/bin/cengines/CPY3123/winsound.pyd new file mode 100644 index 000000000..e3fc3b07f Binary files /dev/null and b/bin/cengines/CPY3123/winsound.pyd differ diff --git a/bin/engines/CPY378/LICENSE.txt b/bin/engines/CPY378/LICENSE.txt deleted file mode 100644 index 66a3ac80d..000000000 --- a/bin/engines/CPY378/LICENSE.txt +++ /dev/null @@ -1,254 +0,0 @@ -A. HISTORY OF THE SOFTWARE -========================== - -Python was created in the early 1990s by Guido van Rossum at Stichting -Mathematisch Centrum (CWI, see http://www.cwi.nl) in the Netherlands -as a successor of a language called ABC. Guido remains Python's -principal author, although it includes many contributions from others. - -In 1995, Guido continued his work on Python at the Corporation for -National Research Initiatives (CNRI, see http://www.cnri.reston.va.us) -in Reston, Virginia where he released several versions of the -software. - -In May 2000, Guido and the Python core development team moved to -BeOpen.com to form the BeOpen PythonLabs team. In October of the same -year, the PythonLabs team moved to Digital Creations, which became -Zope Corporation. In 2001, the Python Software Foundation (PSF, see -https://www.python.org/psf/) was formed, a non-profit organization -created specifically to own Python-related Intellectual Property. -Zope Corporation was a sponsoring member of the PSF. - -All Python releases are Open Source (see http://www.opensource.org for -the Open Source Definition). Historically, most, but not all, Python -releases have also been GPL-compatible; the table below summarizes -the various releases. - - Release Derived Year Owner GPL- - from compatible? (1) - - 0.9.0 thru 1.2 1991-1995 CWI yes - 1.3 thru 1.5.2 1.2 1995-1999 CNRI yes - 1.6 1.5.2 2000 CNRI no - 2.0 1.6 2000 BeOpen.com no - 1.6.1 1.6 2001 CNRI yes (2) - 2.1 2.0+1.6.1 2001 PSF no - 2.0.1 2.0+1.6.1 2001 PSF yes - 2.1.1 2.1+2.0.1 2001 PSF yes - 2.1.2 2.1.1 2002 PSF yes - 2.1.3 2.1.2 2002 PSF yes - 2.2 and above 2.1.1 2001-now PSF yes - -Footnotes: - -(1) GPL-compatible doesn't mean that we're distributing Python under - the GPL. All Python licenses, unlike the GPL, let you distribute - a modified version without making your changes open source. The - GPL-compatible licenses make it possible to combine Python with - other software that is released under the GPL; the others don't. - -(2) According to Richard Stallman, 1.6.1 is not GPL-compatible, - because its license has a choice of law clause. According to - CNRI, however, Stallman's lawyer has told CNRI's lawyer that 1.6.1 - is "not incompatible" with the GPL. - -Thanks to the many outside volunteers who have worked under Guido's -direction to make these releases possible. - - -B. TERMS AND CONDITIONS FOR ACCESSING OR OTHERWISE USING PYTHON -=============================================================== - -PYTHON SOFTWARE FOUNDATION LICENSE VERSION 2 --------------------------------------------- - -1. This LICENSE AGREEMENT is between the Python Software Foundation -("PSF"), and the Individual or Organization ("Licensee") accessing and -otherwise using this software ("Python") in source or binary form and -its associated documentation. - -2. Subject to the terms and conditions of this License Agreement, PSF hereby -grants Licensee a nonexclusive, royalty-free, world-wide license to reproduce, -analyze, test, perform and/or display publicly, prepare derivative works, -distribute, and otherwise use Python alone or in any derivative version, -provided, however, that PSF's License Agreement and PSF's notice of copyright, -i.e., "Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, -2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Python Software Foundation; -All Rights Reserved" are retained in Python alone or in any derivative version -prepared by Licensee. - -3. In the event Licensee prepares a derivative work that is based on -or incorporates Python or any part thereof, and wants to make -the derivative work available to others as provided herein, then -Licensee hereby agrees to include in any such work a brief summary of -the changes made to Python. - -4. PSF is making Python available to Licensee on an "AS IS" -basis. PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR -IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND -DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS -FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON WILL NOT -INFRINGE ANY THIRD PARTY RIGHTS. - -5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON -FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS -A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON, -OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. - -6. This License Agreement will automatically terminate upon a material -breach of its terms and conditions. - -7. Nothing in this License Agreement shall be deemed to create any -relationship of agency, partnership, or joint venture between PSF and -Licensee. This License Agreement does not grant permission to use PSF -trademarks or trade name in a trademark sense to endorse or promote -products or services of Licensee, or any third party. - -8. By copying, installing or otherwise using Python, Licensee -agrees to be bound by the terms and conditions of this License -Agreement. - - -BEOPEN.COM LICENSE AGREEMENT FOR PYTHON 2.0 -------------------------------------------- - -BEOPEN PYTHON OPEN SOURCE LICENSE AGREEMENT VERSION 1 - -1. This LICENSE AGREEMENT is between BeOpen.com ("BeOpen"), having an -office at 160 Saratoga Avenue, Santa Clara, CA 95051, and the -Individual or Organization ("Licensee") accessing and otherwise using -this software in source or binary form and its associated -documentation ("the Software"). - -2. Subject to the terms and conditions of this BeOpen Python License -Agreement, BeOpen hereby grants Licensee a non-exclusive, -royalty-free, world-wide license to reproduce, analyze, test, perform -and/or display publicly, prepare derivative works, distribute, and -otherwise use the Software alone or in any derivative version, -provided, however, that the BeOpen Python License is retained in the -Software, alone or in any derivative version prepared by Licensee. - -3. BeOpen is making the Software available to Licensee on an "AS IS" -basis. BEOPEN MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR -IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, BEOPEN MAKES NO AND -DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS -FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE WILL NOT -INFRINGE ANY THIRD PARTY RIGHTS. - -4. BEOPEN SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF THE -SOFTWARE FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS -AS A RESULT OF USING, MODIFYING OR DISTRIBUTING THE SOFTWARE, OR ANY -DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. - -5. This License Agreement will automatically terminate upon a material -breach of its terms and conditions. - -6. This License Agreement shall be governed by and interpreted in all -respects by the law of the State of California, excluding conflict of -law provisions. Nothing in this License Agreement shall be deemed to -create any relationship of agency, partnership, or joint venture -between BeOpen and Licensee. This License Agreement does not grant -permission to use BeOpen trademarks or trade names in a trademark -sense to endorse or promote products or services of Licensee, or any -third party. As an exception, the "BeOpen Python" logos available at -http://www.pythonlabs.com/logos.html may be used according to the -permissions granted on that web page. - -7. By copying, installing or otherwise using the software, Licensee -agrees to be bound by the terms and conditions of this License -Agreement. - - -CNRI LICENSE AGREEMENT FOR PYTHON 1.6.1 ---------------------------------------- - -1. This LICENSE AGREEMENT is between the Corporation for National -Research Initiatives, having an office at 1895 Preston White Drive, -Reston, VA 20191 ("CNRI"), and the Individual or Organization -("Licensee") accessing and otherwise using Python 1.6.1 software in -source or binary form and its associated documentation. - -2. Subject to the terms and conditions of this License Agreement, CNRI -hereby grants Licensee a nonexclusive, royalty-free, world-wide -license to reproduce, analyze, test, perform and/or display publicly, -prepare derivative works, distribute, and otherwise use Python 1.6.1 -alone or in any derivative version, provided, however, that CNRI's -License Agreement and CNRI's notice of copyright, i.e., "Copyright (c) -1995-2001 Corporation for National Research Initiatives; All Rights -Reserved" are retained in Python 1.6.1 alone or in any derivative -version prepared by Licensee. Alternately, in lieu of CNRI's License -Agreement, Licensee may substitute the following text (omitting the -quotes): "Python 1.6.1 is made available subject to the terms and -conditions in CNRI's License Agreement. This Agreement together with -Python 1.6.1 may be located on the Internet using the following -unique, persistent identifier (known as a handle): 1895.22/1013. This -Agreement may also be obtained from a proxy server on the Internet -using the following URL: http://hdl.handle.net/1895.22/1013". - -3. In the event Licensee prepares a derivative work that is based on -or incorporates Python 1.6.1 or any part thereof, and wants to make -the derivative work available to others as provided herein, then -Licensee hereby agrees to include in any such work a brief summary of -the changes made to Python 1.6.1. - -4. CNRI is making Python 1.6.1 available to Licensee on an "AS IS" -basis. CNRI MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR -IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, CNRI MAKES NO AND -DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS -FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON 1.6.1 WILL NOT -INFRINGE ANY THIRD PARTY RIGHTS. - -5. CNRI SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON -1.6.1 FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS -A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON 1.6.1, -OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. - -6. This License Agreement will automatically terminate upon a material -breach of its terms and conditions. - -7. This License Agreement shall be governed by the federal -intellectual property law of the United States, including without -limitation the federal copyright law, and, to the extent such -U.S. federal law does not apply, by the law of the Commonwealth of -Virginia, excluding Virginia's conflict of law provisions. -Notwithstanding the foregoing, with regard to derivative works based -on Python 1.6.1 that incorporate non-separable material that was -previously distributed under the GNU General Public License (GPL), the -law of the Commonwealth of Virginia shall govern this License -Agreement only as to issues arising under or with respect to -Paragraphs 4, 5, and 7 of this License Agreement. Nothing in this -License Agreement shall be deemed to create any relationship of -agency, partnership, or joint venture between CNRI and Licensee. This -License Agreement does not grant permission to use CNRI trademarks or -trade name in a trademark sense to endorse or promote products or -services of Licensee, or any third party. - -8. By clicking on the "ACCEPT" button where indicated, or by copying, -installing or otherwise using Python 1.6.1, Licensee agrees to be -bound by the terms and conditions of this License Agreement. - - ACCEPT - - -CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2 --------------------------------------------------- - -Copyright (c) 1991 - 1995, Stichting Mathematisch Centrum Amsterdam, -The Netherlands. All rights reserved. - -Permission to use, copy, modify, and distribute this software and its -documentation for any purpose and without fee is hereby granted, -provided that the above copyright notice appear in all copies and that -both that copyright notice and this permission notice appear in -supporting documentation, and that the name of Stichting Mathematisch -Centrum or CWI not be used in advertising or publicity pertaining to -distribution of the software without specific, written prior -permission. - -STICHTING MATHEMATISCH CENTRUM DISCLAIMS ALL WARRANTIES WITH REGARD TO -THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND -FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH CENTRUM BE LIABLE -FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT -OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/bin/engines/CPY378/_asyncio.pyd b/bin/engines/CPY378/_asyncio.pyd deleted file mode 100644 index 7efab3d4d..000000000 Binary files a/bin/engines/CPY378/_asyncio.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_bz2.pyd b/bin/engines/CPY378/_bz2.pyd deleted file mode 100644 index e893abddf..000000000 Binary files a/bin/engines/CPY378/_bz2.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_ctypes.pyd b/bin/engines/CPY378/_ctypes.pyd deleted file mode 100644 index 104daee0f..000000000 Binary files a/bin/engines/CPY378/_ctypes.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_decimal.pyd b/bin/engines/CPY378/_decimal.pyd deleted file mode 100644 index b6200b672..000000000 Binary files a/bin/engines/CPY378/_decimal.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_elementtree.pyd b/bin/engines/CPY378/_elementtree.pyd deleted file mode 100644 index 70693b04b..000000000 Binary files a/bin/engines/CPY378/_elementtree.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_hashlib.pyd b/bin/engines/CPY378/_hashlib.pyd deleted file mode 100644 index 5ea3dcc69..000000000 Binary files a/bin/engines/CPY378/_hashlib.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_lzma.pyd b/bin/engines/CPY378/_lzma.pyd deleted file mode 100644 index 329234711..000000000 Binary files a/bin/engines/CPY378/_lzma.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_msi.pyd b/bin/engines/CPY378/_msi.pyd deleted file mode 100644 index 84f6592ec..000000000 Binary files a/bin/engines/CPY378/_msi.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_multiprocessing.pyd b/bin/engines/CPY378/_multiprocessing.pyd deleted file mode 100644 index ecc8b47a9..000000000 Binary files a/bin/engines/CPY378/_multiprocessing.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_overlapped.pyd b/bin/engines/CPY378/_overlapped.pyd deleted file mode 100644 index 4568229da..000000000 Binary files a/bin/engines/CPY378/_overlapped.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_queue.pyd b/bin/engines/CPY378/_queue.pyd deleted file mode 100644 index 82c2939fd..000000000 Binary files a/bin/engines/CPY378/_queue.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_socket.pyd b/bin/engines/CPY378/_socket.pyd deleted file mode 100644 index 41f8ab50b..000000000 Binary files a/bin/engines/CPY378/_socket.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_sqlite3.pyd b/bin/engines/CPY378/_sqlite3.pyd deleted file mode 100644 index 96fe8ad66..000000000 Binary files a/bin/engines/CPY378/_sqlite3.pyd and /dev/null differ diff --git a/bin/engines/CPY378/_ssl.pyd b/bin/engines/CPY378/_ssl.pyd deleted file mode 100644 index ed1f42ee4..000000000 Binary files a/bin/engines/CPY378/_ssl.pyd and /dev/null differ diff --git a/bin/engines/CPY378/libcrypto-1_1.dll b/bin/engines/CPY378/libcrypto-1_1.dll deleted file mode 100644 index ddf454a67..000000000 Binary files a/bin/engines/CPY378/libcrypto-1_1.dll and /dev/null differ diff --git a/bin/engines/CPY378/libssl-1_1.dll b/bin/engines/CPY378/libssl-1_1.dll deleted file mode 100644 index 635cfd6bf..000000000 Binary files a/bin/engines/CPY378/libssl-1_1.dll and /dev/null differ diff --git a/bin/engines/CPY378/pyRevitLabs.PythonNet.dll b/bin/engines/CPY378/pyRevitLabs.PythonNet.dll deleted file mode 100644 index e180ac862..000000000 Binary files a/bin/engines/CPY378/pyRevitLabs.PythonNet.dll and /dev/null differ diff --git a/bin/engines/CPY378/pyexpat.pyd b/bin/engines/CPY378/pyexpat.pyd deleted file mode 100644 index a7a3ffb6f..000000000 Binary files a/bin/engines/CPY378/pyexpat.pyd and /dev/null differ diff --git a/bin/engines/CPY378/python.exe b/bin/engines/CPY378/python.exe deleted file mode 100644 index a87236bce..000000000 Binary files a/bin/engines/CPY378/python.exe and /dev/null differ diff --git a/bin/engines/CPY378/python3.dll b/bin/engines/CPY378/python3.dll deleted file mode 100644 index a67da7826..000000000 Binary files a/bin/engines/CPY378/python3.dll and /dev/null differ diff --git a/bin/engines/CPY378/python37.dll b/bin/engines/CPY378/python37.dll deleted file mode 100644 index ee52059b6..000000000 Binary files a/bin/engines/CPY378/python37.dll and /dev/null differ diff --git a/bin/engines/CPY378/python37.zip b/bin/engines/CPY378/python37.zip deleted file mode 100644 index d66c736ae..000000000 Binary files a/bin/engines/CPY378/python37.zip and /dev/null differ diff --git a/bin/engines/CPY378/select.pyd b/bin/engines/CPY378/select.pyd deleted file mode 100644 index 257c22273..000000000 Binary files a/bin/engines/CPY378/select.pyd and /dev/null differ diff --git a/bin/engines/CPY378/sqlite3.dll b/bin/engines/CPY378/sqlite3.dll deleted file mode 100644 index d26ac1841..000000000 Binary files a/bin/engines/CPY378/sqlite3.dll and /dev/null differ diff --git a/bin/engines/CPY378/unicodedata.pyd b/bin/engines/CPY378/unicodedata.pyd deleted file mode 100644 index 669aac3f7..000000000 Binary files a/bin/engines/CPY378/unicodedata.pyd and /dev/null differ diff --git a/bin/engines/CPY378/vcruntime140.dll b/bin/engines/CPY378/vcruntime140.dll deleted file mode 100644 index d6eac6e55..000000000 Binary files a/bin/engines/CPY378/vcruntime140.dll and /dev/null differ diff --git a/bin/engines/CPY378/winsound.pyd b/bin/engines/CPY378/winsound.pyd deleted file mode 100644 index 09a36fc88..000000000 Binary files a/bin/engines/CPY378/winsound.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_asyncio.pyd b/bin/engines/CPY385/_asyncio.pyd deleted file mode 100644 index 381b65c59..000000000 Binary files a/bin/engines/CPY385/_asyncio.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_bz2.pyd b/bin/engines/CPY385/_bz2.pyd deleted file mode 100644 index 9977d6b1b..000000000 Binary files a/bin/engines/CPY385/_bz2.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_ctypes.pyd b/bin/engines/CPY385/_ctypes.pyd deleted file mode 100644 index f58afb135..000000000 Binary files a/bin/engines/CPY385/_ctypes.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_decimal.pyd b/bin/engines/CPY385/_decimal.pyd deleted file mode 100644 index 4f818631b..000000000 Binary files a/bin/engines/CPY385/_decimal.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_elementtree.pyd b/bin/engines/CPY385/_elementtree.pyd deleted file mode 100644 index 0936d9b61..000000000 Binary files a/bin/engines/CPY385/_elementtree.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_hashlib.pyd b/bin/engines/CPY385/_hashlib.pyd deleted file mode 100644 index a557ae23f..000000000 Binary files a/bin/engines/CPY385/_hashlib.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_lzma.pyd b/bin/engines/CPY385/_lzma.pyd deleted file mode 100644 index fc7c99618..000000000 Binary files a/bin/engines/CPY385/_lzma.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_msi.pyd b/bin/engines/CPY385/_msi.pyd deleted file mode 100644 index 94d70bf95..000000000 Binary files a/bin/engines/CPY385/_msi.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_multiprocessing.pyd b/bin/engines/CPY385/_multiprocessing.pyd deleted file mode 100644 index effed6859..000000000 Binary files a/bin/engines/CPY385/_multiprocessing.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_overlapped.pyd b/bin/engines/CPY385/_overlapped.pyd deleted file mode 100644 index b825c8fc2..000000000 Binary files a/bin/engines/CPY385/_overlapped.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_queue.pyd b/bin/engines/CPY385/_queue.pyd deleted file mode 100644 index 8c8444af6..000000000 Binary files a/bin/engines/CPY385/_queue.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_socket.pyd b/bin/engines/CPY385/_socket.pyd deleted file mode 100644 index f75b1e1db..000000000 Binary files a/bin/engines/CPY385/_socket.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_sqlite3.pyd b/bin/engines/CPY385/_sqlite3.pyd deleted file mode 100644 index 0a77055d3..000000000 Binary files a/bin/engines/CPY385/_sqlite3.pyd and /dev/null differ diff --git a/bin/engines/CPY385/_ssl.pyd b/bin/engines/CPY385/_ssl.pyd deleted file mode 100644 index e6effffcd..000000000 Binary files a/bin/engines/CPY385/_ssl.pyd and /dev/null differ diff --git a/bin/engines/CPY385/libcrypto-1_1.dll b/bin/engines/CPY385/libcrypto-1_1.dll deleted file mode 100644 index 46178a635..000000000 Binary files a/bin/engines/CPY385/libcrypto-1_1.dll and /dev/null differ diff --git a/bin/engines/CPY385/libffi-7.dll b/bin/engines/CPY385/libffi-7.dll deleted file mode 100644 index c7a9d9e64..000000000 Binary files a/bin/engines/CPY385/libffi-7.dll and /dev/null differ diff --git a/bin/engines/CPY385/libssl-1_1.dll b/bin/engines/CPY385/libssl-1_1.dll deleted file mode 100644 index 1bcffe452..000000000 Binary files a/bin/engines/CPY385/libssl-1_1.dll and /dev/null differ diff --git a/bin/engines/CPY385/pyRevitLabs.PythonNet.dll b/bin/engines/CPY385/pyRevitLabs.PythonNet.dll deleted file mode 100644 index b13e879fe..000000000 Binary files a/bin/engines/CPY385/pyRevitLabs.PythonNet.dll and /dev/null differ diff --git a/bin/engines/CPY385/pyexpat.pyd b/bin/engines/CPY385/pyexpat.pyd deleted file mode 100644 index e558d5673..000000000 Binary files a/bin/engines/CPY385/pyexpat.pyd and /dev/null differ diff --git a/bin/engines/CPY385/python.cat b/bin/engines/CPY385/python.cat deleted file mode 100644 index 5a5e1b489..000000000 Binary files a/bin/engines/CPY385/python.cat and /dev/null differ diff --git a/bin/engines/CPY385/python3.dll b/bin/engines/CPY385/python3.dll deleted file mode 100644 index fad27fce5..000000000 Binary files a/bin/engines/CPY385/python3.dll and /dev/null differ diff --git a/bin/engines/CPY385/python38._pth b/bin/engines/CPY385/python38._pth deleted file mode 100644 index 3ca984388..000000000 --- a/bin/engines/CPY385/python38._pth +++ /dev/null @@ -1,5 +0,0 @@ -python38.zip -. - -# Uncomment to run site.main() automatically -#import site diff --git a/bin/engines/CPY385/python38.dll b/bin/engines/CPY385/python38.dll deleted file mode 100644 index d606ca5b6..000000000 Binary files a/bin/engines/CPY385/python38.dll and /dev/null differ diff --git a/bin/engines/CPY385/python38.zip b/bin/engines/CPY385/python38.zip deleted file mode 100644 index 398f54537..000000000 Binary files a/bin/engines/CPY385/python38.zip and /dev/null differ diff --git a/bin/engines/CPY385/pythonw.exe b/bin/engines/CPY385/pythonw.exe deleted file mode 100644 index 98eabe720..000000000 Binary files a/bin/engines/CPY385/pythonw.exe and /dev/null differ diff --git a/bin/engines/CPY385/select.pyd b/bin/engines/CPY385/select.pyd deleted file mode 100644 index 3c504881f..000000000 Binary files a/bin/engines/CPY385/select.pyd and /dev/null differ diff --git a/bin/engines/CPY385/sqlite3.dll b/bin/engines/CPY385/sqlite3.dll deleted file mode 100644 index f8f0832ad..000000000 Binary files a/bin/engines/CPY385/sqlite3.dll and /dev/null differ diff --git a/bin/engines/CPY385/unicodedata.pyd b/bin/engines/CPY385/unicodedata.pyd deleted file mode 100644 index 73da593b9..000000000 Binary files a/bin/engines/CPY385/unicodedata.pyd and /dev/null differ diff --git a/bin/engines/CPY385/vcruntime140.dll b/bin/engines/CPY385/vcruntime140.dll deleted file mode 100644 index dfab207a2..000000000 Binary files a/bin/engines/CPY385/vcruntime140.dll and /dev/null differ diff --git a/bin/engines/CPY385/vcruntime140_1.dll b/bin/engines/CPY385/vcruntime140_1.dll deleted file mode 100644 index 80ceda420..000000000 Binary files a/bin/engines/CPY385/vcruntime140_1.dll and /dev/null differ diff --git a/bin/engines/CPY385/winsound.pyd b/bin/engines/CPY385/winsound.pyd deleted file mode 100644 index 1f97e9965..000000000 Binary files a/bin/engines/CPY385/winsound.pyd and /dev/null differ diff --git a/bin/engines/IPY2711PR/pyRevitLabs.IronPython.Modules.dll b/bin/engines/IPY2711PR/pyRevitLabs.IronPython.Modules.dll deleted file mode 100644 index c4c042ceb..000000000 Binary files a/bin/engines/IPY2711PR/pyRevitLabs.IronPython.Modules.dll and /dev/null differ diff --git a/bin/engines/IPY2711PR/pyRevitLabs.IronPython.SQLite.dll b/bin/engines/IPY2711PR/pyRevitLabs.IronPython.SQLite.dll deleted file mode 100644 index 20c8faf22..000000000 Binary files a/bin/engines/IPY2711PR/pyRevitLabs.IronPython.SQLite.dll and /dev/null differ diff --git a/bin/engines/IPY2711PR/pyRevitLabs.IronPython.Wpf.dll b/bin/engines/IPY2711PR/pyRevitLabs.IronPython.Wpf.dll deleted file mode 100644 index 0d63c1792..000000000 Binary files a/bin/engines/IPY2711PR/pyRevitLabs.IronPython.Wpf.dll and /dev/null differ diff --git a/bin/engines/IPY2711PR/pyRevitLabs.IronPython.dll b/bin/engines/IPY2711PR/pyRevitLabs.IronPython.dll deleted file mode 100644 index 99c37525f..000000000 Binary files a/bin/engines/IPY2711PR/pyRevitLabs.IronPython.dll and /dev/null differ diff --git a/bin/engines/IPY2711PR/pyRevitLabs.Microsoft.Dynamic.dll b/bin/engines/IPY2711PR/pyRevitLabs.Microsoft.Dynamic.dll deleted file mode 100644 index 1f26b6810..000000000 Binary files a/bin/engines/IPY2711PR/pyRevitLabs.Microsoft.Dynamic.dll and /dev/null differ diff --git a/bin/engines/IPY2711PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll b/bin/engines/IPY2711PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll deleted file mode 100644 index a3611abe8..000000000 Binary files a/bin/engines/IPY2711PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll and /dev/null differ diff --git a/bin/engines/IPY2711PR/pyRevitLabs.Microsoft.Scripting.dll b/bin/engines/IPY2711PR/pyRevitLabs.Microsoft.Scripting.dll deleted file mode 100644 index 30bb86adb..000000000 Binary files a/bin/engines/IPY2711PR/pyRevitLabs.Microsoft.Scripting.dll and /dev/null differ diff --git a/bin/engines/IPY2711PR/pyRevitRunner.dll b/bin/engines/IPY2711PR/pyRevitRunner.dll deleted file mode 100644 index 1db30e9bf..000000000 Binary files a/bin/engines/IPY2711PR/pyRevitRunner.dll and /dev/null differ diff --git a/bin/engines/IPY340PR/pyRevitLabs.IronPython.Modules.dll b/bin/engines/IPY340PR/pyRevitLabs.IronPython.Modules.dll deleted file mode 100644 index 650e56e9b..000000000 Binary files a/bin/engines/IPY340PR/pyRevitLabs.IronPython.Modules.dll and /dev/null differ diff --git a/bin/engines/IPY340PR/pyRevitLabs.IronPython.Wpf.dll b/bin/engines/IPY340PR/pyRevitLabs.IronPython.Wpf.dll deleted file mode 100644 index 9088efc76..000000000 Binary files a/bin/engines/IPY340PR/pyRevitLabs.IronPython.Wpf.dll and /dev/null differ diff --git a/bin/engines/IPY340PR/pyRevitLabs.IronPython.dll b/bin/engines/IPY340PR/pyRevitLabs.IronPython.dll deleted file mode 100644 index 73a2b41b2..000000000 Binary files a/bin/engines/IPY340PR/pyRevitLabs.IronPython.dll and /dev/null differ diff --git a/bin/engines/IPY340PR/pyRevitLabs.Microsoft.Dynamic.dll b/bin/engines/IPY340PR/pyRevitLabs.Microsoft.Dynamic.dll deleted file mode 100644 index 33bce34bc..000000000 Binary files a/bin/engines/IPY340PR/pyRevitLabs.Microsoft.Dynamic.dll and /dev/null differ diff --git a/bin/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.dll b/bin/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.dll deleted file mode 100644 index a3effdd3a..000000000 Binary files a/bin/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.dll and /dev/null differ diff --git a/bin/engines/IPY340PR/pyRevitLoader.dll b/bin/engines/IPY340PR/pyRevitLoader.dll deleted file mode 100644 index 9c6df9d26..000000000 Binary files a/bin/engines/IPY340PR/pyRevitLoader.dll and /dev/null differ diff --git a/bin/engines/IPY340PR/pyRevitRunner.dll b/bin/engines/IPY340PR/pyRevitRunner.dll deleted file mode 100644 index 837d00d0e..000000000 Binary files a/bin/engines/IPY340PR/pyRevitRunner.dll and /dev/null differ diff --git a/bin/netcore/engines/IPY2712PR/Microsoft.Win32.Registry.dll b/bin/netcore/engines/IPY2712PR/Microsoft.Win32.Registry.dll new file mode 100644 index 000000000..78f349b84 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/Microsoft.Win32.Registry.dll differ diff --git a/bin/netcore/engines/IPY2712PR/Mono.Unix.dll b/bin/netcore/engines/IPY2712PR/Mono.Unix.dll new file mode 100644 index 000000000..b05d80f8f Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/Mono.Unix.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.Buffers.dll b/bin/netcore/engines/IPY2712PR/System.Buffers.dll new file mode 100644 index 000000000..c517a3b62 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.Buffers.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.CodeDom.dll b/bin/netcore/engines/IPY2712PR/System.CodeDom.dll new file mode 100644 index 000000000..9ddbb1847 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.CodeDom.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.Memory.dll b/bin/netcore/engines/IPY2712PR/System.Memory.dll new file mode 100644 index 000000000..bdfc501e9 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.Memory.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.Numerics.Vectors.dll b/bin/netcore/engines/IPY2712PR/System.Numerics.Vectors.dll new file mode 100644 index 000000000..a808165ac Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.Numerics.Vectors.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.Reflection.Emit.ILGeneration.dll b/bin/netcore/engines/IPY2712PR/System.Reflection.Emit.ILGeneration.dll new file mode 100644 index 000000000..544d91b68 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.Reflection.Emit.ILGeneration.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.Reflection.Emit.Lightweight.dll b/bin/netcore/engines/IPY2712PR/System.Reflection.Emit.Lightweight.dll new file mode 100644 index 000000000..61937e8d5 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.Reflection.Emit.Lightweight.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.Reflection.Emit.dll b/bin/netcore/engines/IPY2712PR/System.Reflection.Emit.dll new file mode 100644 index 000000000..1a3feb756 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.Reflection.Emit.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.Runtime.CompilerServices.Unsafe.dll b/bin/netcore/engines/IPY2712PR/System.Runtime.CompilerServices.Unsafe.dll new file mode 100644 index 000000000..0c27a0e21 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.Runtime.CompilerServices.Unsafe.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.Security.AccessControl.dll b/bin/netcore/engines/IPY2712PR/System.Security.AccessControl.dll new file mode 100644 index 000000000..36fb33af4 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.Security.AccessControl.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.Security.Principal.Windows.dll b/bin/netcore/engines/IPY2712PR/System.Security.Principal.Windows.dll new file mode 100644 index 000000000..19d0fc0e9 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.Security.Principal.Windows.dll differ diff --git a/bin/netcore/engines/IPY2712PR/System.Text.Encoding.CodePages.dll b/bin/netcore/engines/IPY2712PR/System.Text.Encoding.CodePages.dll new file mode 100644 index 000000000..a7fe6d147 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/System.Text.Encoding.CodePages.dll differ diff --git a/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.Modules.dll b/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.Modules.dll new file mode 100644 index 000000000..b1d2480fc Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.Modules.dll differ diff --git a/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.SQLite.dll b/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.SQLite.dll new file mode 100644 index 000000000..d257860e7 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.SQLite.dll differ diff --git a/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.Wpf.dll b/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.Wpf.dll new file mode 100644 index 000000000..371f30124 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.Wpf.dll differ diff --git a/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.dll b/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.dll new file mode 100644 index 000000000..36319c152 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/pyRevitLabs.IronPython.dll differ diff --git a/bin/netcore/engines/IPY2712PR/pyRevitLabs.Microsoft.Dynamic.dll b/bin/netcore/engines/IPY2712PR/pyRevitLabs.Microsoft.Dynamic.dll new file mode 100644 index 000000000..d55d280cd Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/pyRevitLabs.Microsoft.Dynamic.dll differ diff --git a/bin/netcore/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll b/bin/netcore/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll new file mode 100644 index 000000000..7bf981cd3 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll differ diff --git a/bin/netcore/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.dll b/bin/netcore/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.dll new file mode 100644 index 000000000..d00ce0d25 Binary files /dev/null and b/bin/netcore/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.dll differ diff --git a/dev/libs/IronPython/python_2711pr_lib.zip b/bin/netcore/engines/IPY2712PR/pyRevitLoader.dll similarity index 99% rename from dev/libs/IronPython/python_2711pr_lib.zip rename to bin/netcore/engines/IPY2712PR/pyRevitLoader.dll index 5ad228cf1..28539103e 100644 Binary files a/dev/libs/IronPython/python_2711pr_lib.zip and b/bin/netcore/engines/IPY2712PR/pyRevitLoader.dll differ diff --git a/bin/engines/IPY2711PR/pyRevitLoader.dll b/bin/netcore/engines/IPY2712PR/pyRevitRunner.dll similarity index 99% rename from bin/engines/IPY2711PR/pyRevitLoader.dll rename to bin/netcore/engines/IPY2712PR/pyRevitRunner.dll index e744c823e..2e6986d02 100644 Binary files a/bin/engines/IPY2711PR/pyRevitLoader.dll and b/bin/netcore/engines/IPY2712PR/pyRevitRunner.dll differ diff --git a/bin/netcore/engines/IPY340PR/Mono.Unix.dll b/bin/netcore/engines/IPY340PR/Mono.Unix.dll new file mode 100644 index 000000000..b05d80f8f Binary files /dev/null and b/bin/netcore/engines/IPY340PR/Mono.Unix.dll differ diff --git a/bin/netcore/engines/IPY340PR/System.CodeDom.dll b/bin/netcore/engines/IPY340PR/System.CodeDom.dll new file mode 100644 index 000000000..54c82b665 Binary files /dev/null and b/bin/netcore/engines/IPY340PR/System.CodeDom.dll differ diff --git a/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.Modules.dll b/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.Modules.dll new file mode 100644 index 000000000..f07d03b8b Binary files /dev/null and b/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.Modules.dll differ diff --git a/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.SQLite.dll b/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.SQLite.dll new file mode 100644 index 000000000..194f603ca Binary files /dev/null and b/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.SQLite.dll differ diff --git a/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.Wpf.dll b/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.Wpf.dll new file mode 100644 index 000000000..f2de9338b Binary files /dev/null and b/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.Wpf.dll differ diff --git a/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.dll b/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.dll new file mode 100644 index 000000000..86e394ecd Binary files /dev/null and b/bin/netcore/engines/IPY340PR/pyRevitLabs.IronPython.dll differ diff --git a/bin/netcore/engines/IPY340PR/pyRevitLabs.Microsoft.Dynamic.dll b/bin/netcore/engines/IPY340PR/pyRevitLabs.Microsoft.Dynamic.dll new file mode 100644 index 000000000..f49c8b1ed Binary files /dev/null and b/bin/netcore/engines/IPY340PR/pyRevitLabs.Microsoft.Dynamic.dll differ diff --git a/bin/netcore/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll b/bin/netcore/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll new file mode 100644 index 000000000..a4046fc62 Binary files /dev/null and b/bin/netcore/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll differ diff --git a/bin/netcore/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.dll b/bin/netcore/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.dll new file mode 100644 index 000000000..d908143d6 Binary files /dev/null and b/bin/netcore/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.dll differ diff --git a/bin/engines/pyRevitLoader.py b/bin/netcore/engines/pyRevitLoader.py similarity index 96% rename from bin/engines/pyRevitLoader.py rename to bin/netcore/engines/pyRevitLoader.py index 5b45c4a67..7a67b1d34 100644 --- a/bin/engines/pyRevitLoader.py +++ b/bin/netcore/engines/pyRevitLoader.py @@ -23,7 +23,7 @@ import os.path as op # add the library location to the system search paths -repo_path = op.dirname(op.dirname(op.dirname(__file__))) +repo_path = op.dirname(op.dirname(op.dirname(op.dirname(__file__)))) sys.path.append(op.join(repo_path, 'pyrevitlib')) # now pyrevit can be imported diff --git a/bin/netcore/pyRevitLabs.Emojis.dll b/bin/netcore/pyRevitLabs.Emojis.dll new file mode 100644 index 000000000..ca3af7d6d Binary files /dev/null and b/bin/netcore/pyRevitLabs.Emojis.dll differ diff --git a/bin/netcore/pyrevit-doctor.runtimeconfig.json b/bin/netcore/pyrevit-doctor.runtimeconfig.json new file mode 100644 index 000000000..d78451564 --- /dev/null +++ b/bin/netcore/pyrevit-doctor.runtimeconfig.json @@ -0,0 +1,13 @@ +{ + "runtimeOptions": { + "tfm": "net8.0", + "framework": { + "name": "Microsoft.NETCore.App", + "version": "8.0.0" + }, + "configProperties": { + "System.Reflection.Metadata.MetadataUpdater.IsSupported": false, + "System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false + } + } +} \ No newline at end of file diff --git a/bin/netcore/pyrevit-hosts.json b/bin/netcore/pyrevit-hosts.json new file mode 100644 index 000000000..4fcbe5c5a --- /dev/null +++ b/bin/netcore/pyrevit-hosts.json @@ -0,0 +1,1863 @@ +[ + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2008 Architecture Service Pack 1", + "version": "", + "build": "20070607_1700", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2008 Architecture Service Pack 2", + "version": "", + "build": "20070810_1700", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://forums.autodesk.com/t5/revit-architecture-forum/sp3-build-20080101-2345/td-p/2152807" + }, + "product": "Autodesk Revit", + "release": "2008 Architecture Service Pack 3", + "version": "", + "build": "20080101_2345", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2009 Architecture Service Pack 1", + "version": "", + "build": "20080602_1900", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2009 Architecture Service Pack 2", + "version": "", + "build": "20080915_2100", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2009 Architecture Service Pack 3", + "version": "", + "build": "20081118_1045", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://forums.autodesk.com/t5/revit-architecture-forum/sp3-build-20080101-2345/td-p/2152807" + }, + "product": "Autodesk Revit", + "release": "2010 Architecture Service Pack 1", + "version": "", + "build": "20090612_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2010 Architecture Service Pack 2", + "version": "", + "build": "20090917_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://forums.augi.com/showthread.php?138574-Revit-Architecture-Door-Centerline-not-selectable-during-dimensioning" + }, + "product": "Autodesk Revit", + "release": "2011 Architecture", + "version": "", + "build": "20100326_1700", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://revitclinic.typepad.com/my_weblog/2010/06/revit-2011-build-number-update-display.html" + }, + "product": "Autodesk Revit", + "release": "2011 Architecture Service Pack 1", + "version": "", + "build": "20100615_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/downloads/caas/downloads/content/hotfix--E2-80-93-black-preview-swatch.html?v=2011" + }, + "product": "Autodesk Revit", + "release": "2011 Hotfix - Black Preview Swatch", + "version": "", + "build": "20100903_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/downloads/caas/downloads/content/hotfix-autodesk-revit-architecture-2011-colorfills.html?v=2011" + }, + "product": "Autodesk Revit", + "release": "2011 Hotfix - Color Fills", + "version": "", + "build": "20110218_1300", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2012 First Customer Ship", + "version": "", + "build": "20110309_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2012 Update Release 1", + "version": "", + "build": "20110622_0930", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2012 Update Release 2", + "version": "", + "build": "20110916_2132", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2013 First Customer Ship", + "version": "12.02.21203", + "build": "20120221_2030", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2013 Update Release 1", + "version": "", + "build": "20120716_1115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2013 Update Release 2", + "version": "", + "build": "20121003_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://github.com/eirannejad/pyRevit/issues/622" + }, + "product": "Autodesk Revit", + "release": "2013 Update Release 3", + "version": "12.11.10090", + "build": "20130531_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2013 LT First Customer Ship", + "version": "", + "build": "20120821_1330", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2013 LT Update Release 1", + "version": "", + "build": "20130531_0300", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2014 First Customer Ship", + "version": "13.03.08151", + "build": "20130308_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2014 Update Release 1", + "version": "", + "build": "20130709_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2014 Update Release 2", + "version": "", + "build": "20131024_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "//https://github.com/eirannejad/pyRevit/issues/543" + }, + "product": "Autodesk Revit", + "release": "2014 Update Release 3", + "version": "13.11.00004", + "build": "20140709_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/downloads/caas/downloads/content/autodesk-revit-2015-product-updates.html" + }, + "product": "Autodesk Revit", + "release": "2015 First Customer Ship", + "version": "15.0.136.0", + "build": "20140223_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/downloads/caas/downloads/content/autodesk-revit-2015-product-updates.html" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 1", + "version": "15.0.136.0", + "build": "20140322_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/downloads/caas/downloads/content/autodesk-revit-2015-product-updates.html" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 2", + "version": "15.0.166.0", + "build": "20140323_1530", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 3", + "version": "15.0.207.0", + "build": "20140606_1530", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 4", + "version": "15.0.270.0", + "build": "20140903_1530", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 (Subscription only release)", + "version": "15.0.1103.0", + "build": "20140905_0730", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 5", + "version": "15.0.310.0", + "build": "20141119_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 5 (Subscription only release)", + "version": "15.0.1133.0", + "build": "20141119_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 6", + "version": "15.0.315.0", + "build": "20150127_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 6 (Subscription only release)", + "version": "15.0.1142.0", + "build": "20150127_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 7", + "version": "15.0.318.0", + "build": "20150303_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 7 (Subscription only release)", + "version": "15.0.1148.0", + "build": "20150303_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 8", + "version": "15.0.341.0", + "build": "20150512_1015", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 8 (Subscription only release)", + "version": "15.0.1170.0", + "build": "20150511_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 9", + "version": "15.0.361.0", + "build": "20150702_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 9 (Subscription only release)", + "version": "15.0.1190.0", + "build": "20150704_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 10", + "version": "15.0.379.0", + "build": "20151007_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 10 (Subscription only release)", + "version": "15.0.1203.0", + "build": "20151008_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 11 *Issue with Revit Server", + "version": "15.0.390.0", + "build": "20151207_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 11 (Subscription only release) *Issue with Revit Server", + "version": "15.0.1225.0", + "build": "20151208_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 12", + "version": "15.0.403.0", + "build": "20160119_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 12 (Subscription only release)", + "version": "15.0.1238.0", + "build": "20160120_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 13", + "version": "15.0.406.0", + "build": "20160220_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 13 (Subscription only release)", + "version": "15.0.1243.0", + "build": "20160220_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 14", + "version": "15.0.421.0", + "build": "20160512_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 14 (Subscription only release)", + "version": "15.0.1259.0", + "build": "20160512_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 First Customer Ship", + "version": "16.0.428.0", + "build": "20150220_1215", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Service Pack 1", + "version": "16.0.462.0", + "build": "20150506_1715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/Revit-2016-Release-2-Error-1642.html" + }, + "product": "Autodesk Revit", + "release": "2016 Unreleased Update", + "version": "16.0.485.0", + "build": "20150701_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Service Pack 2", + "version": "16.0.490.0", + "build": "20150714_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Release 2 (R2)", + "version": "16.0.1063", + "build": "20151007_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 1 for R2", + "version": "16.0.1092.0", + "build": "20151209_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 2 for R2", + "version": "16.0.1108.0", + "build": "20160126_1600", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 3 for R2", + "version": "16.0.1118.0", + "build": "20160217_1800", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 4 for R2", + "version": "16.0.1124.0", + "build": "20160314_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 5 for R2", + "version": "16.0.1144.0", + "build": "20160525_1230", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 6 for R2", + "version": "16.0.1161.0", + "build": "20160720_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 7 for R2", + "version": "16.0.1185.0", + "build": "20161004_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://revit.downloads.autodesk.com/download/2016_1_9_RVT/Docs/RelNotes/Autodesk_Revit_2016_1_9_ReleaseNotes.html" + }, + "product": "Autodesk Revit", + "release": "2016.1.8 Update", + "version": "16.0.1205.0", + "build": "20170117_1200", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2016/RVT/Autodesk_Revit_2016_1_9_Readme.htm" + }, + "product": "Autodesk Revit", + "release": "2016.1.9 Security Fix", + "version": "16.0.1218.0", + "build": "20190508_0715", + "target": "x64", + "notes": "https://up.autodesk.com/2016/RVT/Autodesk_Revit_2016_1_9_Readme.htm" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017 First Customer Ship", + "version": "17.0.416.0", + "build": "20160225_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017 Service Pack 1", + "version": "17.0.476.0", + "build": "20160606_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017 Service Pack 2", + "version": "17.0.501.0", + "build": "20160720_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.0.3", + "version": "17.0.503.0", + "build": "20161205_1400", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.1", + "version": "17.0.1081.0", + "build": "20161006_0315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.1.1", + "version": "17.0.1099.0", + "build": "20161117_1200", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.2", + "version": "17.0.1117.0", + "build": "20170118_1100", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.2.1", + "version": "17.0.1128.0", + "build": "20170419_0315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.2.2", + "version": "17.0.1146.0", + "build": "20170816_0615", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.2.3", + "version": "17.0.1150.0", + "build": "20171027_0315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://github.com/eirannejad/pyRevit/issues/456" + }, + "product": "Autodesk Revit", + "release": "2017.0.4", + "version": "17.0.511.0", + "build": "20181011_1545", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2017/RVT/Autodesk_Revit_2017_0_5_Readme.htm" + }, + "product": "Autodesk Revit", + "release": "2017.0.5 Security Fix", + "version": "17.0.517.0", + "build": "20190507_1515", + "target": "x64", + "notes": "https://up.autodesk.com/2017/RVT/Autodesk_Revit_2017_0_5_Readme.htm" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.2.4", + "version": "17.0.1158.0", + "build": "20181011_1645", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2017/RVT/Autodesk_Revit_2017_2_5_Readme.htm" + }, + "product": "Autodesk Revit", + "release": "2017.2.5 Security Fix", + "version": "17.0.1169.0", + "build": "20190508_0315", + "target": "x64", + "notes": "https://up.autodesk.com/2017/RVT/Autodesk_Revit_2017_2_5_Readme.htm" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018 First Customer Ship", + "version": "18.0.0.420", + "build": "20170223_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.0.1", + "version": "18.0.1.2", + "build": "20170421_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.0.2", + "version": "18.0.2.11", + "build": "20170525_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2018/RVT/Autodesk_Revit_2018_0_3_Readme.htm" + }, + "product": "Autodesk Revit", + "release": "2018.0.3", + "version": "18.0.3.6", + "build": "20181015_0930", + "target": "x64", + "notes": "https://up.autodesk.com/2018/RVT/Autodesk_Revit_2018_0_3_Readme.htm" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.1", + "version": "18.1.0.92", + "build": "20170630_0700", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.1.1", + "version": "18.1.1.18", + "build": "20170907_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.2", + "version": "18.2.0.51", + "build": "20170927_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://github.com/eirannejad/pyRevit/issues/456" + }, + "product": "Autodesk Revit", + "release": "2018.3", + "version": "18.3.0.81", + "build": "20180329_1100", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.3.1", + "version": "18.3.1.2", + "build": "20180423_1000", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.3.2", + "version": "18.3.2.7", + "build": "20181011_1500", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2018/RVT/Autodesk_Revit_2018_3_3_Readme.htm" + }, + "product": "Autodesk Revit", + "release": "2018.3.3 Security Fix", + "version": "18.3.3.18", + "build": "20190510_1515", + "target": "x64", + "notes": "https://up.autodesk.com/2018/RVT/Autodesk_Revit_2018_3_3_Readme.htm" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019 First Customer Ship", + "version": "19.0.0.405", + "build": "20180216_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019 Update for Trial Build", + "version": "19.0.1.1", + "build": "20180328_1600", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019.0.1", + "version": "19.0.10.18", + "build": "20180518_1600", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019.0.2", + "version": "19.0.20.1", + "build": "20180927_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019.1", + "version": "19.1.0.112", + "build": "20180806_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019.2 (Update)", + "version": "19.2.0.65", + "build": "20181217_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://twitter.com/JarodJSchultz/status/1100459171491676160" + }, + "product": "Autodesk Revit", + "release": "2019.2 (Full Install)", + "version": "19.2.1.1", + "build": "20190108_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_1_Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.1", + "version": "19.2.10.7", + "build": "20190225_1515", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_1_Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_2_Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.2 Hotfix", + "version": "19.2.20.24", + "build": "20190808_0900", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_2_Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2020 First Customer Ship", + "version": "20.0.0.377", + "build": "20190327_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_0_1_Resolved_Issues_html" + }, + "product": "Autodesk Revit", + "release": "2020.0.1 Hotfix", + "version": "20.0.1.2", + "build": "20190412_1200", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_0_1_Resolved_Issues_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_1_html" + }, + "product": "Autodesk Revit", + "release": "2020.1 (Update)", + "version": "20.1.0.81", + "build": "20190725_1135", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/learn-explore/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2020.1 (Full Install)", + "version": "20.1.1.1", + "build": "20190731_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_html" + }, + "product": "Autodesk Revit", + "release": "2020.2 (Update)", + "version": "20.2.0.48", + "build": "20191031_1115", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2 (Full Install)", + "version": "20.2.1.1", + "build": "20191106_1200", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.2 (Full Install)", + "version": "20.2.11.3", + "build": "20200206_0915", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_2_Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.2 Hotfix", + "version": "19.2.20.24", + "build": "20190808_0900", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_2_Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021release_html" + }, + "product": "Autodesk Revit", + "release": "2021 First Customer Ship", + "version": "21.0.0.383", + "build": "20200220_1100", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021release_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.1 (New Install)", + "version": "20.2.12.1", + "build": "20200210_1400", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.2", + "version": "20.2.20.31", + "build": "20200426_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_html" + }, + "product": "Autodesk Revit", + "release": "2021.1", + "version": "21.1.0.108", + "build": "20200708_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_3_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.3", + "version": "20.2.30.42", + "build": "20200826_1250", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_3_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_1_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.1", + "version": "21.1.10.26", + "build": "20200909_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.2", + "version": "21.1.20.44", + "build": "20201109_1530", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_html" + }, + "product": "Autodesk Revit", + "release": "2022 First Customer Ship", + "version": "22.0.2.392", + "build": "20210224_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_3_Hotfix_Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.3", + "version": "19.2.30.41", + "build": "20210416_1515", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_3_Hotfix_Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.4", + "version": "20.2.40.65", + "build": "20210420_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.3", + "version": "21.1.30.74", + "build": "20210426_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_html" + }, + "product": "Autodesk Revit", + "release": "2022.0.1", + "version": "22.0.10.28", + "build": "20210616_0115", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.4", + "version": "21.1.40.95", + "build": "20210805_1400", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.5", + "version": "20.2.50.77", + "build": "20210804_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_html" + }, + "product": "Autodesk Revit", + "release": "2022.1", + "version": "22.1.1.516", + "build": "20210921_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_1_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.1", + "version": "22.1.10.541", + "build": "20211103_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_5_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.5", + "version": "21.1.50.27", + "build": "20211018_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_5_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_6_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.6", + "version": "20.2.60.15", + "build": "20211019_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_6_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://revit.downloads.autodesk.com/download/2019_2_4_RVT/Docs/RelNotes/Autodesk_Revit_2019_2_4_ReleaseNotes.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.4", + "version": "19.2.40.15", + "build": "20211029_1515", + "target": "x64", + "notes": "https://revit.downloads.autodesk.com/download/2019_2_4_RVT/Docs/RelNotes/Autodesk_Revit_2019_2_4_ReleaseNotes.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_6_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.6", + "version": "21.1.60.25", + "build": "20220123_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_6_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_2_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.2", + "version": "22.1.21.13", + "build": "20220123_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_7_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.7", + "version": "20.2.70.6", + "build": "20220112_1230", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_7_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Revit-2019.2.5-Hotfix-Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.5", + "version": "19.2.50.16", + "build": "20220111_1110", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Revit-2019.2.5-Hotfix-Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023release_html" + }, + "product": "Autodesk Revit", + "release": "2023 First Customer Ship", + "version": "23.0.1.318", + "build": "20220304_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023release_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit/learn-explore/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2023.0.1", + "version": "23.0.10.18", + "build": "20220429_1500", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_8_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.8", + "version": "20.2.80.2", + "build": "20220225_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_8_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Revit-2019.2.6-Hotfix-Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.6", + "version": "19.2.60.3", + "build": "20220224_1700", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Revit-2019.2.6-Hotfix-Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_9_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.9", + "version": "20.2.90.12", + "build": "20220517_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_9_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_7_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.7", + "version": "21.1.70.21", + "build": "20220517_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_7_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_8_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.8", + "version": "21.1.80.35", + "build": "20230515_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_8_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_9_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.9", + "version": "21.1.90.15", + "build": "20230907_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_9_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_3_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.3", + "version": "22.1.30.34", + "build": "20220520_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_3_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_4_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.4", + "version": "22.1.40.58", + "build": "20230505_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_4_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_5_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.5", + "version": "22.1.50.17", + "build": "20230915_1530", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_5_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_0_2_html" + }, + "product": "Autodesk Revit", + "release": "2023.0.2", + "version": "23.0.20.21", + "build": "20220726_1500", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_0_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_html" + }, + "product": "Autodesk Revit", + "release": "2023.1", + "version": "23.1.1.24", + "build": "20221114_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_1_html" + }, + "product": "Autodesk Revit", + "release": "2023.1.1", + "version": "23.1.10.4", + "build": "20221122_1550", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_1_1_html" + }, + "product": "Autodesk Revit", + "release": "2023.1.1.1", + "version": "23.1.10.4", + "build": "20221122_1550", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_1_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + }, + "product": "Autodesk Revit", + "release": "23.1.2", + "version": "23.1.20.70", + "build": "20230510_1100", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + }, + "product": "Autodesk Revit", + "release": "23.1.2", + "version": "23.1.20.70", + "build": "20230510_1100", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + }, + + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_3_html" + }, + "product": "Autodesk Revit", + "release": "23.1.3", + "version": "23.1.30.97", + "build": "20230828_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_3_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.autodesk.com/support/technical/article/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2024 First Customer Ship", + "version": "24.0.4.427", + "build": "20230308_1635", + "target": "x64", + "notes": "https://www.autodesk.com/support/technical/article/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024release_html" + }, + "product": "Autodesk Revit", + "release": "2024.0.1", + "version": "24.0.5.432", + "build": "20230411_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024release_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_0_2_html" + }, + "product": "Autodesk Revit", + "release": "2024.0.2", + "version": "24.0.20.20", + "build": "20230509_0315", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_0_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_1_html" + }, + "product": "Autodesk Revit", + "release": "24.1", + "version": "24.1.0.66", + "build": "20230701_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_1_1_html" + }, + "product": "Autodesk Revit", + "release": "24.1.1", + "version": "24.1.10.25", + "build": "20230830_0315", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_1_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_2_html" + }, + "product": "Autodesk Revit", + "release": "24.2", + "version": "24.2.0.63", + "build": "20231029_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2025/ENU/?guid=GUID-C81929D7-02CB-4BF7-A637-9B98EC9EB38B" + }, + "product": "Autodesk Revit", + "release": "25.0", + "version": "25.0.2.419", + "build": "20240307_1300", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2025/ENU/?guid=GUID-C81929D7-02CB-4BF7-A637-9B98EC9EB38B" + } +] diff --git a/bin/netcore/pyrevit-products.json b/bin/netcore/pyrevit-products.json new file mode 100644 index 000000000..7c1d9fa36 --- /dev/null +++ b/bin/netcore/pyrevit-products.json @@ -0,0 +1,476 @@ +[ + { + "product": "pyRevit", + "release": "4.8.14.24016+1909", + "version": "4.8.14.24016+1909", + "key": "f2a3da53-6f34-41d5-abbd-389ffa7f4d5f" + }, + { + "product": "pyRevit", + "release": "4.8.13.23182+2215", + "version": "4.8.13.23182+2215", + "key": "6a6637c3-859c-4fba-9ed9-03957adee956" + }, + { + "product": "pyRevit", + "release": "4.8.12.22247+0031", + "version": "4.8.12.22247+0031", + "key": "a241ce67-c9b1-41f8-8c20-65d6de92db16" + }, + { + "product": "pyRevit", + "release": "4.8.11.22151+0454", + "version": "4.8.11.22151+0454", + "key": "ee4c9248-a3a4-4a4a-bed8-7a1c28102bc1" + }, + { + "product": "pyRevit", + "release": "4.8.10.22040+1743", + "version": "4.8.10.22040+1743", + "key": "d56fb4d2-b004-4508-bf3d-8ebd5cb466b7" + }, + { + "product": "pyRevit", + "release": "4.8.9.21361+0320", + "version": "4.8.9.21361+0320", + "key": "56307bc9-65f7-4f28-b701-cb88d141b592" + }, + { + "product": "pyRevit", + "release": "4.8.9.21359+1855", + "version": "4.8.9.21359+1855", + "key": "c4bdcf02-55f0-49e4-8db2-6d9bf5bb8287" + }, + { + "product": "pyRevit", + "release": "4.8.8", + "version": "4.8.8", + "key": "{CA372AB6-355A-4270-91DD-144DF75E1B57}" + }, + { + "product": "pyRevit", + "release": "4.8.7", + "version": "4.8.7", + "key": "{FED5DEF7-8D3B-4832-BB3E-55C10FCF9ACF}" + }, + { + "product": "pyRevit", + "release": "4.8.6", + "version": "4.8.6", + "key": "{32B7C208-2ACC-4D2B-9C75-5BAEE22E7F85}" + }, + { + "product": "pyRevit", + "release": "4.8.5", + "version": "4.8.5", + "key": "{F13EA93D-4DB1-4149-A86A-B0EFE54ED6AC}" + }, + { + "product": "pyRevit", + "release": "4.8.4", + "version": "4.8.4", + "key": "{CA4CAB91-D337-4A68-BCF7-D56B77327D3A}" + }, + { + "product": "pyRevit", + "release": "4.8.3", + "version": "4.8.3", + "key": "{696310B4-5E37-4437-B047-20954E4B2814}" + }, + { + "product": "pyRevit", + "release": "4.8.2", + "version": "4.8.2", + "key": "{ECFE3DF3-2276-4A11-BA07-9F166AFE4693}" + }, + { + "product": "pyRevit", + "release": "4.8.1", + "version": "4.8.1", + "key": "{311A0079-4026-4F30-9288-619E8824DCA5}" + }, + { + "product": "pyRevit", + "release": "4.8.0", + "version": "4.8.0", + "key": "{CDA0124F-714E-4F93-BF5D-37FF54C25F15}" + }, + { + "product": "pyRevit", + "release": "4.7.6", + "version": "4.7.6", + "key": "{57D90459-1106-444E-A9DC-DC68435BBAEE}" + }, + { + "product": "pyRevit", + "release": "4.7.5", + "version": "4.7.5", + "key": "{40BE31F6-E27A-49D0-ABF5-67778407DD6F}" + }, + { + "product": "pyRevit", + "release": "4.7 Final", + "version": "4.7.4", + "key": "{8A28EE04-5F33-409A-A3B2-7B38FFF2ADF1}" + }, + { + "product": "pyRevit", + "release": "4.7-beta4", + "version": "4.7.3", + "key": "{4D75C52D-F32E-486A-ADED-C7E77E3A8687}" + }, + { + "product": "pyRevit", + "release": "4.7-beta3", + "version": "4.7.2", + "key": "{83110B68-9131-4D58-95AB-D05D785A22E1}" + }, + { + "product": "pyRevit", + "release": "4.7-beta2", + "version": "4.7.1", + "key": "{D719552C-6D81-4436-BF06-5F024C83313A}" + }, + { + "product": "pyRevit", + "release": "4.6.24", + "version": "4.6.24", + "key": "{C125D1FC-A13B-4D52-B642-D279DF321191}" + }, + { + "product": "pyRevit", + "release": "4.6.23", + "version": "4.6.23", + "key": "{3C05CBFF-8250-41EA-B91B-93967E436EFF}" + }, + { + "product": "pyRevit", + "release": "4.6.22", + "version": "4.6.22", + "key": "{D763A045-F988-4C82-9A94-20645FAD8D83}" + }, + { + "product": "pyRevit", + "release": "4.6.21", + "version": "4.6.21", + "key": "{DB9FCA88-7183-4A7E-9842-798975628854}" + }, + { + "product": "pyRevit", + "release": "4.6.20", + "version": "4.6.20", + "key": "{2FA86D06-A1A1-4908-BEB9-877B62D28D75}" + }, + { + "product": "pyRevit", + "release": "4.6.19", + "version": "4.6.19", + "key": "{BFEA01ED-43D5-4B73-8C7D-01A075B1F967}" + }, + { + "product": "pyRevit", + "release": "4.6.18", + "version": "4.6.18", + "key": "{21D49B9A-05AA-4E2F-8744-1653C37AC5D6}" + }, + { + "product": "pyRevit", + "release": "4.6.17", + "version": "4.6.17", + "key": "{309D684B-5279-4DA7-89AE-0870AECDEA4D}" + }, + { + "product": "pyRevit", + "release": "4.6.16", + "version": "4.6.16", + "key": "{8A958BB7-C38A-417B-8818-EF3FF1F6615F}" + }, + { + "product": "pyRevit", + "release": "4.7-beta", + "version": "4.7.0", + "key": "{70FAC724-6300-4037-9178-6A0002B98A65}" + }, + { + "product": "pyRevit", + "release": "4.6.15", + "version": "4.6.15", + "key": "{67AA2183-02A8-4851-9653-1BEA54E0F9A1}" + }, + { + "product": "pyRevit", + "release": "4.6.14", + "version": "4.6.14", + "key": "{2FE2F748-8EF1-4012-9CEE-5A8AA9BF1114}" + }, + { + "product": "pyRevit", + "release": "4.6.13", + "version": "4.6.13", + "key": "{A596729B-C818-48EB-85E6-957B5537328F}" + }, + { + "product": "pyRevit", + "release": "4.6.12", + "version": "4.6.12", + "key": "{F013A175-38C0-436F-9234-6163E45C3B52}" + }, + { + "product": "pyRevit", + "release": "4.6.11", + "version": "4.6.11", + "key": "{98A0A70D-7F59-4937-A6B9-00A1E2EAC294}" + }, + { + "product": "pyRevit", + "release": "4.6.10", + "version": "4.6.10", + "key": "{6A1713AA-256C-4F10-AB96-DD12A225677E}" + }, + { + "product": "pyRevit", + "release": "4.6.9", + "version": "4.6.9", + "key": "{26F3AF6F-DC19-41BF-98BE-C39C56C413D2}" + }, + { + "product": "pyRevit", + "release": "4.6.8", + "version": "4.6.8", + "key": "{C433FE4C-BE21-405D-8D7B-043392763FC7}" + }, + { + "product": "pyRevit", + "release": "4.6.7", + "version": "4.6.7", + "key": "{B105FB5A-0ACF-4A07-9A14-057886D5E25D}" + }, + { + "product": "pyRevit", + "release": "4.6.6", + "version": "4.6.6", + "key": "{E119DE40-5871-479A-96E9-C2AE4F9C424B}" + }, + { + "product": "pyRevit", + "release": "4.6.5", + "version": "4.6.5", + "key": "{FC761B9E-3699-419C-A5DE-DEC361C1F6A7}" + }, + { + "product": "pyRevit", + "release": "4.6.4", + "version": "4.6.4", + "key": "{37CFAD58-51D0-4248-90E0-893058455ED1}" + }, + { + "product": "pyRevit", + "release": "4.6.3", + "version": "4.6.3", + "key": "{63160AFE-5B53-49AF-B46B-527BCBA0AC6E}" + }, + { + "product": "pyRevit", + "release": "4.6.2", + "version": "4.6.2", + "key": "{31A23489-A61B-4786-A857-F95DEB45573C}" + }, + { + "product": "pyRevit", + "release": "4.6.1", + "version": "4.6.1", + "key": "{EF91A585-DC0C-43B8-B88B-4C130F430E84}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.14.24016+1909", + "version": "4.8.14.24016+1909", + "key": "9557b432-cf79-4ece-91cf-b8f996c88b47" + }, + { + "product": "pyRevit CLI", + "release": "4.8.13.23182+2215", + "version": "4.8.13.23182+2215", + "key": "48b17832-a795-41fe-ac44-29ce052b3dba" + }, + { + "product": "pyRevit CLI", + "release": "4.8.12.22247+0031", + "version": "4.8.12.22247+0031", + "key": "52cc6210-7507-4dd3-9b18-6314d2c0abc4" + }, + { + "product": "pyRevit CLI", + "release": "4.8.11.22151+0454", + "version": "4.8.11.22151+0454", + "key": "942e8317-c392-4020-9fe8-15e8ddb1df45" + }, + { + "product": "pyRevit CLI", + "release": "4.8.10.22040+1743", + "version": "4.8.10.22040+1743", + "key": "a77c5ef7-194d-4211-810e-720a7957f0c1" + }, + { + "product": "pyRevit CLI", + "release": "4.8.9.21361+0320", + "version": "4.8.9.21361+0320", + "key": "e71ec326-b624-4530-b236-ecd0ba1b4a99" + }, + { + "product": "pyRevit CLI", + "release": "4.8.9.21359+1855", + "version": "4.8.9.21359+1855", + "key": "5d419b28-c737-4fd3-9c33-6da59628a443" + }, + { + "product": "pyRevit CLI", + "release": "4.8.8", + "version": "4.8.8", + "key": "{8E0191BC-C5DB-4F0E-8F52-6DF04C2B8CE8}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.7", + "version": "4.8.7", + "key": "{E61BB97E-6FF1-4706-A92E-D9F38EB9C77B}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.6", + "version": "4.8.6", + "key": "{AB14082F-168E-45DE-98A7-7C99DB00FFE7}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.5", + "version": "4.8.5", + "key": "{AA15AF8E-2D65-40EF-A9E6-C920D83984E0}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.4", + "version": "4.8.4", + "key": "{EF5EC593-2F57-44D8-8456-CFB05247ADA0}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.3", + "version": "4.8.3", + "key": "{F0958CD1-EEF8-481D-871C-7501947EC650}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.2", + "version": "4.8.2", + "key": "{667ABAF1-CF3A-4CF6-AF75-68F5CA26BFA6}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.1", + "version": "4.8.1", + "key": "{7FE9A723-CD7C-47E8-A0E6-C8452F0AE64E}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.0", + "version": "4.8.0", + "key": "{A0465103-77E8-4880-8192-9D055744798B}" + }, + { + "product": "pyRevit CLI", + "release": "0.25.0", + "version": "0.25.0", + "key": "{27F44ADD-E91B-4733-B4FC-51473A2FAC3D}" + }, + { + "product": "pyRevit CLI", + "release": "0.24.0", + "version": "0.24.0", + "key": "{21E2B6B9-B39B-4482-99C0-C83B93181870}" + }, + { + "product": "pyRevit CLI", + "release": "0.21.0", + "version": "0.21.0", + "key": "{8D13B375-35DF-4A04-8A47-BF4A8C843ADB}" + }, + { + "product": "pyRevit CLI", + "release": "0.17.0", + "version": "0.17.0", + "key": "{4D1CD2D8-BDCD-4B44-A71B-1775AF4A4EA9}" + }, + { + "product": "pyRevit CLI", + "release": "0.16.0", + "version": "0.16.0", + "key": "{835919B1-5715-4E3C-8112-BB941FA435E8}" + }, + { + "product": "pyRevit CLI", + "release": "0.15.0", + "version": "0.15.0", + "key": "{A90B8942-A3EB-4AA5-96BE-2EE2606C69A6}" + }, + { + "product": "pyRevit CLI", + "release": "0.14.0", + "version": "0.14.0", + "key": "{F1F6254F-1465-4B0D-A4DE-24D2D297AE30}" + }, + { + "product": "pyRevit CLI", + "release": "0.13.0", + "version": "0.13.0", + "key": "{0D50CCF6-35DF-47A2-B13A-D442C835FFB5}" + }, + { + "product": "pyRevit CLI", + "release": "0.12.0", + "version": "0.12.0", + "key": "{B6BA75F8-61A0-42CA-9E03-17503460854E}" + }, + { + "product": "pyRevit CLI", + "release": "0.11.0", + "version": "0.11.0", + "key": "{3B7168BD-E66B-4CF0-B22E-87A3BB809384}" + }, + { + "product": "pyRevit CLI", + "release": "0.10.0", + "version": "0.10.0", + "key": "{949D5537-B9CA-45B0-B69E-CF627F8F2923}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.8", + "version": "0.9.8", + "key": "{D5505166-C49A-436F-B25A-9FBD0632F6F0}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.7", + "version": "0.9.7", + "key": "{D5505166-C49A-436F-B25A-9FBD0632F6F0}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.6", + "version": "0.9.6", + "key": "{A72CCEB0-FD16-472D-8FF1-5215981985F3}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.0", + "version": "0.9.0", + "key": "{4F364726-0CD9-4E0C-A2F6-1FC42DE4CF7C}" + }, + { + "product": "pyRevit CLI", + "release": "0.6.0", + "version": "0.6.0", + "key": "{00C758B9-116B-4E07-8A65-1428643331C8}" + } +] \ No newline at end of file diff --git a/bin/netcore/pyrevit_outputwindow.png b/bin/netcore/pyrevit_outputwindow.png new file mode 100644 index 000000000..0f892fa66 Binary files /dev/null and b/bin/netcore/pyrevit_outputwindow.png differ diff --git a/bin/netcore/pyrevit_settings.png b/bin/netcore/pyrevit_settings.png new file mode 100644 index 000000000..1806c0e7c Binary files /dev/null and b/bin/netcore/pyrevit_settings.png differ diff --git a/bin/engines/IPY340PR/Mono.Posix.dll b/bin/netfx/engines/IPY2712PR/Mono.Posix.dll similarity index 100% rename from bin/engines/IPY340PR/Mono.Posix.dll rename to bin/netfx/engines/IPY2712PR/Mono.Posix.dll diff --git a/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.Modules.dll b/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.Modules.dll new file mode 100644 index 000000000..ad8cf042c Binary files /dev/null and b/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.Modules.dll differ diff --git a/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.SQLite.dll b/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.SQLite.dll new file mode 100644 index 000000000..2a186081d Binary files /dev/null and b/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.SQLite.dll differ diff --git a/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.Wpf.dll b/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.Wpf.dll new file mode 100644 index 000000000..631180d22 Binary files /dev/null and b/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.Wpf.dll differ diff --git a/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.dll b/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.dll new file mode 100644 index 000000000..718abab39 Binary files /dev/null and b/bin/netfx/engines/IPY2712PR/pyRevitLabs.IronPython.dll differ diff --git a/bin/netfx/engines/IPY2712PR/pyRevitLabs.Microsoft.Dynamic.dll b/bin/netfx/engines/IPY2712PR/pyRevitLabs.Microsoft.Dynamic.dll new file mode 100644 index 000000000..65a7e186a Binary files /dev/null and b/bin/netfx/engines/IPY2712PR/pyRevitLabs.Microsoft.Dynamic.dll differ diff --git a/bin/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll b/bin/netfx/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll similarity index 86% rename from bin/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll rename to bin/netfx/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll index 9cdfdeafc..bc308b01b 100644 Binary files a/bin/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll and b/bin/netfx/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll differ diff --git a/bin/netfx/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.dll b/bin/netfx/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.dll new file mode 100644 index 000000000..24ccd4528 Binary files /dev/null and b/bin/netfx/engines/IPY2712PR/pyRevitLabs.Microsoft.Scripting.dll differ diff --git a/bin/engines/IPY2711PR/Mono.Posix.dll b/bin/netfx/engines/IPY340PR/Mono.Posix.dll similarity index 95% rename from bin/engines/IPY2711PR/Mono.Posix.dll rename to bin/netfx/engines/IPY340PR/Mono.Posix.dll index 6a58ed148..649e7e6dd 100644 Binary files a/bin/engines/IPY2711PR/Mono.Posix.dll and b/bin/netfx/engines/IPY340PR/Mono.Posix.dll differ diff --git a/bin/netfx/engines/IPY340PR/System.Buffers.dll b/bin/netfx/engines/IPY340PR/System.Buffers.dll new file mode 100644 index 000000000..f2d83c514 Binary files /dev/null and b/bin/netfx/engines/IPY340PR/System.Buffers.dll differ diff --git a/bin/netfx/engines/IPY340PR/System.Memory.dll b/bin/netfx/engines/IPY340PR/System.Memory.dll new file mode 100644 index 000000000..461719979 Binary files /dev/null and b/bin/netfx/engines/IPY340PR/System.Memory.dll differ diff --git a/bin/netfx/engines/IPY340PR/System.Numerics.Vectors.dll b/bin/netfx/engines/IPY340PR/System.Numerics.Vectors.dll new file mode 100644 index 000000000..08659724d Binary files /dev/null and b/bin/netfx/engines/IPY340PR/System.Numerics.Vectors.dll differ diff --git a/bin/netfx/engines/IPY340PR/System.Runtime.CompilerServices.Unsafe.dll b/bin/netfx/engines/IPY340PR/System.Runtime.CompilerServices.Unsafe.dll new file mode 100644 index 000000000..de9e12447 Binary files /dev/null and b/bin/netfx/engines/IPY340PR/System.Runtime.CompilerServices.Unsafe.dll differ diff --git a/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.Modules.dll b/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.Modules.dll new file mode 100644 index 000000000..c26dc612f Binary files /dev/null and b/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.Modules.dll differ diff --git a/bin/engines/IPY340PR/pyRevitLabs.IronPython.SQLite.dll b/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.SQLite.dll similarity index 81% rename from bin/engines/IPY340PR/pyRevitLabs.IronPython.SQLite.dll rename to bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.SQLite.dll index c9af0ffbc..bd75d7afb 100644 Binary files a/bin/engines/IPY340PR/pyRevitLabs.IronPython.SQLite.dll and b/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.SQLite.dll differ diff --git a/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.Wpf.dll b/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.Wpf.dll new file mode 100644 index 000000000..6cfa62b76 Binary files /dev/null and b/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.Wpf.dll differ diff --git a/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.dll b/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.dll new file mode 100644 index 000000000..507264b56 Binary files /dev/null and b/bin/netfx/engines/IPY340PR/pyRevitLabs.IronPython.dll differ diff --git a/bin/netfx/engines/IPY340PR/pyRevitLabs.Microsoft.Dynamic.dll b/bin/netfx/engines/IPY340PR/pyRevitLabs.Microsoft.Dynamic.dll new file mode 100644 index 000000000..7cfb58ac0 Binary files /dev/null and b/bin/netfx/engines/IPY340PR/pyRevitLabs.Microsoft.Dynamic.dll differ diff --git a/bin/netfx/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll b/bin/netfx/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll new file mode 100644 index 000000000..3f9acd692 Binary files /dev/null and b/bin/netfx/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.Metadata.dll differ diff --git a/bin/netfx/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.dll b/bin/netfx/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.dll new file mode 100644 index 000000000..8e94b186e Binary files /dev/null and b/bin/netfx/engines/IPY340PR/pyRevitLabs.Microsoft.Scripting.dll differ diff --git a/bin/netfx/engines/pyRevitLoader.py b/bin/netfx/engines/pyRevitLoader.py new file mode 100644 index 000000000..7a67b1d34 --- /dev/null +++ b/bin/netfx/engines/pyRevitLoader.py @@ -0,0 +1,33 @@ +# -*- coding: utf-8 -*- +#pylint: disable=C0103,W1401,E0401,E0602 +""" + ██▓███▓██ ██▓ ██▀███ ▓█████ ██▒ █▓ ██▓▄▄▄█████▓ + ▓██░ ██▒██ ██▒▓██ ▒ ██▒▓█ ▀▓██░ █▒▓██▒▓ ██▒ ▓▒ + ▓██░ ██▓▒▒██ ██░▓██ ░▄█ ▒▒███ ▓██ █▒░▒██▒▒ ▓██░ ▒░ + ▒██▄█▓▒ ▒░ ▐██▓░▒██▀▀█▄ ▒▓█ ▄ ▒██ █░░░██░░ ▓██▓ ░ + ▒██▒ ░ ░░ ██▒▓░░██▓ ▒██▒░▒████▒ ▒▀█░ ░██░ ▒██▒ ░ + ▒▓▒░ ░ ░ ██▒▒▒ ░ ▒▓ ░▒▓░░░ ▒░ ░ ░ ▐░ ░▓ ▒ ░░ + ░▒ ░ ▓██ ░▒░ ░▒ ░ ▒░ ░ ░ ░ ░ ░░ ▒ ░ ░ + ░░ ▒ ▒ ░░ ░░ ░ ░ ░░ ▒ ░ ░ + ░ ░ ░ ░ ░ ░ ░ + ░ ░ ░ +This is the starting point for pyRevit. At Revit loads the PyRevitLoader.dll + addon at startup. This dll then creates an ironpython engine and runs + pyRevitLoader.py (this script). It's the job of this script to setup the + environment for the pyrevit module (pyrevitlib\pyrevit) and load a new pyRevit + session. This script needs to add the directory path of the pyrevit lib folder + so the pyrevit module can be imported and used. +""" + +import sys +import os.path as op + +# add the library location to the system search paths +repo_path = op.dirname(op.dirname(op.dirname(op.dirname(__file__)))) +sys.path.append(op.join(repo_path, 'pyrevitlib')) + +# now pyrevit can be imported +from pyrevit.loader import sessionmgr + +# ask sessionmgr to start a new session +sessionmgr.load_session() diff --git a/bin/netfx/pyRevitLabs.Emojis.dll b/bin/netfx/pyRevitLabs.Emojis.dll new file mode 100644 index 000000000..3cf64cf04 Binary files /dev/null and b/bin/netfx/pyRevitLabs.Emojis.dll differ diff --git a/bin/netfx/pyrevit-doctor.runtimeconfig.json b/bin/netfx/pyrevit-doctor.runtimeconfig.json new file mode 100644 index 000000000..d78451564 --- /dev/null +++ b/bin/netfx/pyrevit-doctor.runtimeconfig.json @@ -0,0 +1,13 @@ +{ + "runtimeOptions": { + "tfm": "net8.0", + "framework": { + "name": "Microsoft.NETCore.App", + "version": "8.0.0" + }, + "configProperties": { + "System.Reflection.Metadata.MetadataUpdater.IsSupported": false, + "System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false + } + } +} \ No newline at end of file diff --git a/bin/netfx/pyrevit-hosts.json b/bin/netfx/pyrevit-hosts.json new file mode 100644 index 000000000..4fcbe5c5a --- /dev/null +++ b/bin/netfx/pyrevit-hosts.json @@ -0,0 +1,1863 @@ +[ + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2008 Architecture Service Pack 1", + "version": "", + "build": "20070607_1700", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2008 Architecture Service Pack 2", + "version": "", + "build": "20070810_1700", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://forums.autodesk.com/t5/revit-architecture-forum/sp3-build-20080101-2345/td-p/2152807" + }, + "product": "Autodesk Revit", + "release": "2008 Architecture Service Pack 3", + "version": "", + "build": "20080101_2345", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2009 Architecture Service Pack 1", + "version": "", + "build": "20080602_1900", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2009 Architecture Service Pack 2", + "version": "", + "build": "20080915_2100", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2009 Architecture Service Pack 3", + "version": "", + "build": "20081118_1045", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://forums.autodesk.com/t5/revit-architecture-forum/sp3-build-20080101-2345/td-p/2152807" + }, + "product": "Autodesk Revit", + "release": "2010 Architecture Service Pack 1", + "version": "", + "build": "20090612_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.revitforum.org/architecture-general-revit-questions/105-revit-builds-updates-product-support.html" + }, + "product": "Autodesk Revit", + "release": "2010 Architecture Service Pack 2", + "version": "", + "build": "20090917_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://forums.augi.com/showthread.php?138574-Revit-Architecture-Door-Centerline-not-selectable-during-dimensioning" + }, + "product": "Autodesk Revit", + "release": "2011 Architecture", + "version": "", + "build": "20100326_1700", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://revitclinic.typepad.com/my_weblog/2010/06/revit-2011-build-number-update-display.html" + }, + "product": "Autodesk Revit", + "release": "2011 Architecture Service Pack 1", + "version": "", + "build": "20100615_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/downloads/caas/downloads/content/hotfix--E2-80-93-black-preview-swatch.html?v=2011" + }, + "product": "Autodesk Revit", + "release": "2011 Hotfix - Black Preview Swatch", + "version": "", + "build": "20100903_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/downloads/caas/downloads/content/hotfix-autodesk-revit-architecture-2011-colorfills.html?v=2011" + }, + "product": "Autodesk Revit", + "release": "2011 Hotfix - Color Fills", + "version": "", + "build": "20110218_1300", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2012 First Customer Ship", + "version": "", + "build": "20110309_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2012 Update Release 1", + "version": "", + "build": "20110622_0930", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2012 Update Release 2", + "version": "", + "build": "20110916_2132", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2013 First Customer Ship", + "version": "12.02.21203", + "build": "20120221_2030", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2013 Update Release 1", + "version": "", + "build": "20120716_1115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2013 Update Release 2", + "version": "", + "build": "20121003_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://github.com/eirannejad/pyRevit/issues/622" + }, + "product": "Autodesk Revit", + "release": "2013 Update Release 3", + "version": "12.11.10090", + "build": "20130531_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2013 LT First Customer Ship", + "version": "", + "build": "20120821_1330", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://web.archive.org/web/20150123061214/https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2013 LT Update Release 1", + "version": "", + "build": "20130531_0300", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2014 First Customer Ship", + "version": "13.03.08151", + "build": "20130308_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2014 Update Release 1", + "version": "", + "build": "20130709_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2014 Update Release 2", + "version": "", + "build": "20131024_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "//https://github.com/eirannejad/pyRevit/issues/543" + }, + "product": "Autodesk Revit", + "release": "2014 Update Release 3", + "version": "13.11.00004", + "build": "20140709_2115", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/downloads/caas/downloads/content/autodesk-revit-2015-product-updates.html" + }, + "product": "Autodesk Revit", + "release": "2015 First Customer Ship", + "version": "15.0.136.0", + "build": "20140223_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/downloads/caas/downloads/content/autodesk-revit-2015-product-updates.html" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 1", + "version": "15.0.136.0", + "build": "20140322_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/downloads/caas/downloads/content/autodesk-revit-2015-product-updates.html" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 2", + "version": "15.0.166.0", + "build": "20140323_1530", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 3", + "version": "15.0.207.0", + "build": "20140606_1530", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 4", + "version": "15.0.270.0", + "build": "20140903_1530", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 (Subscription only release)", + "version": "15.0.1103.0", + "build": "20140905_0730", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 5", + "version": "15.0.310.0", + "build": "20141119_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 5 (Subscription only release)", + "version": "15.0.1133.0", + "build": "20141119_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 6", + "version": "15.0.315.0", + "build": "20150127_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 6 (Subscription only release)", + "version": "15.0.1142.0", + "build": "20150127_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 7", + "version": "15.0.318.0", + "build": "20150303_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 7 (Subscription only release)", + "version": "15.0.1148.0", + "build": "20150303_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 8", + "version": "15.0.341.0", + "build": "20150512_1015", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 8 (Subscription only release)", + "version": "15.0.1170.0", + "build": "20150511_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 9", + "version": "15.0.361.0", + "build": "20150702_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 9 (Subscription only release)", + "version": "15.0.1190.0", + "build": "20150704_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 10", + "version": "15.0.379.0", + "build": "20151007_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 10 (Subscription only release)", + "version": "15.0.1203.0", + "build": "20151008_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 11 *Issue with Revit Server", + "version": "15.0.390.0", + "build": "20151207_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 11 (Subscription only release) *Issue with Revit Server", + "version": "15.0.1225.0", + "build": "20151208_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 12", + "version": "15.0.403.0", + "build": "20160119_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 12 (Subscription only release)", + "version": "15.0.1238.0", + "build": "20160120_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 13", + "version": "15.0.406.0", + "build": "20160220_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 13 (Subscription only release)", + "version": "15.0.1243.0", + "build": "20160220_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Update Release 14", + "version": "15.0.421.0", + "build": "20160512_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2015 Release 2 Update Release 14 (Subscription only release)", + "version": "15.0.1259.0", + "build": "20160512_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 First Customer Ship", + "version": "16.0.428.0", + "build": "20150220_1215", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Service Pack 1", + "version": "16.0.462.0", + "build": "20150506_1715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/troubleshooting/caas/sfdcarticles/sfdcarticles/Revit-2016-Release-2-Error-1642.html" + }, + "product": "Autodesk Revit", + "release": "2016 Unreleased Update", + "version": "16.0.485.0", + "build": "20150701_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Service Pack 2", + "version": "16.0.490.0", + "build": "20150714_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Release 2 (R2)", + "version": "16.0.1063", + "build": "20151007_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 1 for R2", + "version": "16.0.1092.0", + "build": "20151209_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 2 for R2", + "version": "16.0.1108.0", + "build": "20160126_1600", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 3 for R2", + "version": "16.0.1118.0", + "build": "20160217_1800", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 4 for R2", + "version": "16.0.1124.0", + "build": "20160314_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 5 for R2", + "version": "16.0.1144.0", + "build": "20160525_1230", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 6 for R2", + "version": "16.0.1161.0", + "build": "20160720_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2016 Update 7 for R2", + "version": "16.0.1185.0", + "build": "20161004_0715", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "http://revit.downloads.autodesk.com/download/2016_1_9_RVT/Docs/RelNotes/Autodesk_Revit_2016_1_9_ReleaseNotes.html" + }, + "product": "Autodesk Revit", + "release": "2016.1.8 Update", + "version": "16.0.1205.0", + "build": "20170117_1200", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2016/RVT/Autodesk_Revit_2016_1_9_Readme.htm" + }, + "product": "Autodesk Revit", + "release": "2016.1.9 Security Fix", + "version": "16.0.1218.0", + "build": "20190508_0715", + "target": "x64", + "notes": "https://up.autodesk.com/2016/RVT/Autodesk_Revit_2016_1_9_Readme.htm" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017 First Customer Ship", + "version": "17.0.416.0", + "build": "20160225_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017 Service Pack 1", + "version": "17.0.476.0", + "build": "20160606_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017 Service Pack 2", + "version": "17.0.501.0", + "build": "20160720_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.0.3", + "version": "17.0.503.0", + "build": "20161205_1400", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.1", + "version": "17.0.1081.0", + "build": "20161006_0315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.1.1", + "version": "17.0.1099.0", + "build": "20161117_1200", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.2", + "version": "17.0.1117.0", + "build": "20170118_1100", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.2.1", + "version": "17.0.1128.0", + "build": "20170419_0315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.2.2", + "version": "17.0.1146.0", + "build": "20170816_0615", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.2.3", + "version": "17.0.1150.0", + "build": "20171027_0315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://github.com/eirannejad/pyRevit/issues/456" + }, + "product": "Autodesk Revit", + "release": "2017.0.4", + "version": "17.0.511.0", + "build": "20181011_1545", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2017/RVT/Autodesk_Revit_2017_0_5_Readme.htm" + }, + "product": "Autodesk Revit", + "release": "2017.0.5 Security Fix", + "version": "17.0.517.0", + "build": "20190507_1515", + "target": "x64", + "notes": "https://up.autodesk.com/2017/RVT/Autodesk_Revit_2017_0_5_Readme.htm" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2017.2.4", + "version": "17.0.1158.0", + "build": "20181011_1645", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2017/RVT/Autodesk_Revit_2017_2_5_Readme.htm" + }, + "product": "Autodesk Revit", + "release": "2017.2.5 Security Fix", + "version": "17.0.1169.0", + "build": "20190508_0315", + "target": "x64", + "notes": "https://up.autodesk.com/2017/RVT/Autodesk_Revit_2017_2_5_Readme.htm" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018 First Customer Ship", + "version": "18.0.0.420", + "build": "20170223_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.0.1", + "version": "18.0.1.2", + "build": "20170421_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.0.2", + "version": "18.0.2.11", + "build": "20170525_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2018/RVT/Autodesk_Revit_2018_0_3_Readme.htm" + }, + "product": "Autodesk Revit", + "release": "2018.0.3", + "version": "18.0.3.6", + "build": "20181015_0930", + "target": "x64", + "notes": "https://up.autodesk.com/2018/RVT/Autodesk_Revit_2018_0_3_Readme.htm" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.1", + "version": "18.1.0.92", + "build": "20170630_0700", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.1.1", + "version": "18.1.1.18", + "build": "20170907_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.2", + "version": "18.2.0.51", + "build": "20170927_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://github.com/eirannejad/pyRevit/issues/456" + }, + "product": "Autodesk Revit", + "release": "2018.3", + "version": "18.3.0.81", + "build": "20180329_1100", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.3.1", + "version": "18.3.1.2", + "build": "20180423_1000", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2018.3.2", + "version": "18.3.2.7", + "build": "20181011_1500", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2018/RVT/Autodesk_Revit_2018_3_3_Readme.htm" + }, + "product": "Autodesk Revit", + "release": "2018.3.3 Security Fix", + "version": "18.3.3.18", + "build": "20190510_1515", + "target": "x64", + "notes": "https://up.autodesk.com/2018/RVT/Autodesk_Revit_2018_3_3_Readme.htm" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019 First Customer Ship", + "version": "19.0.0.405", + "build": "20180216_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019 Update for Trial Build", + "version": "19.0.1.1", + "build": "20180328_1600", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019.0.1", + "version": "19.0.10.18", + "build": "20180518_1600", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019.0.2", + "version": "19.0.20.1", + "build": "20180927_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019.1", + "version": "19.1.0.112", + "build": "20180806_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2019.2 (Update)", + "version": "19.2.0.65", + "build": "20181217_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://twitter.com/JarodJSchultz/status/1100459171491676160" + }, + "product": "Autodesk Revit", + "release": "2019.2 (Full Install)", + "version": "19.2.1.1", + "build": "20190108_1515", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_1_Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.1", + "version": "19.2.10.7", + "build": "20190225_1515", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_1_Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_2_Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.2 Hotfix", + "version": "19.2.20.24", + "build": "20190808_0900", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_2_Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "" + }, + "product": "Autodesk Revit", + "release": "2020 First Customer Ship", + "version": "20.0.0.377", + "build": "20190327_2315", + "target": "x64", + "notes": "" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_0_1_Resolved_Issues_html" + }, + "product": "Autodesk Revit", + "release": "2020.0.1 Hotfix", + "version": "20.0.1.2", + "build": "20190412_1200", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_0_1_Resolved_Issues_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_1_html" + }, + "product": "Autodesk Revit", + "release": "2020.1 (Update)", + "version": "20.1.0.81", + "build": "20190725_1135", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit-products/learn-explore/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2020.1 (Full Install)", + "version": "20.1.1.1", + "build": "20190731_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_html" + }, + "product": "Autodesk Revit", + "release": "2020.2 (Update)", + "version": "20.2.0.48", + "build": "20191031_1115", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2 (Full Install)", + "version": "20.2.1.1", + "build": "20191106_1200", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.2 (Full Install)", + "version": "20.2.11.3", + "build": "20200206_0915", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_2_Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.2 Hotfix", + "version": "19.2.20.24", + "build": "20190808_0900", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_2_Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021release_html" + }, + "product": "Autodesk Revit", + "release": "2021 First Customer Ship", + "version": "21.0.0.383", + "build": "20200220_1100", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021release_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.1 (New Install)", + "version": "20.2.12.1", + "build": "20200210_1400", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.2", + "version": "20.2.20.31", + "build": "20200426_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_html" + }, + "product": "Autodesk Revit", + "release": "2021.1", + "version": "21.1.0.108", + "build": "20200708_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_3_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.3", + "version": "20.2.30.42", + "build": "20200826_1250", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_3_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_1_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.1", + "version": "21.1.10.26", + "build": "20200909_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.2", + "version": "21.1.20.44", + "build": "20201109_1530", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_html" + }, + "product": "Autodesk Revit", + "release": "2022 First Customer Ship", + "version": "22.0.2.392", + "build": "20210224_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_3_Hotfix_Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.3", + "version": "19.2.30.41", + "build": "20210416_1515", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Autodesk_Revit_2019_2_3_Hotfix_Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.4", + "version": "20.2.40.65", + "build": "20210420_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.3", + "version": "21.1.30.74", + "build": "20210426_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_html" + }, + "product": "Autodesk Revit", + "release": "2022.0.1", + "version": "22.0.10.28", + "build": "20210616_0115", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.4", + "version": "21.1.40.95", + "build": "20210805_1400", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.5", + "version": "20.2.50.77", + "build": "20210804_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_html" + }, + "product": "Autodesk Revit", + "release": "2022.1", + "version": "22.1.1.516", + "build": "20210921_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_1_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.1", + "version": "22.1.10.541", + "build": "20211103_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_5_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.5", + "version": "21.1.50.27", + "build": "20211018_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_5_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_6_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.6", + "version": "20.2.60.15", + "build": "20211019_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_6_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://revit.downloads.autodesk.com/download/2019_2_4_RVT/Docs/RelNotes/Autodesk_Revit_2019_2_4_ReleaseNotes.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.4", + "version": "19.2.40.15", + "build": "20211029_1515", + "target": "x64", + "notes": "https://revit.downloads.autodesk.com/download/2019_2_4_RVT/Docs/RelNotes/Autodesk_Revit_2019_2_4_ReleaseNotes.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_6_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.6", + "version": "21.1.60.25", + "build": "20220123_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_6_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_2_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.2", + "version": "22.1.21.13", + "build": "20220123_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_7_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.7", + "version": "20.2.70.6", + "build": "20220112_1230", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_7_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Revit-2019.2.5-Hotfix-Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.5", + "version": "19.2.50.16", + "build": "20220111_1110", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Revit-2019.2.5-Hotfix-Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023release_html" + }, + "product": "Autodesk Revit", + "release": "2023 First Customer Ship", + "version": "23.0.1.318", + "build": "20220304_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023release_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://knowledge.autodesk.com/support/revit/learn-explore/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2023.0.1", + "version": "23.0.10.18", + "build": "20220429_1500", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_8_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.8", + "version": "20.2.80.2", + "build": "20220225_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_8_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://up.autodesk.com/2019/RVT/Revit-2019.2.6-Hotfix-Readme.html" + }, + "product": "Autodesk Revit", + "release": "2019.2.6", + "version": "19.2.60.3", + "build": "20220224_1700", + "target": "x64", + "notes": "https://up.autodesk.com/2019/RVT/Revit-2019.2.6-Hotfix-Readme.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_9_html" + }, + "product": "Autodesk Revit", + "release": "2020.2.9", + "version": "20.2.90.12", + "build": "20220517_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2020/ENU/?guid=RevitReleaseNotes_2020updates_2020_2_9_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_7_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.7", + "version": "21.1.70.21", + "build": "20220517_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_7_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_8_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.8", + "version": "21.1.80.35", + "build": "20230515_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_8_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_9_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.9", + "version": "21.1.90.15", + "build": "20230907_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_9_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_3_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.3", + "version": "22.1.30.34", + "build": "20220520_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_3_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_4_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.4", + "version": "22.1.40.58", + "build": "20230505_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_4_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_5_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.5", + "version": "22.1.50.17", + "build": "20230915_1530", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_5_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_0_2_html" + }, + "product": "Autodesk Revit", + "release": "2023.0.2", + "version": "23.0.20.21", + "build": "20220726_1500", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_0_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_html" + }, + "product": "Autodesk Revit", + "release": "2023.1", + "version": "23.1.1.24", + "build": "20221114_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_1_html" + }, + "product": "Autodesk Revit", + "release": "2023.1.1", + "version": "23.1.10.4", + "build": "20221122_1550", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_1_1_html" + }, + "product": "Autodesk Revit", + "release": "2023.1.1.1", + "version": "23.1.10.4", + "build": "20221122_1550", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_1_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + }, + "product": "Autodesk Revit", + "release": "23.1.2", + "version": "23.1.20.70", + "build": "20230510_1100", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + }, + "product": "Autodesk Revit", + "release": "23.1.2", + "version": "23.1.20.70", + "build": "20230510_1100", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + }, + + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_3_html" + }, + "product": "Autodesk Revit", + "release": "23.1.3", + "version": "23.1.30.97", + "build": "20230828_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_3_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://www.autodesk.com/support/technical/article/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + "product": "Autodesk Revit", + "release": "2024 First Customer Ship", + "version": "24.0.4.427", + "build": "20230308_1635", + "target": "x64", + "notes": "https://www.autodesk.com/support/technical/article/caas/sfdcarticles/sfdcarticles/How-to-tie-the-Build-number-with-the-Revit-update.html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024release_html" + }, + "product": "Autodesk Revit", + "release": "2024.0.1", + "version": "24.0.5.432", + "build": "20230411_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024release_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_0_2_html" + }, + "product": "Autodesk Revit", + "release": "2024.0.2", + "version": "24.0.20.20", + "build": "20230509_0315", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_0_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_1_html" + }, + "product": "Autodesk Revit", + "release": "24.1", + "version": "24.1.0.66", + "build": "20230701_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_1_1_html" + }, + "product": "Autodesk Revit", + "release": "24.1.1", + "version": "24.1.10.25", + "build": "20230830_0315", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_1_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_2_html" + }, + "product": "Autodesk Revit", + "release": "24.2", + "version": "24.2.0.63", + "build": "20231029_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2025/ENU/?guid=GUID-C81929D7-02CB-4BF7-A637-9B98EC9EB38B" + }, + "product": "Autodesk Revit", + "release": "25.0", + "version": "25.0.2.419", + "build": "20240307_1300", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2025/ENU/?guid=GUID-C81929D7-02CB-4BF7-A637-9B98EC9EB38B" + } +] diff --git a/bin/netfx/pyrevit-products.json b/bin/netfx/pyrevit-products.json new file mode 100644 index 000000000..7c1d9fa36 --- /dev/null +++ b/bin/netfx/pyrevit-products.json @@ -0,0 +1,476 @@ +[ + { + "product": "pyRevit", + "release": "4.8.14.24016+1909", + "version": "4.8.14.24016+1909", + "key": "f2a3da53-6f34-41d5-abbd-389ffa7f4d5f" + }, + { + "product": "pyRevit", + "release": "4.8.13.23182+2215", + "version": "4.8.13.23182+2215", + "key": "6a6637c3-859c-4fba-9ed9-03957adee956" + }, + { + "product": "pyRevit", + "release": "4.8.12.22247+0031", + "version": "4.8.12.22247+0031", + "key": "a241ce67-c9b1-41f8-8c20-65d6de92db16" + }, + { + "product": "pyRevit", + "release": "4.8.11.22151+0454", + "version": "4.8.11.22151+0454", + "key": "ee4c9248-a3a4-4a4a-bed8-7a1c28102bc1" + }, + { + "product": "pyRevit", + "release": "4.8.10.22040+1743", + "version": "4.8.10.22040+1743", + "key": "d56fb4d2-b004-4508-bf3d-8ebd5cb466b7" + }, + { + "product": "pyRevit", + "release": "4.8.9.21361+0320", + "version": "4.8.9.21361+0320", + "key": "56307bc9-65f7-4f28-b701-cb88d141b592" + }, + { + "product": "pyRevit", + "release": "4.8.9.21359+1855", + "version": "4.8.9.21359+1855", + "key": "c4bdcf02-55f0-49e4-8db2-6d9bf5bb8287" + }, + { + "product": "pyRevit", + "release": "4.8.8", + "version": "4.8.8", + "key": "{CA372AB6-355A-4270-91DD-144DF75E1B57}" + }, + { + "product": "pyRevit", + "release": "4.8.7", + "version": "4.8.7", + "key": "{FED5DEF7-8D3B-4832-BB3E-55C10FCF9ACF}" + }, + { + "product": "pyRevit", + "release": "4.8.6", + "version": "4.8.6", + "key": "{32B7C208-2ACC-4D2B-9C75-5BAEE22E7F85}" + }, + { + "product": "pyRevit", + "release": "4.8.5", + "version": "4.8.5", + "key": "{F13EA93D-4DB1-4149-A86A-B0EFE54ED6AC}" + }, + { + "product": "pyRevit", + "release": "4.8.4", + "version": "4.8.4", + "key": "{CA4CAB91-D337-4A68-BCF7-D56B77327D3A}" + }, + { + "product": "pyRevit", + "release": "4.8.3", + "version": "4.8.3", + "key": "{696310B4-5E37-4437-B047-20954E4B2814}" + }, + { + "product": "pyRevit", + "release": "4.8.2", + "version": "4.8.2", + "key": "{ECFE3DF3-2276-4A11-BA07-9F166AFE4693}" + }, + { + "product": "pyRevit", + "release": "4.8.1", + "version": "4.8.1", + "key": "{311A0079-4026-4F30-9288-619E8824DCA5}" + }, + { + "product": "pyRevit", + "release": "4.8.0", + "version": "4.8.0", + "key": "{CDA0124F-714E-4F93-BF5D-37FF54C25F15}" + }, + { + "product": "pyRevit", + "release": "4.7.6", + "version": "4.7.6", + "key": "{57D90459-1106-444E-A9DC-DC68435BBAEE}" + }, + { + "product": "pyRevit", + "release": "4.7.5", + "version": "4.7.5", + "key": "{40BE31F6-E27A-49D0-ABF5-67778407DD6F}" + }, + { + "product": "pyRevit", + "release": "4.7 Final", + "version": "4.7.4", + "key": "{8A28EE04-5F33-409A-A3B2-7B38FFF2ADF1}" + }, + { + "product": "pyRevit", + "release": "4.7-beta4", + "version": "4.7.3", + "key": "{4D75C52D-F32E-486A-ADED-C7E77E3A8687}" + }, + { + "product": "pyRevit", + "release": "4.7-beta3", + "version": "4.7.2", + "key": "{83110B68-9131-4D58-95AB-D05D785A22E1}" + }, + { + "product": "pyRevit", + "release": "4.7-beta2", + "version": "4.7.1", + "key": "{D719552C-6D81-4436-BF06-5F024C83313A}" + }, + { + "product": "pyRevit", + "release": "4.6.24", + "version": "4.6.24", + "key": "{C125D1FC-A13B-4D52-B642-D279DF321191}" + }, + { + "product": "pyRevit", + "release": "4.6.23", + "version": "4.6.23", + "key": "{3C05CBFF-8250-41EA-B91B-93967E436EFF}" + }, + { + "product": "pyRevit", + "release": "4.6.22", + "version": "4.6.22", + "key": "{D763A045-F988-4C82-9A94-20645FAD8D83}" + }, + { + "product": "pyRevit", + "release": "4.6.21", + "version": "4.6.21", + "key": "{DB9FCA88-7183-4A7E-9842-798975628854}" + }, + { + "product": "pyRevit", + "release": "4.6.20", + "version": "4.6.20", + "key": "{2FA86D06-A1A1-4908-BEB9-877B62D28D75}" + }, + { + "product": "pyRevit", + "release": "4.6.19", + "version": "4.6.19", + "key": "{BFEA01ED-43D5-4B73-8C7D-01A075B1F967}" + }, + { + "product": "pyRevit", + "release": "4.6.18", + "version": "4.6.18", + "key": "{21D49B9A-05AA-4E2F-8744-1653C37AC5D6}" + }, + { + "product": "pyRevit", + "release": "4.6.17", + "version": "4.6.17", + "key": "{309D684B-5279-4DA7-89AE-0870AECDEA4D}" + }, + { + "product": "pyRevit", + "release": "4.6.16", + "version": "4.6.16", + "key": "{8A958BB7-C38A-417B-8818-EF3FF1F6615F}" + }, + { + "product": "pyRevit", + "release": "4.7-beta", + "version": "4.7.0", + "key": "{70FAC724-6300-4037-9178-6A0002B98A65}" + }, + { + "product": "pyRevit", + "release": "4.6.15", + "version": "4.6.15", + "key": "{67AA2183-02A8-4851-9653-1BEA54E0F9A1}" + }, + { + "product": "pyRevit", + "release": "4.6.14", + "version": "4.6.14", + "key": "{2FE2F748-8EF1-4012-9CEE-5A8AA9BF1114}" + }, + { + "product": "pyRevit", + "release": "4.6.13", + "version": "4.6.13", + "key": "{A596729B-C818-48EB-85E6-957B5537328F}" + }, + { + "product": "pyRevit", + "release": "4.6.12", + "version": "4.6.12", + "key": "{F013A175-38C0-436F-9234-6163E45C3B52}" + }, + { + "product": "pyRevit", + "release": "4.6.11", + "version": "4.6.11", + "key": "{98A0A70D-7F59-4937-A6B9-00A1E2EAC294}" + }, + { + "product": "pyRevit", + "release": "4.6.10", + "version": "4.6.10", + "key": "{6A1713AA-256C-4F10-AB96-DD12A225677E}" + }, + { + "product": "pyRevit", + "release": "4.6.9", + "version": "4.6.9", + "key": "{26F3AF6F-DC19-41BF-98BE-C39C56C413D2}" + }, + { + "product": "pyRevit", + "release": "4.6.8", + "version": "4.6.8", + "key": "{C433FE4C-BE21-405D-8D7B-043392763FC7}" + }, + { + "product": "pyRevit", + "release": "4.6.7", + "version": "4.6.7", + "key": "{B105FB5A-0ACF-4A07-9A14-057886D5E25D}" + }, + { + "product": "pyRevit", + "release": "4.6.6", + "version": "4.6.6", + "key": "{E119DE40-5871-479A-96E9-C2AE4F9C424B}" + }, + { + "product": "pyRevit", + "release": "4.6.5", + "version": "4.6.5", + "key": "{FC761B9E-3699-419C-A5DE-DEC361C1F6A7}" + }, + { + "product": "pyRevit", + "release": "4.6.4", + "version": "4.6.4", + "key": "{37CFAD58-51D0-4248-90E0-893058455ED1}" + }, + { + "product": "pyRevit", + "release": "4.6.3", + "version": "4.6.3", + "key": "{63160AFE-5B53-49AF-B46B-527BCBA0AC6E}" + }, + { + "product": "pyRevit", + "release": "4.6.2", + "version": "4.6.2", + "key": "{31A23489-A61B-4786-A857-F95DEB45573C}" + }, + { + "product": "pyRevit", + "release": "4.6.1", + "version": "4.6.1", + "key": "{EF91A585-DC0C-43B8-B88B-4C130F430E84}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.14.24016+1909", + "version": "4.8.14.24016+1909", + "key": "9557b432-cf79-4ece-91cf-b8f996c88b47" + }, + { + "product": "pyRevit CLI", + "release": "4.8.13.23182+2215", + "version": "4.8.13.23182+2215", + "key": "48b17832-a795-41fe-ac44-29ce052b3dba" + }, + { + "product": "pyRevit CLI", + "release": "4.8.12.22247+0031", + "version": "4.8.12.22247+0031", + "key": "52cc6210-7507-4dd3-9b18-6314d2c0abc4" + }, + { + "product": "pyRevit CLI", + "release": "4.8.11.22151+0454", + "version": "4.8.11.22151+0454", + "key": "942e8317-c392-4020-9fe8-15e8ddb1df45" + }, + { + "product": "pyRevit CLI", + "release": "4.8.10.22040+1743", + "version": "4.8.10.22040+1743", + "key": "a77c5ef7-194d-4211-810e-720a7957f0c1" + }, + { + "product": "pyRevit CLI", + "release": "4.8.9.21361+0320", + "version": "4.8.9.21361+0320", + "key": "e71ec326-b624-4530-b236-ecd0ba1b4a99" + }, + { + "product": "pyRevit CLI", + "release": "4.8.9.21359+1855", + "version": "4.8.9.21359+1855", + "key": "5d419b28-c737-4fd3-9c33-6da59628a443" + }, + { + "product": "pyRevit CLI", + "release": "4.8.8", + "version": "4.8.8", + "key": "{8E0191BC-C5DB-4F0E-8F52-6DF04C2B8CE8}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.7", + "version": "4.8.7", + "key": "{E61BB97E-6FF1-4706-A92E-D9F38EB9C77B}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.6", + "version": "4.8.6", + "key": "{AB14082F-168E-45DE-98A7-7C99DB00FFE7}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.5", + "version": "4.8.5", + "key": "{AA15AF8E-2D65-40EF-A9E6-C920D83984E0}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.4", + "version": "4.8.4", + "key": "{EF5EC593-2F57-44D8-8456-CFB05247ADA0}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.3", + "version": "4.8.3", + "key": "{F0958CD1-EEF8-481D-871C-7501947EC650}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.2", + "version": "4.8.2", + "key": "{667ABAF1-CF3A-4CF6-AF75-68F5CA26BFA6}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.1", + "version": "4.8.1", + "key": "{7FE9A723-CD7C-47E8-A0E6-C8452F0AE64E}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.0", + "version": "4.8.0", + "key": "{A0465103-77E8-4880-8192-9D055744798B}" + }, + { + "product": "pyRevit CLI", + "release": "0.25.0", + "version": "0.25.0", + "key": "{27F44ADD-E91B-4733-B4FC-51473A2FAC3D}" + }, + { + "product": "pyRevit CLI", + "release": "0.24.0", + "version": "0.24.0", + "key": "{21E2B6B9-B39B-4482-99C0-C83B93181870}" + }, + { + "product": "pyRevit CLI", + "release": "0.21.0", + "version": "0.21.0", + "key": "{8D13B375-35DF-4A04-8A47-BF4A8C843ADB}" + }, + { + "product": "pyRevit CLI", + "release": "0.17.0", + "version": "0.17.0", + "key": "{4D1CD2D8-BDCD-4B44-A71B-1775AF4A4EA9}" + }, + { + "product": "pyRevit CLI", + "release": "0.16.0", + "version": "0.16.0", + "key": "{835919B1-5715-4E3C-8112-BB941FA435E8}" + }, + { + "product": "pyRevit CLI", + "release": "0.15.0", + "version": "0.15.0", + "key": "{A90B8942-A3EB-4AA5-96BE-2EE2606C69A6}" + }, + { + "product": "pyRevit CLI", + "release": "0.14.0", + "version": "0.14.0", + "key": "{F1F6254F-1465-4B0D-A4DE-24D2D297AE30}" + }, + { + "product": "pyRevit CLI", + "release": "0.13.0", + "version": "0.13.0", + "key": "{0D50CCF6-35DF-47A2-B13A-D442C835FFB5}" + }, + { + "product": "pyRevit CLI", + "release": "0.12.0", + "version": "0.12.0", + "key": "{B6BA75F8-61A0-42CA-9E03-17503460854E}" + }, + { + "product": "pyRevit CLI", + "release": "0.11.0", + "version": "0.11.0", + "key": "{3B7168BD-E66B-4CF0-B22E-87A3BB809384}" + }, + { + "product": "pyRevit CLI", + "release": "0.10.0", + "version": "0.10.0", + "key": "{949D5537-B9CA-45B0-B69E-CF627F8F2923}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.8", + "version": "0.9.8", + "key": "{D5505166-C49A-436F-B25A-9FBD0632F6F0}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.7", + "version": "0.9.7", + "key": "{D5505166-C49A-436F-B25A-9FBD0632F6F0}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.6", + "version": "0.9.6", + "key": "{A72CCEB0-FD16-472D-8FF1-5215981985F3}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.0", + "version": "0.9.0", + "key": "{4F364726-0CD9-4E0C-A2F6-1FC42DE4CF7C}" + }, + { + "product": "pyRevit CLI", + "release": "0.6.0", + "version": "0.6.0", + "key": "{00C758B9-116B-4E07-8A65-1428643331C8}" + } +] \ No newline at end of file diff --git a/bin/netfx/pyrevit_outputwindow.png b/bin/netfx/pyrevit_outputwindow.png new file mode 100644 index 000000000..0f892fa66 Binary files /dev/null and b/bin/netfx/pyrevit_outputwindow.png differ diff --git a/bin/netfx/pyrevit_settings.png b/bin/netfx/pyrevit_settings.png new file mode 100644 index 000000000..1806c0e7c Binary files /dev/null and b/bin/netfx/pyrevit_settings.png differ diff --git a/bin/pyrevit-doctor.runtimeconfig.json b/bin/pyrevit-doctor.runtimeconfig.json new file mode 100644 index 000000000..d78451564 --- /dev/null +++ b/bin/pyrevit-doctor.runtimeconfig.json @@ -0,0 +1,13 @@ +{ + "runtimeOptions": { + "tfm": "net8.0", + "framework": { + "name": "Microsoft.NETCore.App", + "version": "8.0.0" + }, + "configProperties": { + "System.Reflection.Metadata.MetadataUpdater.IsSupported": false, + "System.Runtime.Serialization.EnableUnsafeBinaryFormatterSerialization": false + } + } +} \ No newline at end of file diff --git a/bin/pyrevit-hosts.json b/bin/pyrevit-hosts.json index 4c0c6aced..5c9d3d896 100644 --- a/bin/pyrevit-hosts.json +++ b/bin/pyrevit-hosts.json @@ -218,7 +218,7 @@ { "meta": { "schema": "1.0", - "source": "https://github.com/eirannejad/pyRevit/issues/622" + "source": "https://github.com/pyrevitlabs/pyRevit/issues/622" }, "product": "Autodesk Revit", "release": "2013 Update Release 3", @@ -290,7 +290,7 @@ { "meta": { "schema": "1.0", - "source": "//https://github.com/eirannejad/pyRevit/issues/543" + "source": "//https://github.com/pyrevitlabs/pyRevit/issues/543" }, "product": "Autodesk Revit", "release": "2014 Update Release 3", @@ -902,7 +902,7 @@ { "meta": { "schema": "1.0", - "source": "https://github.com/eirannejad/pyRevit/issues/456" + "source": "https://github.com/pyrevitlabs/pyRevit/issues/456" }, "product": "Autodesk Revit", "release": "2017.0.4", @@ -1034,7 +1034,7 @@ { "meta": { "schema": "1.0", - "source": "https://github.com/eirannejad/pyRevit/issues/456" + "source": "https://github.com/pyrevitlabs/pyRevit/issues/456" }, "product": "Autodesk Revit", "release": "2018.3", @@ -1655,6 +1655,18 @@ "target": "x64", "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_9_html" }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_10_html" + }, + "product": "Autodesk Revit", + "release": "2021.1.10", + "version": "21.1.100.12", + "build": "20240319_1700", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2021/ENU/?guid=RevitReleaseNotes_2021updates_2021_1_10_html" + }, { "meta": { "schema": "1.0", @@ -1691,6 +1703,30 @@ "target": "x64", "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_5_html" }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_6_html" + }, + "product": "Autodesk Revit", + "release": "2022.1.6", + "version": "22.1.60.18", + "build": "20240417_1700", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_6_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_7_htmll" + }, + "product": "Autodesk Revit", + "release": "2022.1.7", + "version": "22.1.70.9", + "build": "20240704_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2022/ENU/?guid=RevitReleaseNotes_2022updates_2022_1_7_html" + }, { "meta": { "schema": "1.0", @@ -1750,31 +1786,42 @@ "build": "20230510_1100", "target": "x64", "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_3_html" + }, + "product": "Autodesk Revit", + "release": "23.1.3", + "version": "23.1.30.97", + "build": "20230828_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_3_html" }, { "meta": { "schema": "1.0", - "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_4_html" }, "product": "Autodesk Revit", - "release": "23.1.2", - "version": "23.1.20.70", - "build": "20230510_1100", + "release": "23.1.4", + "version": "23.1.40.56", + "build": "20240411_0945", "target": "x64", - "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_2_html" + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_4_html" }, - { "meta": { "schema": "1.0", - "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_3_html" + "source": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_5_html" }, "product": "Autodesk Revit", - "release": "23.1.3", - "version": "23.1.30.97", - "build": "20230828_1515", + "release": "23.1.5", + "version": "23.1.50.23", + "build": "20240709_1030", "target": "x64", - "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_3_html" + "notes": "https://help.autodesk.com/view/RVT/2023/ENU/?guid=RevitReleaseNotes_2023updates_2023_1_5_html" }, { "meta": { @@ -1847,5 +1894,53 @@ "build": "20231029_1515", "target": "x64", "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_2_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_2_1_html" + }, + "product": "Autodesk Revit", + "release": "24.2.1", + "version": "24.2.10.64", + "build": "20240408_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2024/ENU/?guid=RevitReleaseNotes_2024updates_2024_2_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2025/ENU/?guid=RevitReleaseNotes_2025release_html" + }, + "product": "Autodesk Revit", + "release": "Autodesk Revit 2025", + "version": "25.0.2.419", + "build": "20240307_1300", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2025/ENU/?guid=RevitReleaseNotes_2025release_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2025/ENU/?guid=RevitReleaseNotes_2025updates_2025_1_html" + }, + "product": "Autodesk Revit", + "release": "2025.1", + "version": "25.1.0.44", + "build": "20240516_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2025/ENU/?guid=RevitReleaseNotes_2025updates_2025_1_html" + }, + { + "meta": { + "schema": "1.0", + "source": "https://help.autodesk.com/view/RVT/2025/ENU/?guid=RevitReleaseNotes_2025updates_2025_2_html" + }, + "product": "Autodesk Revit", + "release": "2025.2", + "version": "25.2.0.38", + "build": "20240715_1515", + "target": "x64", + "notes": "https://help.autodesk.com/view/RVT/2025/ENU/?guid=RevitReleaseNotes_2025updates_2025_2_html" } ] diff --git a/bin/pyrevit-products.json b/bin/pyrevit-products.json index 7c1d9fa36..0e5601c58 100644 --- a/bin/pyrevit-products.json +++ b/bin/pyrevit-products.json @@ -1,476 +1,500 @@ -[ - { - "product": "pyRevit", - "release": "4.8.14.24016+1909", - "version": "4.8.14.24016+1909", - "key": "f2a3da53-6f34-41d5-abbd-389ffa7f4d5f" - }, - { - "product": "pyRevit", - "release": "4.8.13.23182+2215", - "version": "4.8.13.23182+2215", - "key": "6a6637c3-859c-4fba-9ed9-03957adee956" - }, - { - "product": "pyRevit", - "release": "4.8.12.22247+0031", - "version": "4.8.12.22247+0031", - "key": "a241ce67-c9b1-41f8-8c20-65d6de92db16" - }, - { - "product": "pyRevit", - "release": "4.8.11.22151+0454", - "version": "4.8.11.22151+0454", - "key": "ee4c9248-a3a4-4a4a-bed8-7a1c28102bc1" - }, - { - "product": "pyRevit", - "release": "4.8.10.22040+1743", - "version": "4.8.10.22040+1743", - "key": "d56fb4d2-b004-4508-bf3d-8ebd5cb466b7" - }, - { - "product": "pyRevit", - "release": "4.8.9.21361+0320", - "version": "4.8.9.21361+0320", - "key": "56307bc9-65f7-4f28-b701-cb88d141b592" - }, - { - "product": "pyRevit", - "release": "4.8.9.21359+1855", - "version": "4.8.9.21359+1855", - "key": "c4bdcf02-55f0-49e4-8db2-6d9bf5bb8287" - }, - { - "product": "pyRevit", - "release": "4.8.8", - "version": "4.8.8", - "key": "{CA372AB6-355A-4270-91DD-144DF75E1B57}" - }, - { - "product": "pyRevit", - "release": "4.8.7", - "version": "4.8.7", - "key": "{FED5DEF7-8D3B-4832-BB3E-55C10FCF9ACF}" - }, - { - "product": "pyRevit", - "release": "4.8.6", - "version": "4.8.6", - "key": "{32B7C208-2ACC-4D2B-9C75-5BAEE22E7F85}" - }, - { - "product": "pyRevit", - "release": "4.8.5", - "version": "4.8.5", - "key": "{F13EA93D-4DB1-4149-A86A-B0EFE54ED6AC}" - }, - { - "product": "pyRevit", - "release": "4.8.4", - "version": "4.8.4", - "key": "{CA4CAB91-D337-4A68-BCF7-D56B77327D3A}" - }, - { - "product": "pyRevit", - "release": "4.8.3", - "version": "4.8.3", - "key": "{696310B4-5E37-4437-B047-20954E4B2814}" - }, - { - "product": "pyRevit", - "release": "4.8.2", - "version": "4.8.2", - "key": "{ECFE3DF3-2276-4A11-BA07-9F166AFE4693}" - }, - { - "product": "pyRevit", - "release": "4.8.1", - "version": "4.8.1", - "key": "{311A0079-4026-4F30-9288-619E8824DCA5}" - }, - { - "product": "pyRevit", - "release": "4.8.0", - "version": "4.8.0", - "key": "{CDA0124F-714E-4F93-BF5D-37FF54C25F15}" - }, - { - "product": "pyRevit", - "release": "4.7.6", - "version": "4.7.6", - "key": "{57D90459-1106-444E-A9DC-DC68435BBAEE}" - }, - { - "product": "pyRevit", - "release": "4.7.5", - "version": "4.7.5", - "key": "{40BE31F6-E27A-49D0-ABF5-67778407DD6F}" - }, - { - "product": "pyRevit", - "release": "4.7 Final", - "version": "4.7.4", - "key": "{8A28EE04-5F33-409A-A3B2-7B38FFF2ADF1}" - }, - { - "product": "pyRevit", - "release": "4.7-beta4", - "version": "4.7.3", - "key": "{4D75C52D-F32E-486A-ADED-C7E77E3A8687}" - }, - { - "product": "pyRevit", - "release": "4.7-beta3", - "version": "4.7.2", - "key": "{83110B68-9131-4D58-95AB-D05D785A22E1}" - }, - { - "product": "pyRevit", - "release": "4.7-beta2", - "version": "4.7.1", - "key": "{D719552C-6D81-4436-BF06-5F024C83313A}" - }, - { - "product": "pyRevit", - "release": "4.6.24", - "version": "4.6.24", - "key": "{C125D1FC-A13B-4D52-B642-D279DF321191}" - }, - { - "product": "pyRevit", - "release": "4.6.23", - "version": "4.6.23", - "key": "{3C05CBFF-8250-41EA-B91B-93967E436EFF}" - }, - { - "product": "pyRevit", - "release": "4.6.22", - "version": "4.6.22", - "key": "{D763A045-F988-4C82-9A94-20645FAD8D83}" - }, - { - "product": "pyRevit", - "release": "4.6.21", - "version": "4.6.21", - "key": "{DB9FCA88-7183-4A7E-9842-798975628854}" - }, - { - "product": "pyRevit", - "release": "4.6.20", - "version": "4.6.20", - "key": "{2FA86D06-A1A1-4908-BEB9-877B62D28D75}" - }, - { - "product": "pyRevit", - "release": "4.6.19", - "version": "4.6.19", - "key": "{BFEA01ED-43D5-4B73-8C7D-01A075B1F967}" - }, - { - "product": "pyRevit", - "release": "4.6.18", - "version": "4.6.18", - "key": "{21D49B9A-05AA-4E2F-8744-1653C37AC5D6}" - }, - { - "product": "pyRevit", - "release": "4.6.17", - "version": "4.6.17", - "key": "{309D684B-5279-4DA7-89AE-0870AECDEA4D}" - }, - { - "product": "pyRevit", - "release": "4.6.16", - "version": "4.6.16", - "key": "{8A958BB7-C38A-417B-8818-EF3FF1F6615F}" - }, - { - "product": "pyRevit", - "release": "4.7-beta", - "version": "4.7.0", - "key": "{70FAC724-6300-4037-9178-6A0002B98A65}" - }, - { - "product": "pyRevit", - "release": "4.6.15", - "version": "4.6.15", - "key": "{67AA2183-02A8-4851-9653-1BEA54E0F9A1}" - }, - { - "product": "pyRevit", - "release": "4.6.14", - "version": "4.6.14", - "key": "{2FE2F748-8EF1-4012-9CEE-5A8AA9BF1114}" - }, - { - "product": "pyRevit", - "release": "4.6.13", - "version": "4.6.13", - "key": "{A596729B-C818-48EB-85E6-957B5537328F}" - }, - { - "product": "pyRevit", - "release": "4.6.12", - "version": "4.6.12", - "key": "{F013A175-38C0-436F-9234-6163E45C3B52}" - }, - { - "product": "pyRevit", - "release": "4.6.11", - "version": "4.6.11", - "key": "{98A0A70D-7F59-4937-A6B9-00A1E2EAC294}" - }, - { - "product": "pyRevit", - "release": "4.6.10", - "version": "4.6.10", - "key": "{6A1713AA-256C-4F10-AB96-DD12A225677E}" - }, - { - "product": "pyRevit", - "release": "4.6.9", - "version": "4.6.9", - "key": "{26F3AF6F-DC19-41BF-98BE-C39C56C413D2}" - }, - { - "product": "pyRevit", - "release": "4.6.8", - "version": "4.6.8", - "key": "{C433FE4C-BE21-405D-8D7B-043392763FC7}" - }, - { - "product": "pyRevit", - "release": "4.6.7", - "version": "4.6.7", - "key": "{B105FB5A-0ACF-4A07-9A14-057886D5E25D}" - }, - { - "product": "pyRevit", - "release": "4.6.6", - "version": "4.6.6", - "key": "{E119DE40-5871-479A-96E9-C2AE4F9C424B}" - }, - { - "product": "pyRevit", - "release": "4.6.5", - "version": "4.6.5", - "key": "{FC761B9E-3699-419C-A5DE-DEC361C1F6A7}" - }, - { - "product": "pyRevit", - "release": "4.6.4", - "version": "4.6.4", - "key": "{37CFAD58-51D0-4248-90E0-893058455ED1}" - }, - { - "product": "pyRevit", - "release": "4.6.3", - "version": "4.6.3", - "key": "{63160AFE-5B53-49AF-B46B-527BCBA0AC6E}" - }, - { - "product": "pyRevit", - "release": "4.6.2", - "version": "4.6.2", - "key": "{31A23489-A61B-4786-A857-F95DEB45573C}" - }, - { - "product": "pyRevit", - "release": "4.6.1", - "version": "4.6.1", - "key": "{EF91A585-DC0C-43B8-B88B-4C130F430E84}" - }, - { - "product": "pyRevit CLI", - "release": "4.8.14.24016+1909", - "version": "4.8.14.24016+1909", - "key": "9557b432-cf79-4ece-91cf-b8f996c88b47" - }, - { - "product": "pyRevit CLI", - "release": "4.8.13.23182+2215", - "version": "4.8.13.23182+2215", - "key": "48b17832-a795-41fe-ac44-29ce052b3dba" - }, - { - "product": "pyRevit CLI", - "release": "4.8.12.22247+0031", - "version": "4.8.12.22247+0031", - "key": "52cc6210-7507-4dd3-9b18-6314d2c0abc4" - }, - { - "product": "pyRevit CLI", - "release": "4.8.11.22151+0454", - "version": "4.8.11.22151+0454", - "key": "942e8317-c392-4020-9fe8-15e8ddb1df45" - }, - { - "product": "pyRevit CLI", - "release": "4.8.10.22040+1743", - "version": "4.8.10.22040+1743", - "key": "a77c5ef7-194d-4211-810e-720a7957f0c1" - }, - { - "product": "pyRevit CLI", - "release": "4.8.9.21361+0320", - "version": "4.8.9.21361+0320", - "key": "e71ec326-b624-4530-b236-ecd0ba1b4a99" - }, - { - "product": "pyRevit CLI", - "release": "4.8.9.21359+1855", - "version": "4.8.9.21359+1855", - "key": "5d419b28-c737-4fd3-9c33-6da59628a443" - }, - { - "product": "pyRevit CLI", - "release": "4.8.8", - "version": "4.8.8", - "key": "{8E0191BC-C5DB-4F0E-8F52-6DF04C2B8CE8}" - }, - { - "product": "pyRevit CLI", - "release": "4.8.7", - "version": "4.8.7", - "key": "{E61BB97E-6FF1-4706-A92E-D9F38EB9C77B}" - }, - { - "product": "pyRevit CLI", - "release": "4.8.6", - "version": "4.8.6", - "key": "{AB14082F-168E-45DE-98A7-7C99DB00FFE7}" - }, - { - "product": "pyRevit CLI", - "release": "4.8.5", - "version": "4.8.5", - "key": "{AA15AF8E-2D65-40EF-A9E6-C920D83984E0}" - }, - { - "product": "pyRevit CLI", - "release": "4.8.4", - "version": "4.8.4", - "key": "{EF5EC593-2F57-44D8-8456-CFB05247ADA0}" - }, - { - "product": "pyRevit CLI", - "release": "4.8.3", - "version": "4.8.3", - "key": "{F0958CD1-EEF8-481D-871C-7501947EC650}" - }, - { - "product": "pyRevit CLI", - "release": "4.8.2", - "version": "4.8.2", - "key": "{667ABAF1-CF3A-4CF6-AF75-68F5CA26BFA6}" - }, - { - "product": "pyRevit CLI", - "release": "4.8.1", - "version": "4.8.1", - "key": "{7FE9A723-CD7C-47E8-A0E6-C8452F0AE64E}" - }, - { - "product": "pyRevit CLI", - "release": "4.8.0", - "version": "4.8.0", - "key": "{A0465103-77E8-4880-8192-9D055744798B}" - }, - { - "product": "pyRevit CLI", - "release": "0.25.0", - "version": "0.25.0", - "key": "{27F44ADD-E91B-4733-B4FC-51473A2FAC3D}" - }, - { - "product": "pyRevit CLI", - "release": "0.24.0", - "version": "0.24.0", - "key": "{21E2B6B9-B39B-4482-99C0-C83B93181870}" - }, - { - "product": "pyRevit CLI", - "release": "0.21.0", - "version": "0.21.0", - "key": "{8D13B375-35DF-4A04-8A47-BF4A8C843ADB}" - }, - { - "product": "pyRevit CLI", - "release": "0.17.0", - "version": "0.17.0", - "key": "{4D1CD2D8-BDCD-4B44-A71B-1775AF4A4EA9}" - }, - { - "product": "pyRevit CLI", - "release": "0.16.0", - "version": "0.16.0", - "key": "{835919B1-5715-4E3C-8112-BB941FA435E8}" - }, - { - "product": "pyRevit CLI", - "release": "0.15.0", - "version": "0.15.0", - "key": "{A90B8942-A3EB-4AA5-96BE-2EE2606C69A6}" - }, - { - "product": "pyRevit CLI", - "release": "0.14.0", - "version": "0.14.0", - "key": "{F1F6254F-1465-4B0D-A4DE-24D2D297AE30}" - }, - { - "product": "pyRevit CLI", - "release": "0.13.0", - "version": "0.13.0", - "key": "{0D50CCF6-35DF-47A2-B13A-D442C835FFB5}" - }, - { - "product": "pyRevit CLI", - "release": "0.12.0", - "version": "0.12.0", - "key": "{B6BA75F8-61A0-42CA-9E03-17503460854E}" - }, - { - "product": "pyRevit CLI", - "release": "0.11.0", - "version": "0.11.0", - "key": "{3B7168BD-E66B-4CF0-B22E-87A3BB809384}" - }, - { - "product": "pyRevit CLI", - "release": "0.10.0", - "version": "0.10.0", - "key": "{949D5537-B9CA-45B0-B69E-CF627F8F2923}" - }, - { - "product": "pyRevit CLI", - "release": "0.9.8", - "version": "0.9.8", - "key": "{D5505166-C49A-436F-B25A-9FBD0632F6F0}" - }, - { - "product": "pyRevit CLI", - "release": "0.9.7", - "version": "0.9.7", - "key": "{D5505166-C49A-436F-B25A-9FBD0632F6F0}" - }, - { - "product": "pyRevit CLI", - "release": "0.9.6", - "version": "0.9.6", - "key": "{A72CCEB0-FD16-472D-8FF1-5215981985F3}" - }, - { - "product": "pyRevit CLI", - "release": "0.9.0", - "version": "0.9.0", - "key": "{4F364726-0CD9-4E0C-A2F6-1FC42DE4CF7C}" - }, - { - "product": "pyRevit CLI", - "release": "0.6.0", - "version": "0.6.0", - "key": "{00C758B9-116B-4E07-8A65-1428643331C8}" - } +[ + { + "product": "pyRevit", + "release": "4.8.16.24121+2117", + "version": "4.8.16.24121+2117", + "key": "c8a4b720-9699-4a03-bc67-273bab978723" + }, + { + "product": "pyRevit", + "release": "4.8.15.24089+0912", + "version": "4.8.15.24089+0912", + "key": "6f430f6a-c452-4aa1-bb00-b690c50bea01" + }, + { + "product": "pyRevit", + "release": "4.8.14.24016+1909", + "version": "4.8.14.24016+1909", + "key": "f2a3da53-6f34-41d5-abbd-389ffa7f4d5f" + }, + { + "product": "pyRevit", + "release": "4.8.13.23182+2215", + "version": "4.8.13.23182+2215", + "key": "6a6637c3-859c-4fba-9ed9-03957adee956" + }, + { + "product": "pyRevit", + "release": "4.8.12.22247+0031", + "version": "4.8.12.22247+0031", + "key": "a241ce67-c9b1-41f8-8c20-65d6de92db16" + }, + { + "product": "pyRevit", + "release": "4.8.11.22151+0454", + "version": "4.8.11.22151+0454", + "key": "ee4c9248-a3a4-4a4a-bed8-7a1c28102bc1" + }, + { + "product": "pyRevit", + "release": "4.8.10.22040+1743", + "version": "4.8.10.22040+1743", + "key": "d56fb4d2-b004-4508-bf3d-8ebd5cb466b7" + }, + { + "product": "pyRevit", + "release": "4.8.9.21361+0320", + "version": "4.8.9.21361+0320", + "key": "56307bc9-65f7-4f28-b701-cb88d141b592" + }, + { + "product": "pyRevit", + "release": "4.8.9.21359+1855", + "version": "4.8.9.21359+1855", + "key": "c4bdcf02-55f0-49e4-8db2-6d9bf5bb8287" + }, + { + "product": "pyRevit", + "release": "4.8.8", + "version": "4.8.8", + "key": "{CA372AB6-355A-4270-91DD-144DF75E1B57}" + }, + { + "product": "pyRevit", + "release": "4.8.7", + "version": "4.8.7", + "key": "{FED5DEF7-8D3B-4832-BB3E-55C10FCF9ACF}" + }, + { + "product": "pyRevit", + "release": "4.8.6", + "version": "4.8.6", + "key": "{32B7C208-2ACC-4D2B-9C75-5BAEE22E7F85}" + }, + { + "product": "pyRevit", + "release": "4.8.5", + "version": "4.8.5", + "key": "{F13EA93D-4DB1-4149-A86A-B0EFE54ED6AC}" + }, + { + "product": "pyRevit", + "release": "4.8.4", + "version": "4.8.4", + "key": "{CA4CAB91-D337-4A68-BCF7-D56B77327D3A}" + }, + { + "product": "pyRevit", + "release": "4.8.3", + "version": "4.8.3", + "key": "{696310B4-5E37-4437-B047-20954E4B2814}" + }, + { + "product": "pyRevit", + "release": "4.8.2", + "version": "4.8.2", + "key": "{ECFE3DF3-2276-4A11-BA07-9F166AFE4693}" + }, + { + "product": "pyRevit", + "release": "4.8.1", + "version": "4.8.1", + "key": "{311A0079-4026-4F30-9288-619E8824DCA5}" + }, + { + "product": "pyRevit", + "release": "4.8.0", + "version": "4.8.0", + "key": "{CDA0124F-714E-4F93-BF5D-37FF54C25F15}" + }, + { + "product": "pyRevit", + "release": "4.7.6", + "version": "4.7.6", + "key": "{57D90459-1106-444E-A9DC-DC68435BBAEE}" + }, + { + "product": "pyRevit", + "release": "4.7.5", + "version": "4.7.5", + "key": "{40BE31F6-E27A-49D0-ABF5-67778407DD6F}" + }, + { + "product": "pyRevit", + "release": "4.7 Final", + "version": "4.7.4", + "key": "{8A28EE04-5F33-409A-A3B2-7B38FFF2ADF1}" + }, + { + "product": "pyRevit", + "release": "4.7-beta4", + "version": "4.7.3", + "key": "{4D75C52D-F32E-486A-ADED-C7E77E3A8687}" + }, + { + "product": "pyRevit", + "release": "4.7-beta3", + "version": "4.7.2", + "key": "{83110B68-9131-4D58-95AB-D05D785A22E1}" + }, + { + "product": "pyRevit", + "release": "4.7-beta2", + "version": "4.7.1", + "key": "{D719552C-6D81-4436-BF06-5F024C83313A}" + }, + { + "product": "pyRevit", + "release": "4.6.24", + "version": "4.6.24", + "key": "{C125D1FC-A13B-4D52-B642-D279DF321191}" + }, + { + "product": "pyRevit", + "release": "4.6.23", + "version": "4.6.23", + "key": "{3C05CBFF-8250-41EA-B91B-93967E436EFF}" + }, + { + "product": "pyRevit", + "release": "4.6.22", + "version": "4.6.22", + "key": "{D763A045-F988-4C82-9A94-20645FAD8D83}" + }, + { + "product": "pyRevit", + "release": "4.6.21", + "version": "4.6.21", + "key": "{DB9FCA88-7183-4A7E-9842-798975628854}" + }, + { + "product": "pyRevit", + "release": "4.6.20", + "version": "4.6.20", + "key": "{2FA86D06-A1A1-4908-BEB9-877B62D28D75}" + }, + { + "product": "pyRevit", + "release": "4.6.19", + "version": "4.6.19", + "key": "{BFEA01ED-43D5-4B73-8C7D-01A075B1F967}" + }, + { + "product": "pyRevit", + "release": "4.6.18", + "version": "4.6.18", + "key": "{21D49B9A-05AA-4E2F-8744-1653C37AC5D6}" + }, + { + "product": "pyRevit", + "release": "4.6.17", + "version": "4.6.17", + "key": "{309D684B-5279-4DA7-89AE-0870AECDEA4D}" + }, + { + "product": "pyRevit", + "release": "4.6.16", + "version": "4.6.16", + "key": "{8A958BB7-C38A-417B-8818-EF3FF1F6615F}" + }, + { + "product": "pyRevit", + "release": "4.7-beta", + "version": "4.7.0", + "key": "{70FAC724-6300-4037-9178-6A0002B98A65}" + }, + { + "product": "pyRevit", + "release": "4.6.15", + "version": "4.6.15", + "key": "{67AA2183-02A8-4851-9653-1BEA54E0F9A1}" + }, + { + "product": "pyRevit", + "release": "4.6.14", + "version": "4.6.14", + "key": "{2FE2F748-8EF1-4012-9CEE-5A8AA9BF1114}" + }, + { + "product": "pyRevit", + "release": "4.6.13", + "version": "4.6.13", + "key": "{A596729B-C818-48EB-85E6-957B5537328F}" + }, + { + "product": "pyRevit", + "release": "4.6.12", + "version": "4.6.12", + "key": "{F013A175-38C0-436F-9234-6163E45C3B52}" + }, + { + "product": "pyRevit", + "release": "4.6.11", + "version": "4.6.11", + "key": "{98A0A70D-7F59-4937-A6B9-00A1E2EAC294}" + }, + { + "product": "pyRevit", + "release": "4.6.10", + "version": "4.6.10", + "key": "{6A1713AA-256C-4F10-AB96-DD12A225677E}" + }, + { + "product": "pyRevit", + "release": "4.6.9", + "version": "4.6.9", + "key": "{26F3AF6F-DC19-41BF-98BE-C39C56C413D2}" + }, + { + "product": "pyRevit", + "release": "4.6.8", + "version": "4.6.8", + "key": "{C433FE4C-BE21-405D-8D7B-043392763FC7}" + }, + { + "product": "pyRevit", + "release": "4.6.7", + "version": "4.6.7", + "key": "{B105FB5A-0ACF-4A07-9A14-057886D5E25D}" + }, + { + "product": "pyRevit", + "release": "4.6.6", + "version": "4.6.6", + "key": "{E119DE40-5871-479A-96E9-C2AE4F9C424B}" + }, + { + "product": "pyRevit", + "release": "4.6.5", + "version": "4.6.5", + "key": "{FC761B9E-3699-419C-A5DE-DEC361C1F6A7}" + }, + { + "product": "pyRevit", + "release": "4.6.4", + "version": "4.6.4", + "key": "{37CFAD58-51D0-4248-90E0-893058455ED1}" + }, + { + "product": "pyRevit", + "release": "4.6.3", + "version": "4.6.3", + "key": "{63160AFE-5B53-49AF-B46B-527BCBA0AC6E}" + }, + { + "product": "pyRevit", + "release": "4.6.2", + "version": "4.6.2", + "key": "{31A23489-A61B-4786-A857-F95DEB45573C}" + }, + { + "product": "pyRevit", + "release": "4.6.1", + "version": "4.6.1", + "key": "{EF91A585-DC0C-43B8-B88B-4C130F430E84}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.16.24121+2117", + "version": "4.8.16.24121+2117", + "key": "2669428b-35bc-4824-afb5-9c8b7e343d3d" + }, + { + "product": "pyRevit CLI", + "release": "4.8.15.24089+0912", + "version": "4.8.15.24089+0912", + "key": "2e94b164-49b1-49ff-8329-75a15000d3f9" + }, + { + "product": "pyRevit CLI", + "release": "4.8.14.24016+1909", + "version": "4.8.14.24016+1909", + "key": "9557b432-cf79-4ece-91cf-b8f996c88b47" + }, + { + "product": "pyRevit CLI", + "release": "4.8.13.23182+2215", + "version": "4.8.13.23182+2215", + "key": "48b17832-a795-41fe-ac44-29ce052b3dba" + }, + { + "product": "pyRevit CLI", + "release": "4.8.12.22247+0031", + "version": "4.8.12.22247+0031", + "key": "52cc6210-7507-4dd3-9b18-6314d2c0abc4" + }, + { + "product": "pyRevit CLI", + "release": "4.8.11.22151+0454", + "version": "4.8.11.22151+0454", + "key": "942e8317-c392-4020-9fe8-15e8ddb1df45" + }, + { + "product": "pyRevit CLI", + "release": "4.8.10.22040+1743", + "version": "4.8.10.22040+1743", + "key": "a77c5ef7-194d-4211-810e-720a7957f0c1" + }, + { + "product": "pyRevit CLI", + "release": "4.8.9.21361+0320", + "version": "4.8.9.21361+0320", + "key": "e71ec326-b624-4530-b236-ecd0ba1b4a99" + }, + { + "product": "pyRevit CLI", + "release": "4.8.9.21359+1855", + "version": "4.8.9.21359+1855", + "key": "5d419b28-c737-4fd3-9c33-6da59628a443" + }, + { + "product": "pyRevit CLI", + "release": "4.8.8", + "version": "4.8.8", + "key": "{8E0191BC-C5DB-4F0E-8F52-6DF04C2B8CE8}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.7", + "version": "4.8.7", + "key": "{E61BB97E-6FF1-4706-A92E-D9F38EB9C77B}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.6", + "version": "4.8.6", + "key": "{AB14082F-168E-45DE-98A7-7C99DB00FFE7}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.5", + "version": "4.8.5", + "key": "{AA15AF8E-2D65-40EF-A9E6-C920D83984E0}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.4", + "version": "4.8.4", + "key": "{EF5EC593-2F57-44D8-8456-CFB05247ADA0}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.3", + "version": "4.8.3", + "key": "{F0958CD1-EEF8-481D-871C-7501947EC650}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.2", + "version": "4.8.2", + "key": "{667ABAF1-CF3A-4CF6-AF75-68F5CA26BFA6}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.1", + "version": "4.8.1", + "key": "{7FE9A723-CD7C-47E8-A0E6-C8452F0AE64E}" + }, + { + "product": "pyRevit CLI", + "release": "4.8.0", + "version": "4.8.0", + "key": "{A0465103-77E8-4880-8192-9D055744798B}" + }, + { + "product": "pyRevit CLI", + "release": "0.25.0", + "version": "0.25.0", + "key": "{27F44ADD-E91B-4733-B4FC-51473A2FAC3D}" + }, + { + "product": "pyRevit CLI", + "release": "0.24.0", + "version": "0.24.0", + "key": "{21E2B6B9-B39B-4482-99C0-C83B93181870}" + }, + { + "product": "pyRevit CLI", + "release": "0.21.0", + "version": "0.21.0", + "key": "{8D13B375-35DF-4A04-8A47-BF4A8C843ADB}" + }, + { + "product": "pyRevit CLI", + "release": "0.17.0", + "version": "0.17.0", + "key": "{4D1CD2D8-BDCD-4B44-A71B-1775AF4A4EA9}" + }, + { + "product": "pyRevit CLI", + "release": "0.16.0", + "version": "0.16.0", + "key": "{835919B1-5715-4E3C-8112-BB941FA435E8}" + }, + { + "product": "pyRevit CLI", + "release": "0.15.0", + "version": "0.15.0", + "key": "{A90B8942-A3EB-4AA5-96BE-2EE2606C69A6}" + }, + { + "product": "pyRevit CLI", + "release": "0.14.0", + "version": "0.14.0", + "key": "{F1F6254F-1465-4B0D-A4DE-24D2D297AE30}" + }, + { + "product": "pyRevit CLI", + "release": "0.13.0", + "version": "0.13.0", + "key": "{0D50CCF6-35DF-47A2-B13A-D442C835FFB5}" + }, + { + "product": "pyRevit CLI", + "release": "0.12.0", + "version": "0.12.0", + "key": "{B6BA75F8-61A0-42CA-9E03-17503460854E}" + }, + { + "product": "pyRevit CLI", + "release": "0.11.0", + "version": "0.11.0", + "key": "{3B7168BD-E66B-4CF0-B22E-87A3BB809384}" + }, + { + "product": "pyRevit CLI", + "release": "0.10.0", + "version": "0.10.0", + "key": "{949D5537-B9CA-45B0-B69E-CF627F8F2923}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.8", + "version": "0.9.8", + "key": "{D5505166-C49A-436F-B25A-9FBD0632F6F0}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.7", + "version": "0.9.7", + "key": "{D5505166-C49A-436F-B25A-9FBD0632F6F0}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.6", + "version": "0.9.6", + "key": "{A72CCEB0-FD16-472D-8FF1-5215981985F3}" + }, + { + "product": "pyRevit CLI", + "release": "0.9.0", + "version": "0.9.0", + "key": "{4F364726-0CD9-4E0C-A2F6-1FC42DE4CF7C}" + }, + { + "product": "pyRevit CLI", + "release": "0.6.0", + "version": "0.6.0", + "key": "{00C758B9-116B-4E07-8A65-1428643331C8}" + } ] \ No newline at end of file diff --git a/bin/pyrevit.ico b/bin/pyrevit.ico new file mode 100644 index 000000000..0a88b0cc9 Binary files /dev/null and b/bin/pyrevit.ico differ diff --git a/bin/pyrevit.svg b/bin/pyrevit.svg index d252a463f..5589ba91b 100644 --- a/bin/pyrevit.svg +++ b/bin/pyrevit.svg @@ -1,62 +1,62 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/bin/pyrevit_cli.ico b/bin/pyrevit_cli.ico new file mode 100644 index 000000000..cd51e66ad Binary files /dev/null and b/bin/pyrevit_cli.ico differ diff --git a/bin/pyrevit_pkg.ico b/bin/pyrevit_pkg.ico new file mode 100644 index 000000000..5e585f7a8 Binary files /dev/null and b/bin/pyrevit_pkg.ico differ diff --git a/dev/Directory.Build.props b/dev/Directory.Build.props index ecad774cb..ff090d19f 100644 --- a/dev/Directory.Build.props +++ b/dev/Directory.Build.props @@ -1,25 +1,11 @@ - - bin\$(Configuration)\ - $(MSBuildThisFileDirectory)\..\ - - $(PyRevitRootDir)\bin\ - $(PyRevitBinDir)engines\ - - $(PyRevitRootDir)\dev\ - $(PyRevitDevDir)\libs\ - $(PyRevitDevDir)\modules\ - - $(PyRevitRootDir)\pyrevitlib\ - $(PyRevitRootDir)\extensions\ - - Library - net48 + + x64 - False + true @@ -33,8 +19,18 @@ - 4.8.14.24016+1909 + 5.0.0.24174+2300 Copyright © 2014-2024 pyRevitLabs.io + + + + + + + \ No newline at end of file diff --git a/dev/Directory.Build.targets b/dev/Directory.Build.targets index 040c83531..e7226e7b4 100644 --- a/dev/Directory.Build.targets +++ b/dev/Directory.Build.targets @@ -1,3 +1,34 @@ + + netfx + netcore + + + + bin\$(Configuration) + $(MSBuildThisFileDirectory).. + + $(PyRevitRootDir)\bin\$(NetFolder) + $(PyRevitBinDir)\engines + + $(PyRevitRootDir)\dev + $(PyRevitDevDir)\libs\$(NetFolder) + $(PyRevitDevDir)\modules + + $(PyRevitRootDir)\pyrevitlib + $(PyRevitRootDir)\extensions + + $(PyRevitDevDir)\libs\Revit + $(PyRevitDevDir)\libs\IronPython\ + + + + $(PyRevitRootDir)\bin + + + + 2017 + 2025 + \ No newline at end of file diff --git a/dev/_build.py b/dev/_build.py index 8ce990d1a..d47a85091 100644 --- a/dev/_build.py +++ b/dev/_build.py @@ -11,6 +11,7 @@ import _labs as labs import _telem as telem +import shutil ARTIFACTS = ['bin', 'obj', '.vs', 'TestResults'] @@ -26,7 +27,19 @@ def clean_build(_: Dict[str, str]): def build_binaries(_: Dict[str, str]): """Build all projects under pyRevit dev""" # apidocs.build_docs(_) + labs.build_deps(_) labs.build_labs(_) labs.build_engines(_) + labs.build_runtime(_) telem.build_telem(_) autoc.build_autocmp(_) + + file_list = os.listdir(configs.BINPATH_NETCORE) + for file in file_list: + if file.endswith(".dll")\ + or file.endswith(".png")\ + or file.endswith(".json"): + print(op.join(configs.BINPATH_NETCORE, file)) + print(op.join(configs.ENGINES2PATH_NETCORE, file)) + shutil.copyfile(op.join(configs.BINPATH_NETCORE, file), + op.join(configs.ENGINES2PATH_NETCORE, file)) diff --git a/dev/_changelog.py b/dev/_changelog.py index 8aa1cd276..5a04e1264 100644 --- a/dev/_changelog.py +++ b/dev/_changelog.py @@ -291,7 +291,7 @@ def generate_release_notes(args: Dict[str, str]): install_version_urlsafe = props.get_version(install=True, url_safe=True) base_url = ( - "https://github.com/eirannejad/pyRevit/" + "https://github.com/pyrevitlabs/pyRevit/" f"releases/download/v{install_version_urlsafe}/" ) diff --git a/dev/_labs.py b/dev/_labs.py index 37036c891..9a65aeaf9 100644 --- a/dev/_labs.py +++ b/dev/_labs.py @@ -21,24 +21,42 @@ def _abort(message): sys.exit(1) -def _build(name: str, sln: str, config: str, print_output: Optional[bool] = False): +def _build(name: str, sln: str, config: str = "Release", framework: str = None, publish_dir: str = None, print_output: Optional[bool] = False): utils.ensure_windows() # clean slnpath = op.abspath(sln) - logger.debug("building %s solution: %s", name, slnpath) + logger.debug("building %s solution: %s, configuration: %s", name, slnpath, config) # clean, restore, build - print(f"Building {name}...") - report = utils.system( - [ - install.get_tool("dotnet"), - "build", - slnpath, - "-c", - f"{config}", - ], - dump_stdout=print_output - ) + if publish_dir is None: + print(f"Building {name}...") + report = utils.system( + [ + install.get_tool("dotnet"), + "build", + slnpath, + "-c", + f"{config}", + ], + dump_stdout=print_output + ) + else: + print(f"Publish {name}...") + report = utils.system( + [ + install.get_tool("dotnet"), + "publish", + f"{slnpath}", + "-c", + f"{config}", + "-f", + f"{framework}", + "-o", + f"{publish_dir}", + ], + dump_stdout=print_output + ) + passed, report = utils.parse_dotnet_build_output(report) if not passed: _abort(report) @@ -46,13 +64,50 @@ def _build(name: str, sln: str, config: str, print_output: Optional[bool] = Fals print(f"Building {name} completed successfully") -def build_engines(_: Dict[str, str]): - """Build pyRevit engines""" - _build("ironpython engines", configs.LOADERS, "Release") - _build("cpython 3.7 engine", configs.CPYTHONRUNTIME, "ReleasePY37") - _build("cpython 3.8 engine", configs.CPYTHONRUNTIME, "ReleasePY38") +def build_deps(_: Dict[str, str]): + """Build pyRevit deps""" + _build("MahApps.Metro (styles)", configs.MAHAPPS, framework="net47") + _build("MahApps.Metro (netfx)", configs.MAHAPPS, framework="net47", publish_dir=configs.LIBSPATH_NETFX) + _build("MahApps.Metro (netcore)", configs.MAHAPPS, framework="netcoreapp3.1", publish_dir=configs.LIBSPATH_NETCORE) + + _build("Newtonsoft.Json (netfx)", configs.NEWTONSOFTJSON, framework="net45", publish_dir=configs.LIBSPATH_NETFX) + _build("Newtonsoft.Json (netcore)", configs.NEWTONSOFTJSON, framework="net6.0", publish_dir=configs.LIBSPATH_NETCORE) + + _build("NLog (netfx)", configs.NLOG, framework="net46", publish_dir=configs.LIBSPATH_NETFX) + _build("NLog (netcore)", configs.NLOG, framework="netstandard2.0", publish_dir=configs.LIBSPATH_NETCORE) + + _build("IronPython2 (netfx)", configs.IRONPYTHON2, framework="net48", publish_dir=configs.ENGINES2PATH_NETFX) + _build("IronPython2 (netcore)", configs.IRONPYTHON2_LIB, framework="netstandard2.0", publish_dir=configs.ENGINES2PATH_NETCORE) + _build("IronPython2 (netcore)", configs.IRONPYTHON2_MODULES, framework="netstandard2.0", publish_dir=configs.ENGINES2PATH_NETCORE) + _build("IronPython2 (netcore)", configs.IRONPYTHON2_SQLITE, framework="netstandard2.0", publish_dir=configs.ENGINES2PATH_NETCORE) + _build("IronPython2 (netcore)", configs.IRONPYTHON2_WPF, framework="net6.0-windows", publish_dir=configs.ENGINES2PATH_NETCORE) + + _build("IronPython3 (netfx)", configs.IRONPYTHON3, framework="net48", publish_dir=configs.ENGINES3PATH_NETFX) + _build("IronPython3 (netcore)", configs.IRONPYTHON3_LIB, framework="net6.0", publish_dir=configs.ENGINES3PATH_NETCORE) + _build("IronPython3 (netcore)", configs.IRONPYTHON3_MODULES, framework="net6.0", publish_dir=configs.ENGINES3PATH_NETCORE) + _build("IronPython3 (netcore)", configs.IRONPYTHON3_SQLITE, framework="net6.0", publish_dir=configs.ENGINES3PATH_NETCORE) + _build("IronPython3 (netcore)", configs.IRONPYTHON3_WPF, framework="net6.0-windows", publish_dir=configs.ENGINES3PATH_NETCORE) + + _build("Python.Net (netfx)", configs.CPYTHONRUNTIME, framework="netstandard2.0", publish_dir=configs.LIBSPATH_NETFX) + _build("Python.Net (netcore)", configs.CPYTHONRUNTIME, framework="netstandard2.0", publish_dir=configs.LIBSPATH_NETCORE) + + + +def build_engines(args: Dict[str, str]): + """Build pyRevit engines.""" + config = args.get("") or "Release" + _build("loaders", configs.LOADERS, config=config) + + +def build_labs(args: Dict[str, str]): + """Build pyRevit labs.""" + config = args.get("") or "Release" + _build("labs", configs.LABS, config=config) + _build("cli", configs.LABS_CLI, config=config, framework="net8.0-windows", publish_dir=configs.BINPATH) + _build("doctor", configs.LABS_DOCTOR, config=config, framework="net8.0-windows", publish_dir=configs.BINPATH) -def build_labs(_: Dict[str, str]): - """Build pyRevit labs""" - _build("cli and labs", configs.LABS, "Release") +def build_runtime(args: Dict[str, str]): + """Build pyRevit runtime.""" + config = args.get("") or "Release" + _build("runtime", configs.RUNTIME, config=config) diff --git a/dev/_props.py b/dev/_props.py index 7b0dbeae8..e11f8c8c4 100644 --- a/dev/_props.py +++ b/dev/_props.py @@ -30,7 +30,7 @@ def _get_urlsafe_version(version: str): def _get_release_url(version: str): build_version_urlsafe = _get_urlsafe_version(version) return ( - "https://github.com/eirannejad/pyRevit/" + "https://github.com/pyrevitlabs/pyRevit/" f"releases/tag/v{build_version_urlsafe}/" ) diff --git a/dev/_release.py b/dev/_release.py index 5c70fa4b7..09530925e 100644 --- a/dev/_release.py +++ b/dev/_release.py @@ -279,12 +279,12 @@ def _build_msi_installers(): def _build_choco_packages(): - install_version = props.get_version(install=True) - install_version_urlsafe = props.get_version(install=True, url_safe=True) + build_version_urlsafe = props.get_version(install=False, url_safe=True) base_url = ( - "https://github.com/eirannejad/pyRevit/" - f"releases/download/v{install_version_urlsafe}/" + "https://github.com/pyrevitlabs/pyRevit/" + f"releases/download/v{build_version_urlsafe}/" ) + install_version = props.get_version(install=True) pyrevit_cli_admin_installer = ( configs.PYREVIT_CLI_ADMIN_INSTALLER_NAME.format(version=install_version) + ".exe" diff --git a/dev/libs/IronPython/python_2712pr_lib.zip b/dev/libs/IronPython/python_2712pr_lib.zip new file mode 100644 index 000000000..587f96184 Binary files /dev/null and b/dev/libs/IronPython/python_2712pr_lib.zip differ diff --git a/dev/libs/IronPython/python_340pr_lib.zip b/dev/libs/IronPython/python_340pr_lib.zip index cdc64e66a..75f9641c4 100644 Binary files a/dev/libs/IronPython/python_340pr_lib.zip and b/dev/libs/IronPython/python_340pr_lib.zip differ diff --git a/dev/libs/Revit/2025/AdWindows.dll b/dev/libs/Revit/2025/AdWindows.dll new file mode 100644 index 000000000..628b93fba Binary files /dev/null and b/dev/libs/Revit/2025/AdWindows.dll differ diff --git a/dev/libs/Revit/2025/RevitAPI.dll b/dev/libs/Revit/2025/RevitAPI.dll new file mode 100644 index 000000000..5da0295f0 Binary files /dev/null and b/dev/libs/Revit/2025/RevitAPI.dll differ diff --git a/dev/libs/Revit/2025/RevitAPIUI.dll b/dev/libs/Revit/2025/RevitAPIUI.dll new file mode 100644 index 000000000..ede1a9d56 Binary files /dev/null and b/dev/libs/Revit/2025/RevitAPIUI.dll differ diff --git a/dev/libs/Revit/2025/UIFramework.dll b/dev/libs/Revit/2025/UIFramework.dll new file mode 100644 index 000000000..032021052 Binary files /dev/null and b/dev/libs/Revit/2025/UIFramework.dll differ diff --git a/dev/libs/Revit/2025/Xceed.Wpf.AvalonDock.dll b/dev/libs/Revit/2025/Xceed.Wpf.AvalonDock.dll new file mode 100644 index 000000000..9922aa106 Binary files /dev/null and b/dev/libs/Revit/2025/Xceed.Wpf.AvalonDock.dll differ diff --git a/dev/libs/netcore/ControlzEx.dll b/dev/libs/netcore/ControlzEx.dll new file mode 100644 index 000000000..4eac5b8dd Binary files /dev/null and b/dev/libs/netcore/ControlzEx.dll differ diff --git a/dev/libs/netcore/ControlzEx.xml b/dev/libs/netcore/ControlzEx.xml new file mode 100644 index 000000000..4afe23adc --- /dev/null +++ b/dev/libs/netcore/ControlzEx.xml @@ -0,0 +1,3210 @@ + + + + ControlzEx + + + + + Automation-Peer for . + + + + + Initializes a new instance. + + + + + + + + Automation-Peer for in . + + + + + Initializes a new instance. + + + + + + + + Gets the real tab item. + + + + Identifies the dependency property. + + + + Gets or sets the Badge content to display. + + + + Identifies the dependency property. + + + + The BadgeFontFamily property specifies the name of font family. + + + + Identifies the dependency property. + + + + The BadgeFontStyle property requests normal, italic, and oblique faces within a font family. + + + + Identifies the dependency property. + + + + The BadgeFontWeight property specifies the weight of the font. + + + + Identifies the dependency property. + + + + The BadgeFontStretch property selects a normal, condensed, or extended face from a font family. + + + + Identifies the dependency property. + + + + The BadgeFontSize property specifies the size of the font. + + + + Identifies the dependency property. + + + + Gets or sets the background brush for the Badge. + + + + Identifies the dependency property. + + + + Gets or sets the foreground brush for the Badge. + + + + Identifies the dependency property. + + + + Gets or sets the border brush for the Badge. + + + + Identifies the dependency property. + + + + Gets or sets the border thickness for the Badge. + + + + Identifies the dependency property. + + + + Gets or sets the placement of the Badge relative to its content. + + + + Identifies the dependency property. + + + + Gets or sets a margin which can be used to make minor adjustments to the placement of the Badge. + + + + Identifies the dependency property. + + + + Gets or sets the for the Badge + + + + Identifies the dependency property. + + + + Gets or sets the for the Badge + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the Badge property if it is displayed as a string. + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + + Indicates whether the Badge has content to display. + + + + + for . + + + + + Gets or sets a brush which is used as the glow when the window is active. + + + + + for . + + + + + Gets or sets a brush which is used as the glow when the window is not active. + + + + + for . + + + + + Defines whether glow transitions should be used or not. + + + + + for . + + + + + Gets or sets resize border thickness. + + + + + + + + Updates all glow windows (visible, hidden, collapsed) + + + + + Sets the opacity to all glow windows + + + + + Starts the opacity storyboard 0 -> 1 + + + + + Shows all glow windows + + + + + Closes all glow windows + + + + + Enables an InputMask for with 2 Properties: , . + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Pasting prüft ob korrekte Daten reingepastet werden + + + + + Falls eine Textauswahl vorliegt wird diese entsprechend behandelt. + + + + + With this class we can make custom window styles. + + + + Underlying HWND for the _window. + + Critical : Critical member + + + + Underlying HWND for the _window. + + Critical : Critical member provides access to HWND's window messages which are critical + + + + + Mirror property for . + + + + + for . + + + + + Defines if the Taskbar should be ignored when maximizing a Window. + This only works with WindowStyle = None. + + + + + for . + + + + + Gets/sets if the border thickness value should be kept on maximize + if the MaxHeight/MaxWidth of the window is less than the monitor resolution. + + + + + for . + + + + + Gets or sets whether the resizing of the window should be tried in a way that does not cause flicker/jitter, especially when resizing from the left side. + + + Please note that setting this to true may cause resize lag and black areas appearing on some systems. + + + + + for . + + + + + for . + + + + + Gets whether the non-client area is active or not. + + + + + Gets or sets whether if the minimize button is visible and the minimize system menu is enabled. + + + + + Gets or sets whether if the maximize/restore button is visible and the maximize/restore system menu is enabled. + + + + + + + + Gets the default resize border thicknes from the system parameters. + + + + + Occurs during the cleanup of this behavior. + + + + + + + + Is called when the associated object of this instance is loaded + + + + + This fix is needed because style triggers don't work if someone sets the value locally/directly on the window. + + + + + Critical : Store critical methods in critical callback table + Safe : Demands full trust permissions + + + + + Critical : Calls critical methods + Safe : Demands full trust permissions + + + + + Critical : Calls critical methods + + + + + Critical : Accesses critical _hwnd + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + This method handles the window size if the taskbar is set to auto-hide. + + + Critical : Calls critical methods + + + + + Critical : Calls critical Marshal.PtrToStructure + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical method + + + + + Critical : Calls critical method + + + + + Critical : Calls critical Marshal.PtrToStructure + + + + + Critical : Calls critical Marshal.PtrToStructure + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + Add and remove a native WindowStyle from the HWND. + The styles to be removed. These can be bitwise combined. + The styles to be added. These can be bitwise combined. + Whether the styles of the HWND were modified as a result of this call. + + Critical : Calls critical methods + + + + + Get the WindowState as the native HWND knows it to be. This isn't necessarily the same as what Window thinks. + + + Critical : Calls critical methods + + + + + Get the bounding rectangle for the window in physical coordinates. + + The bounding rectangle for the window. + + Critical : Calls critical methods + + + + + Update the items in the system menu based on the current, or assumed, WindowState. + + + The state to assume that the Window is in. This can be null to query the Window's state. + + + We want to update the menu while we have some control over whether the caption will be repainted. + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + Matrix of the HT values to return when responding to NC window messages. + + + + + Critical : Calls critical methods + + + + + Critical : Calls critical methods + + + + + GlowWindow + + + + + InitializeComponent + + + + + The standard WPF TabControl is quite bad in the fact that it only + even contains the current TabItem in the VisualTree, so if you + have complex views it takes a while to re-create the view each tab + selection change.Which makes the standard TabControl very sticky to + work with. This class along with its associated ControlTemplate + allow all TabItems to remain in the VisualTree without it being Sticky. + It does this by keeping all TabItem content in the VisualTree but + hides all inactive TabItem content, and only keeps the active TabItem + content shown. + + Acknowledgement + Eric Burke + http://eric.burke.name/dotnetmania/2009/04/26/22.09.28 + Sacha Barber: https://sachabarbs.wordpress.com/about-me/ + http://stackoverflow.com/a/10210889/920384 + http://stackoverflow.com/a/7838955/920384 + + + We use two attached properties to later recognize the content presenters we generated. + We need the OwningItem because the TabItem associated with an item can later change. + + We need the OwningTabItem to reduce the amount of lookups we have to do. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Helper for getting from . + to read from. + OwningTabItem property value. + + + Helper for setting on . + to set on. + OwningTabItem property value. + + + Helper for setting on . + to set on. + OwningItem property value. + + + Helper for getting from . + to read from. + OwningItem property value. + + + Identifies the dependency property. + + + + Gets or sets whether keyboard focus should be moved to the content area when the selected item changes. + + + + + Initializes a new instance. + + + + + Defines if the TabPanel (Tab-Header) are visible. + + + + + Gets or sets the child content visibility. + + + The child content visibility. + + + + + + + + + + + + When the items change we remove any generated panel children and add any new ones as necessary. + + + + + + + + + + + + + + Copied from . wish it were protected in that class instead of private. + + + + + Clears all current children by calling and calls afterwards. + + + + + Generate a ContentPresenter for the selected item and control the visibility of already created presenters. + + + + + Create the child ContentPresenter for the given item (could be data or a TabItem) if none exists. + + + + + Find the for the given object. Data could be a TabItem or a piece of data. + + + + + Gets the value associated with directly from . + + + + + Checks if directly contains . + + + + + Helper class for a common focusing problem. + The focus itself isn't the problem. If we use the common focusing methods the control get the focus + but it doesn't get the focus visual style. + The KeyboardNavigation class handles the visual style only if the control get the focus from a keyboard + device or if the SystemParameters.KeyboardCues is true. + + + + + Gets the KeyboardNavigationEx singleton instance. + + + + + Shows the focus visual of the current focused UI element. + Works only together with AlwaysShowFocusVisual property. + + + + + Focuses the specified element and shows the focus visual style. + + The element which will be focused. + + + + Attached DependencyProperty for setting AlwaysShowFocusVisual for a UI element. + + + + + Gets a the value which indicates if the UI element always show the focus visual style. + + + + + Sets a the value which indicates if the UI element always show the focus visual style. + + + + IID_IApplicationAssociationRegistration + + + IID_IConnectionPoint + + + IID_IConnectionPointContainer + + + IID_IEnumConnectionPoints + + + IID_IEnumConnections + + + IID_IEnumIDList + + + IID_IEnumObjects + + + IID_IFileDialog + + + IID_IFileDialogEvents + + + IID_IFileOpenDialog + + + IID_IFileSaveDialog + + + IID_IHTMLDocument + + + IID_IHTMLDocument2 + + + IID_IModalWindow + + + IID_IObjectArray + + + IID_IObjectCollection + + + IID_IPropertyNotifySink + + + IID_IPropertyStore + + + IID_IServiceProvider + + + IID_IShellFolder + + + IID_IShellLink + + + IID_IShellItem + + + IID_IShellItem2 + + + IID_IShellItemArray + + + IID_ITaskbarList + + + IID_ITaskbarList2 + + + IID_IUnknown + + + IID_IWebBrowser2 + + + DIID_DWebBrowserEvents + + + IID_DWebBrowserEvents2 + + + IID_IWICBitmapDecoder + + + IID_IWICBitmapFlipRotator + + + IID_IWICBitmapFrameDecode + + + IID_IWICBitmap + + + IID_IWICBitmapSource + + + IID_IWICFormatConverter + + + IID_IWICImagingFactory + + + IID_IWICStream + + + IID_IApplicationDestinations + + + IID_IApplicationDocumentLists + + + IID_ICustomDestinationList + + + IID_IObjectWithAppUserModelID + + + IID_IObjectWithProgID + + + IID_ITaskbarList3 + + + IID_ITaskbarList4 + + + SID_SWebBrowserApp + + + CLSID_ApplicationAssociationRegistration + IID_IApplicationAssociationRegistration + + + CLSID_DragDropHelper + + + CLSID_FileOpenDialog + IID_IFileOpenDialog + + + CLSID_FileSaveDialog + IID_IFileSaveDialog + + + CLSID_TaskbarList + IID_ITaskbarList + + + CLSID_EnumerableObjectCollection + IID_IEnumObjects. + + + CLSID_ShellLink + IID_IShellLink + + + CLSID_WICImagingFactory + + + CLSID_DestinationList + IID_ICustomDestinationList + + + CLSID_ApplicationDestinations + IID_IApplicationDestinations + + + CLSID_ApplicationDocumentLists + IID_IApplicationDocumentLists + + + A static class for verifying assumptions. + + + A function signature for Assert.Evaluate. + + + A function signature for Assert.Implies. + Returns the truth of a predicate. + + + + Executes the specified argument. + + The function to execute. + + + Obsolete: Use Standard.Assert.AreEqual instead of Assert.Equals + The generic type to compare for equality. + The first generic type data to compare. This is is the expected value. + The second generic type data to compare. This is the actual value. + + + + Verifies that two generic type data are equal. The assertion fails if they are not. + + The generic type to compare for equality. + The first generic type data to compare. This is is the expected value. + The second generic type data to compare. This is the actual value. + This breaks into the debugger in the case of a failed assertion. + + + + Verifies that two generic type data are not equal. The assertion fails if they are. + + The generic type to compare for inequality. + The first generic type data to compare. This is is the value that's not expected. + The second generic type data to compare. This is the actual value. + This breaks into the debugger in the case of a failed assertion. + + + + Verifies that if the specified condition is true, then so is the result. + The assertion fails if the condition is true but the result is false. + + if set to true [condition]. + + A second Boolean statement. If the first was true then so must this be. + If the first statement was false then the value of this is ignored. + + This breaks into the debugger in the case of a failed assertion. + + + + Lazy evaluation overload. Verifies that if a condition is true, then so is a secondary value. + + The conditional value. + A function to be evaluated for truth if the condition argument is true. + + This overload only evaluates the result if the first condition is true. + + + + + Verifies that a string has content. I.e. it is not null and it is not empty. + + The string to verify. + + + + Verifies that a string has content. I.e. it is not null and it is not purely whitespace. + + The string to verify. + + + + Verifies the specified value is not null. The assertion fails if it is. + + The generic reference type. + The value to check for nullness. + This breaks into the debugger in the case of a failed assertion. + + + + Verifies that the specified condition is false. The assertion fails if it is true. + + The expression that should be false. + This breaks into the debugger in the case of a failed assertion. + + + + Verifies that the specified condition is false. The assertion fails if it is true. + + The expression that should be false. + The message to display if the condition is true. + This breaks into the debugger in the case of a failed assertion. + + + + Verifies that the specified condition is true. The assertion fails if it is not. + + A condition that is expected to be true. + This breaks into the debugger in the case of a failed assertion. + + + + Verifies that the specified condition is true. The assertion fails if it is not. + + A condition that is expected to be true. + The message to write in case the condition is false. + This breaks into the debugger in the case of a failed assertion. + + + + This line should never be executed. The assertion always fails. + + This breaks into the debugger in the case of a failed assertion. + + + + This line should never be executed. The assertion always fails. + + The message to display if this function is executed. + This breaks into the debugger in the case of a failed assertion. + + + + Verifies that the specified object is null. The assertion fails if it is not. + + The item to verify is null. + + + + Verifies that the specified value is within the expected range. The assertion fails if it isn't. + + The lower bound inclusive value. + The value to verify. + The upper bound inclusive value. + + + + Verifies that the specified value is within the expected range. The assertion fails if it isn't. + + The lower bound inclusive value. + The value to verify. + The upper bound exclusive value. + + + + Verify the current thread's apartment state is what's expected. The assertion fails if it isn't + + + The expected apartment state for the current thread. + + This breaks into the debugger in the case of a failed assertion. + + + + DoubleUtil uses fixed eps to provide fuzzy comparison functionality for doubles. + Note that FP noise is a big problem and using any of these compare + methods is not a complete solution, but rather the way to reduce + the probability of repeating unnecessary work. + + + + + Epsilon - more or less random, more or less small number. + + + + + AreClose returns whether or not two doubles are "close". That is, whether or + not they are within epsilon of each other. + There are plenty of ways for this to return false even for numbers which + are theoretically identical, so no code calling this should fail to work if this + returns false. + + The first double to compare. + The second double to compare. + The result of the AreClose comparision. + + + + LessThan returns whether or not the first double is less than the second double. + That is, whether or not the first is strictly less than *and* not within epsilon of + the other number. + There are plenty of ways for this to return false even for numbers which + are theoretically identical, so no code calling this should fail to work if this + returns false. + + The first double to compare. + The second double to compare. + The result of the LessThan comparision. + + + + GreaterThan returns whether or not the first double is greater than the second double. + That is, whether or not the first is strictly greater than *and* not within epsilon of + the other number. + There are plenty of ways for this to return false even for numbers which + are theoretically identical, so no code calling this should fail to work if this + returns false. + + The first double to compare. + The second double to compare. + The result of the GreaterThan comparision. + + + + LessThanOrClose returns whether or not the first double is less than or close to + the second double. That is, whether or not the first is strictly less than or within + epsilon of the other number. + There are plenty of ways for this to return false even for numbers which + are theoretically identical, so no code calling this should fail to work if this + returns false. + + The first double to compare. + The second double to compare. + The result of the LessThanOrClose comparision. + + + + GreaterThanOrClose returns whether or not the first double is greater than or close to + the second double. That is, whether or not the first is strictly greater than or within + epsilon of the other number. + There are plenty of ways for this to return false even for numbers which + are theoretically identical, so no code calling this should fail to work if this + returns false. + + The first double to compare. + The second double to compare. + The result of the GreaterThanOrClose comparision. + + + + Test to see if a double is a finite number (is not NaN or Infinity). + + The value to test. + Whether or not the value is a finite number. + + + + Test to see if a double a valid size value (is finite and > 0). + + The value to test. + Whether or not the value is a valid size value. + + + + Convert a point in device independent pixels (1/96") to a point in the system coordinates. + + A point in the logical coordinate system. + Returns the parameter converted to the system's coordinates. + + + + Convert a point in system coordinates to a point in device independent pixels (1/96"). + + A point in the physical coordinate system. + Returns the parameter converted to the device independent coordinate system. + + + + Wrapper for common Win32 status codes. + + + + The operation completed successfully. + + + Incorrect function. + + + The system cannot find the file specified. + + + The system cannot find the path specified. + + + The system cannot open the file. + + + Access is denied. + + + The handle is invalid. + + + Not enough storage is available to complete this operation. + + + There are no more files. + + + The process cannot access the file because it is being used by another process. + + + The parameter is incorrect. + + + The data area passed to a system call is too small. + + + Cannot nest calls to LoadModule. + + + Illegal operation attempted on a registry key that has been marked for deletion. + + + Element not found. + + + There was no match for the specified key in the index. + + + An invalid device was specified. + + + The operation was canceled by the user. + + + Cannot find window class. + + + The window class was already registered. + + + The specified datatype is invalid. + + + + Create a new Win32 error. + + The integer value of the error. + + + Performs HRESULT_FROM_WIN32 conversion. + The Win32 error being converted to an HRESULT. + The equivilent HRESULT value. + + + Performs HRESULT_FROM_WIN32 conversion. + The equivilent HRESULT value. + + + Performs the equivalent of Win32's GetLastError() + A Win32Error instance with the result of the native GetLastError + + + + Compare two Win32 error codes for equality. + + The first error code to compare. + The second error code to compare. + Whether the two error codes are the same. + + + + Compare two Win32 error codes for inequality. + + The first error code to compare. + The second error code to compare. + Whether the two error codes are not the same. + + + FACILITY_NULL + + + FACILITY_RPC + + + FACILITY_DISPATCH + + + FACILITY_STORAGE + + + FACILITY_ITF + + + FACILITY_WIN32 + + + FACILITY_WINDOWS + + + FACILITY_CONTROL + + + MSDN doced facility code for ESE errors. + + + FACILITY_WINCODEC (WIC) + + + Wrapper for HRESULT status codes. + + + S_OK + + + S_FALSE + + + E_PENDING + + + E_NOTIMPL + + + E_NOINTERFACE + + + E_POINTER + + + E_ABORT + + + E_FAIL + + + E_UNEXPECTED + + + STG_E_INVALIDFUNCTION + + + REGDB_E_CLASSNOTREG + + + DESTS_E_NO_MATCHING_ASSOC_HANDLER. Win7 internal error code for Jump Lists. + There is no Assoc Handler for the given item registered by the specified application. + + + DESTS_E_NORECDOCS. Win7 internal error code for Jump Lists. + The given item is excluded from the recent docs folder by the NoRecDocs bit on its registration. + + + DESTS_E_NOTALLCLEARED. Win7 internal error code for Jump Lists. + Not all of the items were successfully cleared + + + E_ACCESSDENIED + Win32Error ERROR_ACCESS_DENIED. + + + E_OUTOFMEMORY + Win32Error ERROR_OUTOFMEMORY. + + + E_INVALIDARG + Win32Error ERROR_INVALID_PARAMETER. + + + INTSAFE_E_ARITHMETIC_OVERFLOW + + + COR_E_OBJECTDISPOSED + + + WC_E_GREATERTHAN + + + WC_E_SYNTAX + + + + Create an HRESULT from an integer value. + + + + + + Convert an HRESULT to an int. Used for COM interface declarations out of our control. + + + + + retrieve HRESULT_FACILITY + + + + + retrieve HRESULT_CODE + + + + + Get a string representation of this HRESULT. + + + + + + Convert the result of Win32 GetLastError() into a raised exception. + + + + + Gets the monitor information from the current cursor position. + + The monitor information. + + + + Gets the monitor information from the current cursor position. + + True when getting the monitor information was successful. + + + + HIGHCONTRAST flags + + + + + DROPIMAGE_* + + + + + BITMAPINFOHEADER Compression type. BI_*. + + + + + CombingRgn flags. RGN_* + + + + + Creates the intersection of the two combined regions. + + + + + Creates the union of two combined regions. + + + + + Creates the union of two combined regions except for any overlapping areas. + + + + + Combines the parts of hrgnSrc1 that are not part of hrgnSrc2. + + + + + Creates a copy of the region identified by hrgnSrc1. + + + + + For IWebBrowser2. OLECMDEXECOPT_* + + + + + For IWebBrowser2. OLECMDF_* + + + + + For IWebBrowser2. OLECMDID_* + + + + + For IWebBrowser2. READYSTATE_* + + + + + DATAOBJ_GET_ITEM_FLAGS. DOGIF_*. + + + + Use the system default, which is to display all error dialog boxes. + + + + The system does not display the critical-error-handler message box. + Instead, the system sends the error to the calling process. + + + + + 64-bit Windows: The system automatically fixes memory alignment faults and makes them + invisible to the application. It does this for the calling process and any descendant processes. + After this value is set for a process, subsequent attempts to clear the value are ignored. + + + + + The system does not display the general-protection-fault message box. + This flag should only be set by debugging applications that handle general + protection (GP) faults themselves with an exception handler. + + + + + The system does not display a message box when it fails to find a file. + Instead, the error is returned to the calling process. + + + + + Non-client hit test values, HT* + + + + + GetClassLongPtr values, GCLP_* + + + + + https://docs.microsoft.com/en-us/windows/desktop/api/winuser/nf-winuser-getwindow + + + + + GetWindowLongPtr values, GWL_* + + + + + SystemMetrics. SM_* + + + + + SystemParameterInfo values, SPI_* + + + + + SystemParameterInfo flag values, SPIF_* + + + + + CS_* + + + + + WindowStyle values, WS_* + + + + + Window message values, WM_* + + + + + Window style extended values, WS_EX_* + + + + + GetDeviceCaps nIndex values. + + + + Number of bits per pixel + + + + + Number of planes + + + + + Logical pixels inch in X + + + + + Logical pixels inch in Y + + + + + "FILEOP_FLAGS", FOF_*. + + + + + EnableMenuItem uEnable values, MF_* + + + + + Possible return value for EnableMenuItem + + + + Specifies the type of visual style attribute to set on a window. + + + Non-client area window attributes will be set. + + + + DWMFLIP3DWINDOWPOLICY. DWMFLIP3D_* + + + + + DWMNCRENDERINGPOLICY. DWMNCRP_* + + + + + DWMWINDOWATTRIBUTE. DWMWA_* + + + + + WindowThemeNonClientAttributes + + + + Prevents the window caption from being drawn. + + + Prevents the system icon from being drawn. + + + Prevents the system icon menu from appearing. + + + Prevents mirroring of the question mark, even in right-to-left (RTL) layout. + + + A mask that contains all the valid bits. + + + + SetWindowPos options + + + + + If the calling thread and the thread that owns the window are attached to different input queues, the system posts the request to the thread that owns the window. This prevents the calling thread from blocking its execution while other threads process the request. + + + + + Prevents generation of the WM_SYNCPAINT message. + + + + + Draws a frame (defined in the window's class description) around the window. + + + + + Applies new frame styles set using the SetWindowLong function. Sends a WM_NCCALCSIZE message to the window, even if the window's size is not being changed. If this flag is not specified, WM_NCCALCSIZE is sent only when the window's size is being changed. + + + + + Hides the window. + + + + + Does not activate the window. If this flag is not set, the window is activated and moved to the top of either the topmost or non-topmost group (depending on the setting of the hWndInsertAfter parameter). + + + + + Discards the entire contents of the client area. If this flag is not specified, the valid contents of the client area are saved and copied back into the client area after the window is sized or repositioned. + + + + + Retains the current position (ignores X and Y parameters). + + + + + Does not change the owner window's position in the Z order. + + + + + Does not redraw changes. If this flag is set, no repainting of any kind occurs. This applies to the client area, the nonclient area (including the title bar and scroll bars), and any part of the parent window uncovered as a result of the window being moved. When this flag is set, the application must explicitly invalidate or redraw any parts of the window and parent window that need redrawing. + + + + + Same as the SWP_NOOWNERZORDER flag. + + + + + Prevents the window from receiving the WM_WINDOWPOSCHANGING message. + + + + + Retains the current size (ignores the cx and cy parameters). + + + + + Retains the current Z order (ignores the hWndInsertAfter parameter). + + + + + Displays the window. + + + + + ShowWindow options + + + + + SCF_ISSECURE + + + + + GDI+ Status codes + + + + + MSGFLT_*. New in Vista. Realiased in Windows 7. + + + + + Shell_NotifyIcon messages. NIM_* + + + + + SHAddToRecentDocuments flags. SHARD_* + + + + + Shell_NotifyIcon flags. NIF_* + + + + + Vista only. + + + + + Vista only. + + + + + Shell_NotifyIcon info flags. NIIF_* + + + + XP SP2 and later. + + + XP and later. + + + Vista and later. + + + Windows 7 and later + + + XP and later. Native version called NIIF_ICON_MASK. + + + + AC_* + + + + + The state of the icon. There are two flags that can be set independently. + NIS_HIDDEN = 1. The icon is hidden. + NIS_SHAREDICON = 2. The icon is shared. + + + + The idlist for the shell item that should be added to the recent docs folder. + + + The id of the application that should be associated with this recent doc. + + + Defines options that are used to set window visual style attributes. + + + + A combination of flags that modify window visual style attributes. + Can be a combination of the WTNCA constants. + + + + + A bitmask that describes how the values specified in dwFlags should be applied. + If the bit corresponding to a value in dwFlags is 0, that flag will be removed. + If the bit is 1, the flag will be added. + + + + Width of left border that retains its size. + + + Width of right border that retains its size. + + + Height of top border that retains its size. + + + Height of bottom border that retains its size. + + + + + + + initialize this field using: Marshal.SizeOf(typeof(APPBARDATA)); + + + + Delegate declaration that matches native WndProc signatures. + + + Delegate declaration that matches managed WndProc signatures. + + + + Try to get the relative mouse position to the given handle in client coordinates. + + The handle for this method. + The relative mouse position to the given handle. + + + + https://docs.microsoft.com/en-us/windows/desktop/api/winuser/nf-winuser-getwindow + + + + + Sets attributes to control how visual styles are applied to a specified window. + + + Handle to a window to apply changes to. + + + Value of type WINDOWTHEMEATTRIBUTETYPE that specifies the type of attribute to set. + The value of this parameter determines the type of data that should be passed in the pvAttribute parameter. + Can be the following value: + WTA_NONCLIENT (Specifies non-client related attributes). + pvAttribute must be a pointer of type WTA_OPTIONS. + + + A pointer that specifies attributes to set. Type is determined by the value of the eAttribute value. + + + Specifies the size, in bytes, of the data pointed to by pvAttribute. + + + + + Retrieves the show state and the restored, minimized, and maximized positions of the specified window. + + A handle to the window. + A pointer to the WINDOWPLACEMENT structure that receives the show state and position information. + + Before calling GetWindowPlacement, set the length member to sizeof(WINDOWPLACEMENT). + GetWindowPlacement fails if lpwndpl-> length is not set correctly. + + If the function succeeds, the return value is nonzero. If the function fails, the return value is zero. + + + + Sets the show state and the restored, minimized, and maximized positions of the specified window. + + A handle to the window. + A pointer to a WINDOWPLACEMENT structure that specifies the new show state and window positions. + + Before calling SetWindowPlacement, set the length member of the WINDOWPLACEMENT structure to sizeof(WINDOWPLACEMENT). + SetWindowPlacement fails if the length member is not set correctly. + + If the function succeeds, the return value is nonzero. If the function fails, the return value is zero. + + + + Retrieves the length, in characters, of the specified window's title bar text (if the window has a title bar). + If the specified window is a control, the function retrieves the length of the text within the control. However, + GetWindowTextLength cannot retrieve the length of the text of an edit control in another application. + + A handle to the window or control. + + If the function succeeds, the return value is the length, in characters, of the text. Under certain + conditions, this value may actually be greater than the length of the text. For more information, see the following + Remarks section. + If the window has no text, the return value is zero. To get extended error information, call GetLastError. + + + + + Copies the text of the specified window's title bar (if it has one) into a buffer. If the specified window is + a control, the text of the control is copied. However, GetWindowText cannot retrieve the text of a control in another + application. + + A handle to the window or control containing the text. + + The buffer that will receive the text. If the string is as long or longer than the buffer, the + string is truncated and terminated with a null character. + + + The maximum number of characters to copy to the buffer, including the null character. If the + text exceeds this limit, it is truncated. + + + If the function succeeds, the return value is the length, in characters, of the copied string, not including + the terminating null character. If the window has no title bar or text, if the title bar is empty, or if the window or + control handle is invalid, the return value is zero. To get extended error information, call GetLastError. + This function cannot retrieve the text of an edit control in another application. + + + + + The MonitorFromRect function retrieves a handle to the display monitor that + has the largest area of intersection with a specified rectangle. + + Pointer to a RECT structure that specifies the rectangle of interest in + virtual-screen coordinates + Determines the function's return value if the rectangle does not intersect + any display monitor + + If the rectangle intersects one or more display monitor rectangles, the return value + is an HMONITOR handle to the display monitor that has the largest area of intersection with the rectangle. + If the rectangle does not intersect a display monitor, the return value depends on the value of dwFlags. + + + + + Loads an icon, cursor, animated cursor, or bitmap. + + Handle to the module of either a DLL or executable (.exe) that contains the image to be loaded + Specifies the image to load + Specifies the type of image to be loaded. + Specifies the width, in pixels, of the icon or cursor + Specifies the height, in pixels, of the icon or cursor + This parameter can be one or more of the following values. + If the function succeeds, the return value is the requested value.If the function fails, the return value is zero. To get extended error information, call GetLastError. + + + + Stop flashing. The system restores the window to its original state. + + + + + Flash the window caption + + + + + Flash the taskbar button. + + + + + Flash both the window caption and taskbar button. + This is equivalent to setting the FLASHW_CAPTION | FLASHW_TRAY flags. + + + + + Flash continuously, until the FLASHW_STOP flag is set. + + + + + Flash continuously until the window comes to the foreground. + + + + Overload of SystemParametersInfo for getting and setting NONCLIENTMETRICS. + + + Overload of SystemParametersInfo for getting and setting HIGHCONTRAST. + + + + Wraps an IStream interface pointer from COM into a form consumable by .Net. + + + This implementation is immutable, though it's possible that the underlying + stream can be changed in another context. + + + + + Wraps a native IStream interface into a CLR Stream subclass. + + + The stream that this object wraps. + + + Note that the parameter is passed by ref. On successful creation it is + zeroed out to the caller. This object becomes responsible for the lifetime + management of the wrapped IStream. + + + + + Wraps a managed stream instance into an interface pointer consumable by COM. + + + + + Initializes a new instance of the ManagedIStream class with the specified managed Stream object. + + + The stream that this IStream reference is wrapping. + + + + + Creates a new stream object with its own seek pointer that + references the same bytes as the original stream. + + + When this method returns, contains the new stream object. This parameter is passed uninitialized. + + + For more information, see the existing documentation for IStream::Clone in the MSDN library. + This class doesn't implement Clone. A COMException is thrown if it is used. + + + + + Ensures that any changes made to a stream object that is open in transacted + mode are reflected in the parent storage. + + + A value that controls how the changes for the stream object are committed. + + + For more information, see the existing documentation for IStream::Commit in the MSDN library. + + + + + Copies a specified number of bytes from the current seek pointer in the + stream to the current seek pointer in another stream. + + + A reference to the destination stream. + + + The number of bytes to copy from the source stream. + + + On successful return, contains the actual number of bytes read from the source. + (Note the native signature is to a ULARGE_INTEGER*, so 64 bits are written + to this parameter on success.) + + + On successful return, contains the actual number of bytes written to the destination. + (Note the native signature is to a ULARGE_INTEGER*, so 64 bits are written + to this parameter on success.) + + + + + Restricts access to a specified range of bytes in the stream. + + + The byte offset for the beginning of the range. + + + The length of the range, in bytes, to restrict. + + + The requested restrictions on accessing the range. + + + For more information, see the existing documentation for IStream::LockRegion in the MSDN library. + This class doesn't implement LockRegion. A COMException is thrown if it is used. + + + + + Reads a specified number of bytes from the stream object into memory starting at the current seek pointer. + + + When this method returns, contains the data read from the stream. This parameter is passed uninitialized. + + + The number of bytes to read from the stream object. + + + A pointer to a ULONG variable that receives the actual number of bytes read from the stream object. + + + For more information, see the existing documentation for ISequentialStream::Read in the MSDN library. + + + + + Discards all changes that have been made to a transacted stream since the last Commit call. + + + This class doesn't implement Revert. A COMException is thrown if it is used. + + + + + Changes the seek pointer to a new location relative to the beginning of the + stream, to the end of the stream, or to the current seek pointer. + + + The displacement to add to dwOrigin. + + + The origin of the seek. The origin can be the beginning of the file, the current seek pointer, or the end of the file. + + + On successful return, contains the offset of the seek pointer from the beginning of the stream. + (Note the native signature is to a ULARGE_INTEGER*, so 64 bits are written + to this parameter on success.) + + + For more information, see the existing documentation for IStream::Seek in the MSDN library. + + + + + Changes the size of the stream object. + + + The new size of the stream as a number of bytes. + + + For more information, see the existing documentation for IStream::SetSize in the MSDN library. + + + + + Retrieves the STATSTG structure for this stream. + + + When this method returns, contains a STATSTG structure that describes this stream object. + This parameter is passed uninitialized. + + + Members in the STATSTG structure that this method does not return, thus saving some memory allocation operations. + + + + + Removes the access restriction on a range of bytes previously restricted with the LockRegion method. + + The byte offset for the beginning of the range. + + + The length, in bytes, of the range to restrict. + + + The access restrictions previously placed on the range. + + + For more information, see the existing documentation for IStream::UnlockRegion in the MSDN library. + This class doesn't implement UnlockRegion. A COMException is thrown if it is used. + + + + + Writes a specified number of bytes into the stream object starting at the current seek pointer. + + + The buffer to write this stream to. + + + The number of bytes to write to the stream. + + + On successful return, contains the actual number of bytes written to the stream object. + If the caller sets this pointer to null, this method does not provide the actual number + of bytes written. + + + + + Releases resources controlled by this object. + + + Dispose can be called multiple times, but trying to use the object + after it has been disposed will generally throw ObjectDisposedExceptions. + + + + + Wrapper around File.Copy to provide feedback as to whether the file wasn't copied because it didn't exist. + + + + + + Simple guard against the exceptions that File.Delete throws on null and empty strings. + + The path to delete. Unlike File.Delete, this can be null or empty. + + Note that File.Delete, and by extension SafeDeleteFile, does not throw an exception + if the file does not exist. + + + + + Utility to help classes catenate their properties for implementing ToString(). + + The StringBuilder to catenate the results into. + The name of the property to be catenated. + The value of the property to be catenated. + + + + Generates ToString functionality for a struct. This is an expensive way to do it, + it exists for the sake of debugging while classes are in flux. + Eventually this should just be removed and the classes should + do this without reflection. + + + + + + + + Encodes a URL string. Duplicated functionality from System.Web.HttpUtility.UrlEncode. + + + + + Duplicated from System.Web.HttpUtility because System.Web isn't part of the client profile. + URL Encoding replaces ' ' with '+' and unsafe ASCII characters with '%XX'. + Safe characters are defined in RFC2396 (http://www.ietf.org/rfc/rfc2396.txt). + They are the 7-bit ASCII alphanumerics and the mark characters "-_.!~*'()". + This implementation does not treat '~' as a safe character to be consistent with the System.Web version. + + + + GDI's DeleteObject + + + GDI+'s DisposeImage + + + + From a list of BitmapFrames find the one that best matches the requested dimensions. + The methods used here are copied from Win32 sources. We want to be consistent with + system behaviors. + + + Convert a native integer that represent a color with an alpha channel into a Color struct. + The integer that represents the color. Its bits are of the format 0xAARRGGBB. + A Color representation of the parameter. + + + + A static class for retail validated assertions. + Instead of breaking into the debugger an exception is thrown. + + + + + Ensure that the current thread's apartment state is what's expected. + + + The required apartment state for the current thread. + + + The message string for the exception to be thrown if the state is invalid. + + + Thrown if the calling thread's apartment state is not the same as the requiredState. + + + + + Ensure that an argument is neither null nor empty. + + The string to validate. + The name of the parameter that will be presented if an exception is thrown. + + + + Ensure that an argument is neither null nor does it consist only of whitespace. + + The string to validate. + The name of the parameter that will be presented if an exception is thrown. + + + Verifies that an argument is not null. + Type of the object to validate. Must be a class. + The object to validate. + The name of the parameter that will be presented if an exception is thrown. + + + Verifies that an argument is not null. + Type of the object to validate. Must be a class. + The object to validate. + The name of the parameter that will be presented if an exception is thrown. + + + Verifies that an argument is null. + Type of the object to validate. Must be a class. + The object to validate. + The name of the parameter that will be presented if an exception is thrown. + + + + Verifies the specified statement is true. Throws an ArgumentException if it's not. + + The statement to be verified as true. + Name of the parameter to include in the ArgumentException. + The message to include in the ArgumentException. + + + + Verifies that the specified value is within the expected range. The assertion fails if it isn't. + + The lower bound inclusive value. + The value to verify. + The upper bound exclusive value. + The name of the parameter that caused the current exception. + + + + Shows the system menu at the current mouse position. + + The window for which the system menu should be shown. + The mouse event args. + + + Display the system menu at a specified location. + The visual for which the system menu should be displayed. + The location to display the system menu, in logical screen coordinates. + + + Display the system menu at a specified location. + The visual for which the system menu should be displayed. + The location to display the system menu, in physical screen coordinates. + + The dpi of is NOT used to calculate the final coordinates. + So you have to pass the final coordinates. + + + + Display the system menu at a specified location. + The source/hwnd for which the system menu should be displayed. + The location to display the system menu, in physical screen coordinates. + + The dpi of is NOT used to calculate the final coordinates. + So you have to pass the final coordinates. + + + + + Private constructor. The public way to access this class is through the static Current property. + + + + + Critical as this accesses Native methods. + TreatAsSafe - it would be ok to expose this information - DPI in partial trust + + + + + Invalidates the rectangle or region that you specify in lprcUpdate or hrgnUpdate. + You can set only one of these parameters to a non-NULL value. If both are NULL, RDW_INVALIDATE invalidates the entire window. + + + + Causes the OS to post a WM_PAINT message to the window regardless of whether a portion of the window is invalid. + + + + Causes the window to receive a WM_ERASEBKGND message when the window is repainted. + Specify this value in combination with the RDW_INVALIDATE value; otherwise, RDW_ERASE has no effect. + + + + + Validates the rectangle or region that you specify in lprcUpdate or hrgnUpdate. + You can set only one of these parameters to a non-NULL value. If both are NULL, RDW_VALIDATE validates the entire window. + This value does not affect internal WM_PAINT messages. + + + + Suppresses any pending WM_ERASEBKGND messages. + + + Excludes child windows, if any, from the repainting operation. + + + Includes child windows, if any, in the repainting operation. + + + Causes the affected windows, which you specify by setting the RDW_ALLCHILDREN and RDW_NOCHILDREN values, to receive WM_ERASEBKGND and WM_PAINT messages before the RedrawWindow returns, if necessary. + + + + Causes the affected windows, which you specify by setting the RDW_ALLCHILDREN and RDW_NOCHILDREN values, to receive WM_ERASEBKGND messages before RedrawWindow returns, if necessary. + The affected windows receive WM_PAINT messages at the ordinary time. + + + + + Causes the dialog box to display all available colors in the set of basic colors. + + + + http://msdn.microsoft.com/en-us/library/ms182161.aspx + + + http://msdn.microsoft.com/en-us/library/dd145064%28v=VS.85%29.aspx + + + http://msdn.microsoft.com/en-us/library/windows/desktop/ms647486%28v=vs.85%29.aspx + + + http://msdn.microsoft.com/en-us/library/windows/desktop/ms633528(v=vs.85).aspx + + + http://msdn.microsoft.com/en-us/library/windows/desktop/ms684175%28v=vs.85%29.aspx + + + http://msdn.microsoft.com/en-us/library/windows/desktop/ms683152%28v=vs.85%29.aspx + + + + Base class for creating an icon control for icon packs. + + + + + + Inheritors should provide a factory for setting up the path data index (per icon kind). + The factory will only be utilized once, across all closed instances (first instantiation wins). + + + + Identifies the dependency property. + + + + Gets or sets the icon to display. + + + + Identifies the dependency property. + + + + Gets the icon path data for the current . + + + + + This custom popup can be used by validation error templates or something else. + It provides some additional nice features: + - repositioning if host-window size or location changed + - repositioning if host-window gets maximized and vice versa + - it's only topmost if the host-window is activated + + + + Identifies the dependency property. + + + + Gets or sets if the popup can be closed by left mouse button down. + + + + Identifies the dependency property. + + + + Gets or sets whether if the Popup should be always on top. + + + + + Causes the popup to update it's position according to it's current settings. + + + + + SetWindowPos options + + + + + AddValueChanged of dependency property descriptor results in memory leak as you already know. + So, as described here, you can create custom class PropertyChangeNotifier to listen + to any dependency property changes. + + This class takes advantage of the fact that bindings use weak references to manage associations + so the class will not root the object who property changes it is watching. It also uses a WeakReference + to maintain a reference to the object whose property it is watching without rooting that object. + In this way, you can maintain a collection of these objects so that you can unhook the property + change later without worrying about that collection rooting the object whose values you are watching. + + Complete implementation can be found here: http://agsmith.wordpress.com/2008/04/07/propertydescriptor-addvaluechanged-alternative/ + + + + Identifies the dependency property. + + + + Gets or sets the value of the watched property. + + + + + + This struct represent a Color in HSL (Hue, Saturation, Luminance) + + Idea taken from here http://ciintelligence.blogspot.com/2012/02/converting-excel-theme-color-and-tint.html + and here: https://en.wikipedia.org/wiki/HSL_and_HSV + + + + + Creates a new HSL Color + + Any System.Windows.Media.Color + + + + Creates a new HSL Color + + Alpha Channel [0;1] + Hue Channel [0;360] + Saturation Channel [0;1] + Luminance Channel [0;1] + + + + Gets or sets the Alpha channel. + + + + + Gets or sets the Hue channel. + + + + + Gets or sets the Saturation channel. + + + + + Gets or sets the Luminance channel. + + + + + Gets the ARGB-Color for this HSL-Color + + System.Windows.Media.Color + + + + Gets a lighter / darker color based on a tint value. If is > 0 then the returned color is darker, otherwise it will be lighter. + + Tint Value in the Range [-1;1]. + a new which is lighter or darker. + + + + Gets a lighter / darker color based on a tint value. If is > 0 then the returned color is darker, otherwise it will be lighter. + + The input color which should be tinted. + Tint Value in the Range [-1;1]. + a new which is lighter or darker. + + + + Represents a theme. + + + + + Gets the key for the library theme instance. + + + + + Gets the key for the theme color scheme. + + + + + Gets the key for the color values being used to generate a runtime theme. + + + + + Initializes a new instance. + + The URI of the theme ResourceDictionary. + The which created this instance. + + + + Initializes a new instance. + + The ResourceDictionary of the theme. + The which created this instance. + + + + + + + + + + + + + Get the origin of the theme. + + + + + + + + + + + + + + + + + + + + The root containing all resource dictionaries belonging to this instance as + + + + + Gets the alternative color scheme for this theme. + + + + + Determining Ideal Text Color Based on Specified Background Color + http://www.codeproject.com/KB/GDI-plus/IdealTextColor.aspx + + The background color. + + + + + Global options for . + + + + + Used to create the options being used to generate a single . + + + + + Options being used to generate one single . + + + + + Represents a theme. + + + + + Gets the key for the themes name. + + + + + Gets the key for the themes origin. + + + + + Gets the key for the themes display name. + + + + + Gets the key for the themes base color scheme. + + + + + Gets the key for the themes color scheme. + + + + + Gets the key for the themes primary accent color. + + + + + Gets the key for the themes showcase brush. + + + + + Gets the key for the themes runtime generation flag. + + + + + Gets the key for the themes high contrast flag. + + + + + Gets the key for the theme instance. + + + + + Initializes a new instance. + + The first of the theme. + + + + Gets whether this theme was generated at runtime. + + + + + Gets whether this theme is for high contrast mode. + + + + + Gets the name of the theme. + + + + + Gets the display name of the theme. + + + + + Get the base color scheme for this theme. + + + + + Gets the primary accent color for this theme. + + + + + Gets the color scheme for this theme. + + + + + Gets a brush which can be used to showcase this theme. + + + + + The root containing all resource dictionaries of all belonging to this instance as + + + + + The ResourceDictionaries that represent this theme. + + + + + The ResourceDictionaries that represent this theme. + + + + + Ensures that all from provided a for this . + + This instance for fluent call usage. + + + + Gets a flat list of all from all library themes. + + A flat list of all from all library themes. + + + + Adds a new to this . + + The to add. + This instance for fluent call usage. + + + + + + + Class which is used as argument for an event to signal theme changes. + + + + + Creates a new instance of this class. + + + + + The target object for which was targeted by the theme change. + + + + + The for which was targeted by the theme change. + + + + + The old theme. + + + + + The new theme. + + + + + A class that allows for the detection and alteration of a theme. + + + + + Gets the name for the light base color. + + + + + Gets the name for the light base color. + + + + + Gets the name for the dark base color. + + + + + Gets the name for the dark base color. + + + + + Gets a list of all library theme providers. + + + + + Gets a list of all themes. + + + + + Gets a list of all available base colors. + + + + + Gets a list of all available color schemes. + + + + + Clears the internal themes list. + + + + + Gets the with the given name. + + The or null, if the theme wasn't found + + + + Gets the with the given name. + + The or null, if the theme wasn't found + + + + Gets the with the given resource dictionary. + + from which the theme should be retrieved. + The or null, if the theme wasn't found. + + + + Gets the inverse of the given . + This method relies on the "Dark" or "Light" affix to be present. + + The app theme. + The inverse or null if it couldn't be found. + + Returns BaseLight, if BaseDark is given or vice versa. + Custom Themes must end with "Dark" or "Light" for this to work, for example "CustomDark" and "CustomLight". + + + + + Determines whether the specified resource dictionary represents a . + + This might include runtime themes which do not have a resource uri. + + The resources. + true if the resource dictionary is an ; otherwise, false. + resources + + + + Determines whether the specified resource dictionary represents a and was generated at runtime. + + This might include runtime themes which do not have a resource uri. + + The resources. + true if the resource dictionary is an ; otherwise, false. + resources + + + + Change the theme for the whole application. + + + + + Change theme for the given window. + + + + + Change theme for the whole application. + + The instance of Application to change. + The theme to apply. + + + + Change theme for the given ResourceDictionary. + + The FrameworkElement to change. + The theme to apply. + + + + Change theme for the given ResourceDictionary. + + The target object for which the theme change should be made. This is optional an can be null. + The ResourceDictionary to change. + The theme to apply. + + + + Change base color and color scheme of for the given application. + + The application to modify. + The base color to apply to the ResourceDictionary. + The color scheme to apply to the ResourceDictionary. + + + + Change base color and color scheme of for the given window. + + The FrameworkElement to modify. + The base color to apply to the ResourceDictionary. + The color scheme to apply to the ResourceDictionary. + + + + Change base color and color scheme of for the given ResourceDictionary. + + The target object for which the theme change should be made. This is optional an can be null. + The ResourceDictionary to modify. + The old/current theme. + The base color to apply to the ResourceDictionary. + The color scheme to apply to the ResourceDictionary. + + + + Change base color for the given application. + + The application to change. + The base color to apply to the ResourceDictionary. + + + + Change base color for the given window. + + The FrameworkElement to change. + The base color to apply to the ResourceDictionary. + + + + Change base color of for the given ResourceDictionary. + + The target object for which the theme change should be made. This is optional an can be null. + The ResourceDictionary to modify. + The old/current theme. + The base color to apply to the ResourceDictionary. + + + + Change color scheme for the given application. + + The application to change. + The color scheme to apply to the ResourceDictionary. + + + + Change color scheme for the given window. + + The FrameworkElement to change. + The color scheme to apply to the ResourceDictionary. + + + + Change color scheme for the given ResourceDictionary. + + The target object for which the theme change should be made. This is optional an can be null. + The ResourceDictionary to modify. + The old/current theme. + The color scheme to apply to the ResourceDictionary. + + + + Changes the theme of a ResourceDictionary directly. + + The ResourceDictionary to modify. + The theme to apply to the ResourceDictionary. + + + + Scans the resources and returns it's theme. + + If the theme can't be detected from the we try to detect it from . + + + + Scans the application resources and returns it's theme. + + The Application instance to scan. + + + + Scans the resources and returns it's theme. + + The FrameworkElement to scan. + If the theme can't be detected from the we try to detect it from . + + + + Scans a resources and returns it's theme. + + The ResourceDictionary to scan. + + + + This event fires if the theme was changed + this should be using the weak event pattern, but for now it's enough + + + + + Invalidates global colors and resources. + Sometimes the ContextMenu is not changing the colors, so this will fix it. + + + + + Gets or sets whether changes to the "app mode" setting from windows should be detected at runtime and the current be changed accordingly. + + + + + Gets or sets whether changes to the accent color settings from windows should be detected at runtime and the current be changed accordingly. + + + + + Gets or sets whether changes to the high contrast setting from windows should be detected at runtime and the current be changed accordingly. + + + + + Works around an issue in the XamlReader. + Without this fix the XamlReader would not be able to read the XAML we produced earlier because it does not know where to look for the types. + The real issue is that we can't use the full namespace, with assembly hint, at compile time of the original project because said assembly does not yet exist and would cause a compile time error. + Hence we have to use this workaround to enable both. + The issue + + The fixed version of . + + If you have the following in your XAML file: + xmlns:markup="clr-namespace:MahApps.Metro.Markup" + xmlns:markupWithAssembly="clr-namespace:MahApps.Metro.Markup;assembly=MahApps.Metro" + It get's converted to: + xmlns:markup="clr-namespace:MahApps.Metro.Markup;assembly=MahApps.Metro" + xmlns:markupWithAssembly="clr-namespace:MahApps.Metro.Markup;assembly=MahApps.Metro" + + + + + Indicates whether a tooltip should follow the mouse cursor. + + + + + Sets whether a tooltip should follow the mouse cursor. + + + + + Gets the horizontal offset for the relative placement of the Tooltip. + + + + + Sets the horizontal offset for the relative placement of the Tooltip. + + + + + Gets the vertical offset for the relative placement of the Tooltip. + + + + + Sets the vertical offset for the relative placement of the Tooltip. + + + + diff --git a/dev/libs/netcore/Lokad.ILPack.dll b/dev/libs/netcore/Lokad.ILPack.dll new file mode 100644 index 000000000..dcb26e8f8 Binary files /dev/null and b/dev/libs/netcore/Lokad.ILPack.dll differ diff --git a/dev/libs/netcore/Microsoft.Xaml.Behaviors.dll b/dev/libs/netcore/Microsoft.Xaml.Behaviors.dll new file mode 100644 index 000000000..1f4abee12 Binary files /dev/null and b/dev/libs/netcore/Microsoft.Xaml.Behaviors.dll differ diff --git a/dev/libs/PythonStubsBuilder.dll b/dev/libs/netcore/PythonStubsBuilder.dll similarity index 100% rename from dev/libs/PythonStubsBuilder.dll rename to dev/libs/netcore/PythonStubsBuilder.dll diff --git a/dev/libs/netcore/System.Text.Json.dll b/dev/libs/netcore/System.Text.Json.dll new file mode 100644 index 000000000..799c1efb2 Binary files /dev/null and b/dev/libs/netcore/System.Text.Json.dll differ diff --git a/dev/libs/netcore/de/pyRevitLabs.MahAppsMetro.resources.dll b/dev/libs/netcore/de/pyRevitLabs.MahAppsMetro.resources.dll new file mode 100644 index 000000000..cdf9643cd Binary files /dev/null and b/dev/libs/netcore/de/pyRevitLabs.MahAppsMetro.resources.dll differ diff --git a/dev/libs/netcore/pyRevitLabs.Json.dll b/dev/libs/netcore/pyRevitLabs.Json.dll new file mode 100644 index 000000000..c25fba9e0 Binary files /dev/null and b/dev/libs/netcore/pyRevitLabs.Json.dll differ diff --git a/dev/libs/netcore/pyRevitLabs.Json.xml b/dev/libs/netcore/pyRevitLabs.Json.xml new file mode 100644 index 000000000..038040fdb --- /dev/null +++ b/dev/libs/netcore/pyRevitLabs.Json.xml @@ -0,0 +1,11325 @@ + + + + Newtonsoft.Json + + + + + Represents a BSON Oid (object id). + + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Initializes a new instance of the class. + + The Oid value. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized BSON data. + + + + + Gets or sets a value indicating whether binary data reading should be compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The containing the BSON data to read. + + + + Initializes a new instance of the class. + + The containing the BSON data to read. + + + + Initializes a new instance of the class. + + The containing the BSON data to read. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The containing the BSON data to read. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the underlying . + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the reader's state to . + If is set to true, the underlying is also closed. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating BSON data. + + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Initializes a new instance of the class. + + The to write to. + + + + Initializes a new instance of the class. + + The to write to. + + + + Flushes whatever is in the buffer to the underlying and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a JSON array. + + + + + Writes the beginning of a JSON object. + + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Closes this writer. + If is set to true, the underlying is also closed. + If is set to true, the JSON is auto-completed. + + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to a single parameterized constructor, then to the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a parameterized constructor. + + + + + Converts a binary value to and from a base 64 string value. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Creates a custom object. + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a F# discriminated union type to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an Entity Framework to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Converts a to and from the ISO 8601 date format (e.g. "2008-04-12T12:53Z"). + + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Converts a to and from a JavaScript Date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + The default value is false. + + true if the written enum text will be camel case; otherwise, false. + + + + Gets or sets the naming strategy used to resolve how enum text is written. + + The naming strategy used to resolve how enum text is written. + + + + Gets or sets a value indicating whether integer values are allowed when serializing and deserializing. + The default value is true. + + true if integers are allowed when serializing and deserializing; otherwise, false. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + true if the written enum text will be camel case; otherwise, false. + + + + Initializes a new instance of the class. + + The naming strategy used to resolve how enum text is written. + true if integers are allowed when serializing and deserializing; otherwise, false. + + + + Initializes a new instance of the class. + + The of the used to write enum text. + + + + Initializes a new instance of the class. + + The of the used to write enum text. + + The parameter list to use when constructing the described by . + If null, the default constructor is used. + When non-null, there must be a constructor defined in the that exactly matches the number, + order, and type of these parameters. + + + + + Initializes a new instance of the class. + + The of the used to write enum text. + + The parameter list to use when constructing the described by . + If null, the default constructor is used. + When non-null, there must be a constructor defined in the that exactly matches the number, + order, and type of these parameters. + + true if integers are allowed when serializing and deserializing; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from Unix epoch time + + + + + Gets or sets a value indicating whether the dates before Unix epoch + should converted to and from JSON. + + + true to allow converting dates before Unix epoch to and from JSON; + false to throw an exception when a date being converted to or from JSON + occurred before Unix epoch. The default value is false. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + true to allow converting dates before Unix epoch to and from JSON; + false to throw an exception when a date being converted to or from JSON + occurred before Unix epoch. The default value is false. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts XML to and from JSON. + + + + + Gets or sets the name of the root element to insert when deserializing to XML if the JSON structure has produced multiple root elements. + + The name of the deserialized root element. + + + + Gets or sets a value to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + true if the array attribute is written to the XML; otherwise, false. + + + + Gets or sets a value indicating whether to write the root JSON object. + + true if the JSON root object is omitted; otherwise, false. + + + + Gets or sets a value indicating whether to encode special characters when converting JSON to XML. + If true, special characters like ':', '@', '?', '#' and '$' in JSON property names aren't used to specify + XML namespaces, attributes or processing directives. Instead special characters are encoded and written + as part of the XML element name. + + true if special characters are encoded; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The calling serializer. + The value. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Checks if the is a namespace attribute. + + Attribute name to test. + The attribute name prefix if it has one, otherwise an empty string. + true if attribute name is for a namespace attribute, otherwise false. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + The default JSON name table implementation. + + + + + Initializes a new instance of the class. + + + + + Gets a string containing the same characters as the specified range of characters in the given array. + + The character array containing the name to find. + The zero-based index into the array specifying the first character of the name. + The number of characters in the name. + A string containing the same characters as the specified range of characters in the given array. + + + + Adds the specified string into name table. + + The string to add. + This method is not thread-safe. + The resolved string. + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that it is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable types; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and set members to their default value when deserializing. + + + + + Specifies float format handling options when writing special floating point numbers, e.g. , + and with . + + + + + Write special floating point values as strings in JSON, e.g. "NaN", "Infinity", "-Infinity". + + + + + Write special floating point values as symbols in JSON, e.g. NaN, Infinity, -Infinity. + Note that this will produce non-valid JSON. + + + + + Write special floating point values as the property's default value in JSON, e.g. 0.0 for a property, null for a of property. + + + + + Specifies how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + + + + + Floating point numbers are parsed to . + + + + + Floating point numbers are parsed to . + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Provides an interface for using pooled arrays. + + The array type content. + + + + Rent an array from the pool. This array must be returned when it is no longer needed. + + The minimum required length of the array. The returned array may be longer. + The rented array from the pool. This array must be returned when it is no longer needed. + + + + Return an array to the pool. + + The array that is being returned. + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if and can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, when returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, when returns false). + + + + Instructs the how to serialize the collection. + + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items. + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Instructs the how to serialize the object. + + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets or sets the collection's items converter. + + The collection's items converter. + + + + The parameter list to use when constructing the described by . + If null, the default constructor is used. + When non-null, there must be a constructor defined in the that exactly matches the number, + order, and type of these parameters. + + + + [JsonContainer(ItemConverterType = typeof(MyContainerConverter), ItemConverterParameters = new object[] { 123, "Four" })] + + + + + + Gets or sets the of the . + + The of the . + + + + The parameter list to use when constructing the described by . + If null, the default constructor is used. + When non-null, there must be a constructor defined in the that exactly matches the number, + order, and type of these parameters. + + + + [JsonContainer(NamingStrategyType = typeof(MyNamingStrategy), NamingStrategyParameters = new object[] { 123, "Four" })] + + + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Provides methods for converting between .NET types and JSON types. + + + + + + + + Gets or sets a function that creates default . + Default settings are automatically used by serialization methods on , + and and on . + To serialize without using any default settings create a with + . + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + The string escape handling. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using formatting. + + The object to serialize. + Indicates how the output should be formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection of converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using formatting and a collection of . + + The object to serialize. + Indicates how the output should be formatted. + A collection of converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a type, formatting and . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be used. + + The type of the value being serialized. + This parameter is used when is to write out the type name if the type of the value does not match. + Specifying the type is optional. + + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using formatting and . + + The object to serialize. + Indicates how the output should be formatted. + The used to serialize the object. + If this is null, default serialization settings will be used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a type, formatting and . + + The object to serialize. + Indicates how the output should be formatted. + The used to serialize the object. + If this is null, default serialization settings will be used. + + The type of the value being serialized. + This parameter is used when is to write out the type name if the type of the value does not match. + Specifying the type is optional. + + + A JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the JSON string. + + + + Deserializes the JSON to a .NET object using . + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be inferred from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the given anonymous type using . + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be inferred from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type using a collection of . + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type using . + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type using a collection of . + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type using . + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + The deserialized object from the JSON string. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string using . + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be used. + + + + + Serializes the to a JSON string. + + The node to serialize. + A JSON string of the . + + + + Serializes the to a JSON string using formatting. + + The node to serialize. + Indicates how the output should be formatted. + A JSON string of the . + + + + Serializes the to a JSON string using formatting and omits the root object if is true. + + The node to serialize. + Indicates how the output should be formatted. + Omits writing the root object. + A JSON string of the . + + + + Deserializes the from a JSON string. + + The JSON string. + The deserialized . + + + + Deserializes the from a JSON string nested in a root element specified by . + + The JSON string. + The name of the root element to append when deserializing. + The deserialized . + + + + Deserializes the from a JSON string nested in a root element specified by + and writes a Json.NET array attribute for collections. + + The JSON string. + The name of the root element to append when deserializing. + + A value to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized . + + + + Deserializes the from a JSON string nested in a root element specified by , + writes a Json.NET array attribute for collections, and encodes special characters. + + The JSON string. + The name of the root element to append when deserializing. + + A value to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + + A value to indicate whether to encode special characters when converting JSON to XML. + If true, special characters like ':', '@', '?', '#' and '$' in JSON property names aren't used to specify + XML namespaces, attributes or processing directives. Instead special characters are encoded and written + as part of the XML element name. + + The deserialized . + + + + Serializes the to a JSON string. + + The node to convert to JSON. + A JSON string of the . + + + + Serializes the to a JSON string using formatting. + + The node to convert to JSON. + Indicates how the output should be formatted. + A JSON string of the . + + + + Serializes the to a JSON string using formatting and omits the root object if is true. + + The node to serialize. + Indicates how the output should be formatted. + Omits writing the root object. + A JSON string of the . + + + + Deserializes the from a JSON string. + + The JSON string. + The deserialized . + + + + Deserializes the from a JSON string nested in a root element specified by . + + The JSON string. + The name of the root element to append when deserializing. + The deserialized . + + + + Deserializes the from a JSON string nested in a root element specified by + and writes a Json.NET array attribute for collections. + + The JSON string. + The name of the root element to append when deserializing. + + A value to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized . + + + + Deserializes the from a JSON string nested in a root element specified by , + writes a Json.NET array attribute for collections, and encodes special characters. + + The JSON string. + The name of the root element to append when deserializing. + + A value to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + + A value to indicate whether to encode special characters when converting JSON to XML. + If true, special characters like ':', '@', '?', '#' and '$' in JSON property names aren't used to specify + XML namespaces, attributes or processing directives. Instead special characters are encoded and written + as part of the XML element name. + + The deserialized . + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Converts an object to and from JSON. + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. If there is no existing value then null will be used. + The existing value has a value. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Instructs the to use the specified when serializing the member or class. + + + + + Gets the of the . + + The of the . + + + + The parameter list to use when constructing the described by . + If null, the default constructor is used. + + + + + Initializes a new instance of the class. + + Type of the . + + + + Initializes a new instance of the class. + + Type of the . + Parameter list to use when constructing the . Can be null. + + + + Represents a collection of . + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during JSON serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or null if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Instructs the to deserialize properties with no matching class member into the specified collection + and write values during serialization. + + + + + Gets or sets a value that indicates whether to write extension data when serializing the object. + + + true to write extension data when serializing the object; otherwise, false. The default is true. + + + + + Gets or sets a value that indicates whether to read extension data when deserializing the object. + + + true to read extension data when deserializing the object; otherwise, false. The default is true. + + + + + Initializes a new instance of the class. + + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Base class for a table of atomized string objects. + + + + + Gets a string containing the same characters as the specified range of characters in the given array. + + The character array containing the name to find. + The zero-based index into the array specifying the first character of the name. + The number of characters in the name. + A string containing the same characters as the specified range of characters in the given array. + + + + Instructs the how to serialize the object. + + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets the missing member handling used when deserializing this object. + + The missing member handling. + + + + Gets or sets how the object's properties with null values are handled during serialization and deserialization. + + How the object's properties with null values are handled during serialization and deserialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Instructs the to always serialize the member with the specified name. + + + + + Gets or sets the type used when serializing the property's collection items. + + The collection's items type. + + + + The parameter list to use when constructing the described by . + If null, the default constructor is used. + When non-null, there must be a constructor defined in the that exactly matches the number, + order, and type of these parameters. + + + + [JsonProperty(ItemConverterType = typeof(MyContainerConverter), ItemConverterParameters = new object[] { 123, "Four" })] + + + + + + Gets or sets the of the . + + The of the . + + + + The parameter list to use when constructing the described by . + If null, the default constructor is used. + When non-null, there must be a constructor defined in the that exactly matches the number, + order, and type of these parameters. + + + + [JsonProperty(NamingStrategyType = typeof(MyNamingStrategy), NamingStrategyParameters = new object[] { 123, "Four" })] + + + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization of a member. + + The numeric order of serialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized JSON data. + + + + + Asynchronously reads the next JSON token from the source. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns true if the next token was read successfully; false if there are no more tokens to read. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously skips the children of the current token. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously reads the next JSON token from the source as a []. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the []. This result will be null at the end of an array. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously reads the next JSON token from the source as a . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the . This result will be null at the end of an array. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Specifies the state of the reader. + + + + + A read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader is in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the source should be closed when this reader is closed. + + + true to close the source when this reader is closed; otherwise false. The default is true. + + + + + Gets or sets a value indicating whether multiple pieces of JSON content can + be read from a continuous stream without erroring. + + + true to support reading multiple pieces of JSON content; otherwise false. + The default is false. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Gets or sets how time zones are handled when reading JSON. + + + + + Gets or sets how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + + + + + Gets or sets how custom date formatted strings are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + A null value means there is no maximum. + The default value is 64. + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets the .NET type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Initializes a new instance of the class. + + + + + Reads the next JSON token from the source. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the source as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the source as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the source as a []. + + A [] or null if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the source as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the source as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the source as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the source as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the source as a of . + + A of . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the current token and value. + + The new token. + The value. + A flag indicating whether the position index inside an array should be updated. + + + + Sets the state based on current token type. + + + + + Releases unmanaged and - optionally - managed resources. + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the reader's state to . + If is set to true, the source is also closed. + + + + + The exception thrown when an error occurs while reading JSON text. + + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or null if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Initializes a new instance of the class + with a specified error message, JSON path, line number, line position, and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The path to the JSON where the error occurred. + The line number indicating where the error occurred. + The line position indicating where the error occurred. + The exception that is the cause of the current exception, or null if no inner exception is specified. + + + + Instructs the to always serialize the member, and to require that the member has a value. + + + + + The exception thrown when an error occurs during JSON serialization or deserialization. + + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or null if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Initializes a new instance of the class + with a specified error message, JSON path, line number, line position, and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The path to the JSON where the error occurred. + The line number indicating where the error occurred. + The line position indicating where the error occurred. + The exception that is the cause of the current exception, or null if no inner exception is specified. + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the equality comparer used by the serializer when comparing references. + + The equality comparer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + The default value is . + + + should be used with caution when your application deserializes JSON from an external source. + Incoming types should be validated with a custom + when deserializing with a value other than . + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + The default value is . + + The type name assembly format. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + The default value is . + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + The default value is . + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + The default value is . + + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + The default value is . + + + + + Gets or sets how null values are handled during serialization and deserialization. + The default value is . + + + + + Gets or sets how default values are handled during serialization and deserialization. + The default value is . + + + + + Gets or sets how objects are created during deserialization. + The default value is . + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + The default value is . + + The constructor handling. + + + + Gets or sets how metadata properties are used during deserialization. + The default value is . + + The metadata properties handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + The default value is . + + + + + Gets or sets how dates are written to JSON text. + The default value is . + + + + + Gets or sets how time zones are handled during serialization and deserialization. + The default value is . + + + + + Gets or sets how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + The default value is . + + + + + Gets or sets how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + The default value is . + + + + + Gets or sets how special floating point numbers, e.g. , + and , + are written as JSON text. + The default value is . + + + + + Gets or sets how strings are escaped when writing JSON text. + The default value is . + + + + + Gets or sets how and values are formatted when writing JSON text, + and the expected date format when reading JSON text. + The default value is "yyyy'-'MM'-'dd'T'HH':'mm':'ss.FFFFFFFK". + + + + + Gets or sets the culture used when reading JSON. + The default value is . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + A null value means there is no maximum. + The default value is 64. + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + The default value is false. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance. + The will not use default settings + from . + + + A new instance. + The will not use default settings + from . + + + + + Creates a new instance using the specified . + The will not use default settings + from . + + The settings to be applied to the . + + A new instance using the specified . + The will not use default settings + from . + + + + + Creates a new instance. + The will use default settings + from . + + + A new instance. + The will use default settings + from . + + + + + Creates a new instance using the specified . + The will use default settings + from as well as the specified . + + The settings to be applied to the . + + A new instance using the specified . + The will use default settings + from as well as the specified . + + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to read values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to read values from. + The target object to populate values onto. + + + + Deserializes the JSON structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the JSON structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the JSON structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the JSON structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the JSON structure + using the specified . + + The used to write the JSON structure. + The to serialize. + + + + Serializes the specified and writes the JSON structure + using the specified . + + The used to write the JSON structure. + The to serialize. + + The type of the value being serialized. + This parameter is used when is to write out the type name if the type of the value does not match. + Specifying the type is optional. + + + + + Serializes the specified and writes the JSON structure + using the specified . + + The used to write the JSON structure. + The to serialize. + + The type of the value being serialized. + This parameter is used when is Auto to write out the type name if the type of the value does not match. + Specifying the type is optional. + + + + + Serializes the specified and writes the JSON structure + using the specified . + + The used to write the JSON structure. + The to serialize. + + + + Specifies the settings on a object. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) are handled. + The default value is . + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + The default value is . + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + The default value is . + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + The default value is . + + Null value handling. + + + + Gets or sets how default values are handled during serialization and deserialization. + The default value is . + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + The default value is . + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + The default value is . + + + should be used with caution when your application deserializes JSON from an external source. + Incoming types should be validated with a custom + when deserializing with a value other than . + + The type name handling. + + + + Gets or sets how metadata properties are used during deserialization. + The default value is . + + The metadata properties handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + The default value is . + + The type name assembly format. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + The default value is . + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + The default value is . + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the equality comparer used by the serializer when comparing references. + + The equality comparer. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets a function that creates the used by the serializer when resolving references. + + A function that creates the used by the serializer when resolving references. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Gets or sets how and values are formatted when writing JSON text, + and the expected date format when reading JSON text. + The default value is "yyyy'-'MM'-'dd'T'HH':'mm':'ss.FFFFFFFK". + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + A null value means there is no maximum. + The default value is 64. + + + + + Indicates how JSON text output is formatted. + The default value is . + + + + + Gets or sets how dates are written to JSON text. + The default value is . + + + + + Gets or sets how time zones are handled during serialization and deserialization. + The default value is . + + + + + Gets or sets how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + The default value is . + + + + + Gets or sets how special floating point numbers, e.g. , + and , + are written as JSON. + The default value is . + + + + + Gets or sets how floating point numbers, e.g. 1.0 and 9.9, are parsed when reading JSON text. + The default value is . + + + + + Gets or sets how strings are escaped when writing JSON text. + The default value is . + + + + + Gets or sets the culture used when reading JSON. + The default value is . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + The default value is false. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + using values copied from the passed in . + + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Asynchronously reads the next JSON token from the source. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns true if the next token was read successfully; false if there are no more tokens to read. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously reads the next JSON token from the source as a []. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the []. This result will be null at the end of an array. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously reads the next JSON token from the source as a of . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the of . This result will be null at the end of an array. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously reads the next JSON token from the source as a . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous read. The + property returns the . This result will be null at the end of an array. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Initializes a new instance of the class with the specified . + + The containing the JSON data to read. + + + + Gets or sets the reader's property name table. + + + + + Gets or sets the reader's character buffer pool. + + + + + Reads the next JSON token from the underlying . + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the underlying as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the underlying as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the underlying as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the underlying as a []. + + A [] or null if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the underlying as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the underlying as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the underlying as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the underlying as a of . + + A of . This method will return null at the end of an array. + + + + Changes the reader's state to . + If is set to true, the underlying is also closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if and can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, returns false). + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Asynchronously flushes whatever is in the buffer to the destination and also flushes the destination. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the JSON value delimiter. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the specified end token. + + The end token to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously closes this writer. + If is set to true, the destination is also closed. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the end of the current JSON object or array. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes indent characters. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes an indent space. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes raw JSON without changing the writer's state. + + The raw JSON to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a null value. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the property name of a name/value pair of a JSON object. + + The name of the property. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the property name of a name/value pair of a JSON object. + + The name of the property. + A flag to indicate whether the text should be escaped when it is written as a JSON property name. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the beginning of a JSON array. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the beginning of a JSON object. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the start of a constructor with the given name. + + The name of the constructor. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes an undefined value. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the given white space. + + The string of white space characters. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a [] value. + + The [] value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes a comment /*...*/ containing the specified text. + + Text to place inside the comment. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the end of an array. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the end of a constructor. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes the end of a JSON object. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Asynchronously writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + Derived classes must override this method to get asynchronous behaviour. Otherwise it will + execute synchronously, returning an already-completed task. + + + + Gets or sets the writer's character array pool. + + + + + Gets or sets how many s to write for each level in the hierarchy when is set to . + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to . + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + Initializes a new instance of the class using the specified . + + The to write to. + + + + Flushes whatever is in the buffer to the underlying and also flushes the underlying . + + + + + Closes this writer. + If is set to true, the underlying is also closed. + If is set to true, the JSON is auto-completed. + + + + + Writes the beginning of a JSON object. + + + + + Writes the beginning of a JSON array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + A flag to indicate whether the text should be escaped when it is written as a JSON property name. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a value. + + The value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the given white space. + + The string of white space characters. + + + + Specifies the type of JSON token. + + + + + This is returned by the if a read method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + + Represents a reader that provides validation. + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + + + + Sets an event handler for receiving schema validation errors. + + + + + Gets the text value of the current JSON token. + + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + + Gets the type of the current JSON token. + + + + + + Gets the .NET type for the current JSON token. + + + + + + Initializes a new instance of the class that + validates the content returned from the given . + + The to read from while validating. + + + + Gets or sets the schema. + + The schema. + + + + Gets the used to construct this . + + The specified in the constructor. + + + + Changes the reader's state to . + If is set to true, the underlying is also closed. + + + + + Reads the next JSON token from the underlying as a of . + + A of . + + + + Reads the next JSON token from the underlying as a []. + + + A [] or null if the next JSON token is null. + + + + + Reads the next JSON token from the underlying as a of . + + A of . + + + + Reads the next JSON token from the underlying as a of . + + A of . + + + + Reads the next JSON token from the underlying as a of . + + A of . + + + + Reads the next JSON token from the underlying as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the underlying as a of . + + A of . This method will return null at the end of an array. + + + + Reads the next JSON token from the underlying as a of . + + A of . + + + + Reads the next JSON token from the underlying . + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Asynchronously closes this writer. + If is set to true, the destination is also closed. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously flushes whatever is in the buffer to the destination and also flushes the destination. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the specified end token. + + The end token to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes indent characters. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the JSON value delimiter. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes an indent space. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes raw JSON without changing the writer's state. + + The raw JSON to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the end of the current JSON object or array. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the end of an array. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the end of a constructor. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the end of a JSON object. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a null value. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the property name of a name/value pair of a JSON object. + + The name of the property. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the property name of a name/value pair of a JSON object. + + The name of the property. + A flag to indicate whether the text should be escaped when it is written as a JSON property name. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the beginning of a JSON array. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a comment /*...*/ containing the specified text. + + Text to place inside the comment. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the start of a constructor with the given name. + + The name of the constructor. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the beginning of a JSON object. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the current token. + + The to read the token from. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the current token. + + The to read the token from. + A flag indicating whether the current token's children should be written. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the token and its value. + + The to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the token and its value. + + The to write. + + The value to write. + A value is only required for tokens that have an associated value, e.g. the property name for . + null can be passed to the method for tokens that don't have a value, e.g. . + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a [] value. + + The [] value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a value. + + The value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes a of value. + + The of value to write. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes an undefined value. + + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously writes the given white space. + + The string of white space characters. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Asynchronously ets the state of the . + + The being written. + The value being written. + The token to monitor for cancellation requests. The default value is . + A that represents the asynchronous operation. + The default behaviour is to execute synchronously, returning an already-completed task. Derived + classes can override this behaviour for true asynchronicity. + + + + Gets or sets a value indicating whether the destination should be closed when this writer is closed. + + + true to close the destination when this writer is closed; otherwise false. The default is true. + + + + + Gets or sets a value indicating whether the JSON should be auto-completed when this writer is closed. + + + true to auto-complete the JSON when this writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Gets or sets a value indicating how JSON text output should be formatted. + + + + + Gets or sets how dates are written to JSON text. + + + + + Gets or sets how time zones are handled when writing JSON text. + + + + + Gets or sets how strings are escaped when writing JSON text. + + + + + Gets or sets how special floating point numbers, e.g. , + and , + are written to JSON text. + + + + + Gets or sets how and values are formatted when writing JSON text. + + + + + Gets or sets the culture used when writing JSON. Defaults to . + + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the destination and also flushes the destination. + + + + + Closes this writer. + If is set to true, the destination is also closed. + If is set to true, the JSON is auto-completed. + + + + + Writes the beginning of a JSON object. + + + + + Writes the end of a JSON object. + + + + + Writes the beginning of a JSON array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair of a JSON object. + + The name of the property. + + + + Writes the property name of a name/value pair of a JSON object. + + The name of the property. + A flag to indicate whether the text should be escaped when it is written as a JSON property name. + + + + Writes the end of the current JSON object or array. + + + + + Writes the current token and its children. + + The to read the token from. + + + + Writes the current token. + + The to read the token from. + A flag indicating whether the current token's children should be written. + + + + Writes the token and its value. + + The to write. + + The value to write. + A value is only required for tokens that have an associated value, e.g. the property name for . + null can be passed to the method for tokens that don't have a value, e.g. . + + + + + Writes the token. + + The to write. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a of value. + + The of value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the given white space. + + The string of white space characters. + + + + Releases unmanaged and - optionally - managed resources. + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Sets the state of the . + + The being written. + The value being written. + + + + The exception thrown when an error occurs while writing JSON text. + + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or null if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Initializes a new instance of the class + with a specified error message, JSON path and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The path to the JSON where the error occurred. + The exception that is the cause of the current exception, or null if no inner exception is specified. + + + + Specifies how JSON comments are handled when loading JSON. + + + + + Ignore comments. + + + + + Load comments as a with type . + + + + + Specifies how duplicate property names are handled when loading JSON. + + + + + Replace the existing value when there is a duplicate property. The value of the last property in the JSON object will be used. + + + + + Ignore the new value when there is a duplicate property. The value of the first property in the JSON object will be used. + + + + + Throw a when a duplicate property is encountered. + + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every token in the source collection. + + + + Returns a collection of tokens that contains every token in the source collection, and the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains every token in the source collection, the ancestors of every token in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every token in the source collection. + + + + Returns a collection of tokens that contains every token in the source collection, and the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains every token in the source collection, and the descendants of every token in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every token in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every token in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every token in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every token in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every token in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every token in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a collection of objects. + + The type of token. + + + + Gets the of with the specified key. + + + + + + Represents a JSON array. + + + + + + + + Writes this token to a asynchronously. + + A into which this method will write. + The token to monitor for cancellation requests. + A collection of which will be used when writing the token. + A that represents the asynchronous write operation. + + + + Asynchronously loads a from a . + + A that will be read for the content of the . + If this is null, default load settings will be used. + The token to monitor for cancellation requests. The default value is . + A representing the asynchronous load. The property contains the JSON that was read from the specified . + + + + Asynchronously loads a from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + The token to monitor for cancellation requests. The default value is . + A representing the asynchronous load. The property contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads an from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Load a from a string that contains JSON. + + A that contains JSON. + The used to load the JSON. + If this is null, default load settings will be used. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object. + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + + + + + Returns an enumerator that iterates through the collection. + + + A of that can be used to iterate through the collection. + + + + + Adds an item to the . + + The object to add to the . + + + + Removes all items from the . + + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Copies the elements of the to an array, starting at a particular array index. + + The array. + Index of the array. + + + + Gets a value indicating whether the is read-only. + + true if the is read-only; otherwise, false. + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + + + + Represents a JSON constructor. + + + + + Writes this token to a asynchronously. + + A into which this method will write. + The token to monitor for cancellation requests. + A collection of which will be used when writing the token. + A that represents the asynchronous write operation. + + + + Asynchronously loads a from a . + + A that will be read for the content of the . + The token to monitor for cancellation requests. The default value is . + + A that represents the asynchronous load. The + property returns a that contains the JSON that was read from the specified . + + + + Asynchronously loads a from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + The token to monitor for cancellation requests. The default value is . + + A that represents the asynchronous load. The + property returns a that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Loads a from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads a from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Represents a token that can contain other tokens. + + + + + Occurs when the list changes or an item in the list changes. + + + + + Occurs before an item is added to the collection. + + + + + Occurs when the items list of the collection has changed, or the collection is reset. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Raises the event. + + The instance containing the event data. + + + + Raises the event. + + The instance containing the event data. + + + + Raises the event. + + The instance containing the event data. + + + + Gets a value indicating whether this token has child tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An of containing the descendant tokens of the . + + + + Returns a collection of the tokens that contain this token, and all descendant tokens of this token, in document order. + + An of containing this token, and all the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates a that can be used to add tokens to the . + + A that is ready to have content written to it. + + + + Replaces the child nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Merge the specified content into this . + + The content to be merged. + + + + Merge the specified content into this using . + + The content to be merged. + The used to merge the content. + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens. + + + + Represents a collection of objects. + + The type of token. + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that can be used to iterate through the collection. + + + A that can be used to iterate through the collection. + + + + + Gets the of with the specified key. + + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Represents a JSON object. + + + + + + + + Writes this token to a asynchronously. + + A into which this method will write. + The token to monitor for cancellation requests. + A collection of which will be used when writing the token. + A that represents the asynchronous write operation. + + + + Asynchronously loads a from a . + + A that will be read for the content of the . + The token to monitor for cancellation requests. The default value is . + + A that represents the asynchronous load. The + property returns a that contains the JSON that was read from the specified . + + + + Asynchronously loads a from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + The token to monitor for cancellation requests. The default value is . + + A that represents the asynchronous load. The + property returns a that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Occurs when a property value is changing. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets the node type for this . + + The type. + + + + Gets an of of this object's properties. + + An of of this object's properties. + + + + Gets a with the specified name. + + The property name. + A with the specified name or null. + + + + Gets the with the specified name. + The exact name will be searched for first and if no matching property is found then + the will be used to match a property. + + The property name. + One of the enumeration values that specifies how the strings will be compared. + A matched with the specified name or null. + + + + Gets a of of this object's property values. + + A of of this object's property values. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Loads a from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + is not valid JSON. + + + + + Loads a from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + is not valid JSON. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + is not valid JSON. + + + + + + + + Load a from a string that contains JSON. + + A that contains JSON. + The used to load the JSON. + If this is null, default load settings will be used. + A populated from the string that contains JSON. + + is not valid JSON. + + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object. + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Determines whether the JSON object has the specified property name. + + Name of the property. + true if the JSON object has the specified property name; otherwise, false. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries to get the with the specified property name. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that can be used to iterate through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Represents a JSON property. + + + + + Writes this token to a asynchronously. + + A into which this method will write. + The token to monitor for cancellation requests. + A collection of which will be used when writing the token. + A that represents the asynchronous write operation. + + + + Asynchronously loads a from a . + + A that will be read for the content of the . + The token to monitor for cancellation requests. The default value is . + A representing the asynchronous creation. The + property returns a that contains the JSON that was read from the specified . + + + + Asynchronously loads a from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + The token to monitor for cancellation requests. The default value is . + A representing the asynchronous creation. The + property returns a that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Gets the node type for this . + + The type. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads a from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Loads a from a . + + A that will be read for the content of the . + The used to load the JSON. + If this is null, default load settings will be used. + A that contains the JSON that was read from the specified . + + + + Represents a view of a . + + + + + Initializes a new instance of the class. + + The name. + + + + When overridden in a derived class, returns whether resetting an object changes its value. + + + true if resetting the component changes its value; otherwise, false. + + The component to test for reset capability. + + + + When overridden in a derived class, gets the current value of the property on a component. + + + The value of a property for a given component. + + The component with the property for which to retrieve the value. + + + + When overridden in a derived class, resets the value for this property of the component to the default value. + + The component with the property value that is to be reset to the default value. + + + + When overridden in a derived class, sets the value of the component to a different value. + + The component with the property value that is to be set. + The new value. + + + + When overridden in a derived class, determines a value indicating whether the value of this property needs to be persisted. + + + true if the property should be persisted; otherwise, false. + + The component with the property to be examined for persistence. + + + + When overridden in a derived class, gets the type of the component this property is bound to. + + + A that represents the type of component this property is bound to. + When the or + + methods are invoked, the object specified might be an instance of this type. + + + + + When overridden in a derived class, gets a value indicating whether this property is read-only. + + + true if the property is read-only; otherwise, false. + + + + + When overridden in a derived class, gets the type of the property. + + + A that represents the type of the property. + + + + + Gets the hash code for the name of the member. + + + + The hash code for the name of the member. + + + + + Represents a raw JSON string. + + + + + Asynchronously creates an instance of with the content of the reader's current token. + + The reader. + The token to monitor for cancellation requests. The default value is . + A representing the asynchronous creation. The + property returns an instance of with the content of the reader's current token. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Specifies the settings used when cloning JSON. + + + + + Initializes a new instance of the class. + + + + + Gets or sets a flag that indicates whether to copy annotations when cloning a . + The default value is true. + + + A flag that indicates whether to copy annotations when cloning a . + + + + + Specifies the settings used when loading JSON. + + + + + Initializes a new instance of the class. + + + + + Gets or sets how JSON comments are handled when loading JSON. + The default value is . + + The JSON comment handling. + + + + Gets or sets how JSON line info is handled when loading JSON. + The default value is . + + The JSON line info handling. + + + + Gets or sets how duplicate property names in JSON objects are handled when loading JSON. + The default value is . + + The JSON duplicate property name handling. + + + + Specifies the settings used when merging JSON. + + + + + Initializes a new instance of the class. + + + + + Gets or sets the method used when merging JSON arrays. + + The method used when merging JSON arrays. + + + + Gets or sets how null value properties are merged. + + How null value properties are merged. + + + + Gets or sets the comparison used to match property names while merging. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + The comparison used to match property names while merging. + + + + Specifies the settings used when selecting JSON. + + + + + Gets or sets a timeout that will be used when executing regular expressions. + + The timeout that will be used when executing regular expressions. + + + + Gets or sets a flag that indicates whether an error should be thrown if + no tokens are found when evaluating part of the expression. + + + A flag that indicates whether an error should be thrown if + no tokens are found when evaluating part of the expression. + + + + + Represents an abstract JSON token. + + + + + Writes this token to a asynchronously. + + A into which this method will write. + The token to monitor for cancellation requests. + A collection of which will be used when writing the token. + A that represents the asynchronous write operation. + + + + Writes this token to a asynchronously. + + A into which this method will write. + A collection of which will be used when writing the token. + A that represents the asynchronous write operation. + + + + Asynchronously creates a from a . + + An positioned at the token to read into this . + The token to monitor for cancellation requests. The default value is . + + A that represents the asynchronous creation. The + property returns a that contains + the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Asynchronously creates a from a . + + An positioned at the token to read into this . + The used to load the JSON. + If this is null, default load settings will be used. + The token to monitor for cancellation requests. The default value is . + + A that represents the asynchronous creation. The + property returns a that contains + the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Asynchronously creates a from a . + + A positioned at the token to read into this . + The token to monitor for cancellation requests. The default value is . + + A that represents the asynchronous creation. The + property returns a that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Asynchronously creates a from a . + + A positioned at the token to read into this . + The used to load the JSON. + If this is null, default load settings will be used. + The token to monitor for cancellation requests. The default value is . + + A that represents the asynchronous creation. The + property returns a that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has child tokens. + + + true if this token has child values; otherwise, false. + + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the path of the JSON token. + + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of tokens that contain this token, and the ancestors of this token. + + A collection of tokens that contain this token, and the ancestors of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + ToString() returns a non-JSON string value for tokens with a type of . + If you want the JSON for all token types then you should use . + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output should be formatted. + A collection of s which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to []. + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to of . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from [] to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from of to . + + The value to create a from. + The initialized with the specified value. + + + + Creates a for this token. + + A that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object. + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object. + + + + Creates an instance of the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates an instance of the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates an instance of the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates an instance of the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + A positioned at the token to read into this . + + A that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Creates a from a . + + An positioned at the token to read into this . + The used to load the JSON. + If this is null, default load settings will be used. + + A that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Load a from a string that contains JSON. + + A that contains JSON. + The used to load the JSON. + If this is null, default load settings will be used. + A populated from the string that contains JSON. + + + + Creates a from a . + + A positioned at the token to read into this . + The used to load the JSON. + If this is null, default load settings will be used. + + A that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Creates a from a . + + A positioned at the token to read into this . + + A that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects a using a JSONPath expression. Selects the token that matches the object path. + + + A that contains a JSONPath expression. + + A , or null. + + + + Selects a using a JSONPath expression. Selects the token that matches the object path. + + + A that contains a JSONPath expression. + + A flag to indicate whether an error should be thrown if no tokens are found when evaluating part of the expression. + A . + + + + Selects a using a JSONPath expression. Selects the token that matches the object path. + + + A that contains a JSONPath expression. + + The used to select tokens. + A . + + + + Selects a collection of elements using a JSONPath expression. + + + A that contains a JSONPath expression. + + An of that contains the selected elements. + + + + Selects a collection of elements using a JSONPath expression. + + + A that contains a JSONPath expression. + + A flag to indicate whether an error should be thrown if no tokens are found when evaluating part of the expression. + An of that contains the selected elements. + + + + Selects a collection of elements using a JSONPath expression. + + + A that contains a JSONPath expression. + + The used to select tokens. + An of that contains the selected elements. + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A object to configure cloning settings. + A new instance of the . + + + + Adds an object to the annotation list of this . + + The annotation to add. + + + + Get the first annotation object of the specified type from this . + + The type of the annotation to retrieve. + The first annotation object that matches the specified type, or null if no annotation is of the specified type. + + + + Gets the first annotation object of the specified type from this . + + The of the annotation to retrieve. + The first annotation object that matches the specified type, or null if no annotation is of the specified type. + + + + Gets a collection of annotations of the specified type for this . + + The type of the annotations to retrieve. + An that contains the annotations for this . + + + + Gets a collection of annotations of the specified type for this . + + The of the annotations to retrieve. + An of that contains the annotations that match the specified type for this . + + + + Removes the annotations of the specified type from this . + + The type of annotations to remove. + + + + Removes the annotations of the specified type from this . + + The of annotations to remove. + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized JSON data. + + + + + Gets the at the reader's current position. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Initializes a new instance of the class. + + The token to read from. + The initial path of the token. It is prepended to the returned . + + + + Reads the next JSON token from the underlying . + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Gets the path of the current JSON token. + + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating JSON data. + + + + + Gets the at the writer's current position. + + + + + Gets the token being written. + + The token being written. + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying . + + + + + Closes this writer. + If is set to true, the JSON is auto-completed. + + + Setting to true has no additional effect, since the underlying is a type that cannot be closed. + + + + + Writes the beginning of a JSON object. + + + + + Writes the beginning of a JSON array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a JSON object. + + The name of the property. + + + + Writes a value. + An error will be raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a [] value. + + The [] value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Writes this token to a asynchronously. + + A into which this method will write. + The token to monitor for cancellation requests. + A collection of which will be used when writing the token. + A that represents the asynchronous write operation. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Gets a value indicating whether this token has child tokens. + + + true if this token has child values; otherwise, false. + + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Creates a null value. + + A null value. + + + + Creates a undefined value. + + A undefined value. + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Writes this token to a . + + A into which this method will write. + A collection of s which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + ToString() returns a non-JSON string value for tokens with a type of . + If you want the JSON for all token types then you should use . + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not of the same type as this instance. + + + + + Specifies how line information is handled when loading JSON. + + + + + Ignore line information. + + + + + Load line information. + + + + + Specifies how JSON arrays are merged together. + + + + Concatenate arrays. + + + Union arrays, skipping items that already exist. + + + Replace all array items. + + + Merge array items together, matched by index. + + + + Specifies how null value properties are merged. + + + + + The content's null value properties will be ignored during merging. + + + + + The content's null value properties will be merged. + + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies metadata property handling options for the . + + + + + Read metadata properties located at the start of a JSON object. + + + + + Read metadata properties located anywhere in a JSON object. Note that this setting will impact performance. + + + + + Do not try to read metadata properties. + + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Specifies reference handling options for the . + Note that references cannot be preserved when a value is set via a non-default constructor such as types that implement . + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + The property is not required but it cannot be a null value. + + + + + + Contains the JSON schema extension methods. + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + + + + + Determines whether the is valid. + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + The source to test. + The schema to test with. + + true if the specified is valid; otherwise, false. + + + + + + Determines whether the is valid. + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + The source to test. + The schema to test with. + When this method returns, contains any error messages generated while validating. + + true if the specified is valid; otherwise, false. + + + + + + Validates the specified . + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + The source to test. + The schema to test with. + + + + + Validates the specified . + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + The source to test. + The schema to test with. + The validation event handler. + + + + + An in-memory representation of a JSON Schema. + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + + + + Gets or sets the id. + + + + + Gets or sets the title. + + + + + Gets or sets whether the object is required. + + + + + Gets or sets whether the object is read-only. + + + + + Gets or sets whether the object is visible to users. + + + + + Gets or sets whether the object is transient. + + + + + Gets or sets the description of the object. + + + + + Gets or sets the types of values allowed by the object. + + The type. + + + + Gets or sets the pattern. + + The pattern. + + + + Gets or sets the minimum length. + + The minimum length. + + + + Gets or sets the maximum length. + + The maximum length. + + + + Gets or sets a number that the value should be divisible by. + + A number that the value should be divisible by. + + + + Gets or sets the minimum. + + The minimum. + + + + Gets or sets the maximum. + + The maximum. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the minimum attribute (). + + A flag indicating whether the value can not equal the number defined by the minimum attribute (). + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the maximum attribute (). + + A flag indicating whether the value can not equal the number defined by the maximum attribute (). + + + + Gets or sets the minimum number of items. + + The minimum number of items. + + + + Gets or sets the maximum number of items. + + The maximum number of items. + + + + Gets or sets the of items. + + The of items. + + + + Gets or sets a value indicating whether items in an array are validated using the instance at their array position from . + + + true if items are validated using their array position; otherwise, false. + + + + + Gets or sets the of additional items. + + The of additional items. + + + + Gets or sets a value indicating whether additional items are allowed. + + + true if additional items are allowed; otherwise, false. + + + + + Gets or sets whether the array items must be unique. + + + + + Gets or sets the of properties. + + The of properties. + + + + Gets or sets the of additional properties. + + The of additional properties. + + + + Gets or sets the pattern properties. + + The pattern properties. + + + + Gets or sets a value indicating whether additional properties are allowed. + + + true if additional properties are allowed; otherwise, false. + + + + + Gets or sets the required property if this property is present. + + The required property if this property is present. + + + + Gets or sets the a collection of valid enum values allowed. + + A collection of valid enum values allowed. + + + + Gets or sets disallowed types. + + The disallowed types. + + + + Gets or sets the default value. + + The default value. + + + + Gets or sets the collection of that this schema extends. + + The collection of that this schema extends. + + + + Gets or sets the format. + + The format. + + + + Initializes a new instance of the class. + + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The object representing the JSON Schema. + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The to use when resolving schema references. + The object representing the JSON Schema. + + + + Load a from a string that contains JSON Schema. + + A that contains JSON Schema. + A populated from the string that contains JSON Schema. + + + + Load a from a string that contains JSON Schema using the specified . + + A that contains JSON Schema. + The resolver. + A populated from the string that contains JSON Schema. + + + + Writes this schema to a . + + A into which this method will write. + + + + Writes this schema to a using the specified . + + A into which this method will write. + The resolver used. + + + + Returns a that represents the current . + + + A that represents the current . + + + + + + Returns detailed information about the schema exception. + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or null if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + + Generates a from a specified . + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + + + + Gets or sets how undefined schemas are handled by the serializer. + + + + + Gets or sets the contract resolver. + + The contract resolver. + + + + Generate a from the specified type. + + The type to generate a from. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + + Resolves from an id. + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + + + + Gets or sets the loaded schemas. + + The loaded schemas. + + + + Initializes a new instance of the class. + + + + + Gets a for the specified reference. + + The id. + A for the specified reference. + + + + + The value types allowed by the . + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + + + + No type specified. + + + + + String type. + + + + + Float type. + + + + + Integer type. + + + + + Boolean type. + + + + + Object type. + + + + + Array type. + + + + + Null type. + + + + + Any type. + + + + + + Specifies undefined schema Id handling options for the . + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + + + + Do not infer a schema Id. + + + + + Use the .NET type name as the schema Id. + + + + + Use the assembly qualified .NET type name as the schema Id. + + + + + + Returns detailed information related to the . + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + + + + Gets the associated with the validation error. + + The JsonSchemaException associated with the validation error. + + + + Gets the path of the JSON location where the validation error occurred. + + The path of the JSON location where the validation error occurred. + + + + Gets the text description corresponding to the validation error. + + The text description. + + + + + Represents the callback method that will handle JSON schema validation events and the . + + + JSON Schema validation has been moved to its own package. See https://www.newtonsoft.com/jsonschema for more details. + + + + + + A camel case naming strategy. + + + + + Initializes a new instance of the class. + + + A flag indicating whether dictionary keys should be processed. + + + A flag indicating whether explicitly specified property names should be processed, + e.g. a property name customized with a . + + + + + Initializes a new instance of the class. + + + A flag indicating whether dictionary keys should be processed. + + + A flag indicating whether explicitly specified property names should be processed, + e.g. a property name customized with a . + + + A flag indicating whether extension data names should be processed. + + + + + Initializes a new instance of the class. + + + + + Resolves the specified property name. + + The property name to resolve. + The resolved property name. + + + + Resolves member mappings for a type, camel casing property names. + + + + + Initializes a new instance of the class. + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Used by to resolve a for a given . + + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets the default members search flags. + + The default members search flags. + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore the interface when serializing and deserializing types. + + + true if the interface will be ignored when serializing and deserializing types; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore the attribute when serializing and deserializing types. + + + true if the attribute will be ignored when serializing and deserializing types; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore IsSpecified members when serializing and deserializing types. + + + true if the IsSpecified members will be ignored when serializing and deserializing types; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore ShouldSerialize members when serializing and deserializing types. + + + true if the ShouldSerialize members will be ignored when serializing and deserializing types; otherwise, false. + + + + + Gets or sets the naming strategy used to resolve how property names and dictionary keys are serialized. + + The naming strategy used to resolve how property names and dictionary keys are serialized. + + + + Initializes a new instance of the class. + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Resolved name of the property. + + + + Resolves the name of the extension data. By default no changes are made to extension data names. + + Name of the extension data. + Resolved name of the extension data. + + + + Resolves the key of the dictionary. By default is used to resolve dictionary keys. + + Key of the dictionary. + Resolved key of the dictionary. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + The default naming strategy. Property names and dictionary keys are unchanged. + + + + + Resolves the specified property name. + + The property name to resolve. + The resolved property name. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + Initializes a new instance of the class. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Represents a trace writer that writes to the application's instances. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of will exclude messages and include , + and messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Get and set values for a using dynamic methods. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Provides information surrounding an error. + + + + + Gets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Provides data for the Error event. + + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Get and set values for a using dynamic methods. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Provides methods to get attributes. + + + + + Returns a collection of all of the attributes, or an empty collection if there are no attributes. + + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Returns a collection of attributes, identified by type, or an empty collection if there are no attributes. + + The type of the attributes. + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Used by to resolve a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that was resolved from the reference. + + + + Gets the reference for the specified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + Allows users to control class loading and mandate what class to load. + + + + + When implemented, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object + The type of the object the formatter creates a new instance of. + + + + When implemented, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Represents a trace writer. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of will exclude messages and include , + and messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Contract details for a used by the . + + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Gets or sets the function used to create the object. When set this function will override . + + The function used to create the object. + + + + Gets a value indicating whether the creator has a parameter with the collection values. + + true if the creator has a parameter with the collection values; otherwise, false. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Handles serialization callback events. + + The object that raised the callback event. + The streaming context. + + + + Handles serialization error callback events. + + The object that raised the callback event. + The streaming context. + The error context. + + + + Sets extension data for an object during deserialization. + + The object to set extension data on. + The extension data key. + The extension data value. + + + + Gets extension data for an object during serialization. + + The object to set extension data on. + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets the internally resolved for the contract's type. + This converter is used as a fallback converter when no other converter is resolved. + Setting will always override this converter. + + + + + Gets or sets all methods called immediately after deserialization of the object. + + The methods called immediately after deserialization of the object. + + + + Gets or sets all methods called during deserialization of the object. + + The methods called during deserialization of the object. + + + + Gets or sets all methods called after serialization of the object graph. + + The methods called after serialization of the object graph. + + + + Gets or sets all methods called before serialization of the object. + + The methods called before serialization of the object. + + + + Gets or sets all method called when an error is thrown during the serialization of the object. + + The methods called when an error is thrown during the serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non-public. + + true if the default object creator is non-public; otherwise, false. + + + + Contract details for a used by the . + + + + + Gets or sets the dictionary key resolver. + + The dictionary key resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Gets or sets the function used to create the object. When set this function will override . + + The function used to create the object. + + + + Gets a value indicating whether the creator has a parameter with the dictionary values. + + true if the creator has a parameter with the dictionary values; otherwise, false. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Gets the object's properties. + + The object's properties. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Gets or sets the object constructor. + + The object constructor. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets the missing member handling used when deserializing this object. + + The missing member handling. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets or sets how the object's properties with null values are handled during serialization and deserialization. + + How the object's properties with null values are handled during serialization and deserialization. + + + + Gets the object's properties. + + The object's properties. + + + + Gets a collection of instances that define the parameters used with . + + + + + Gets or sets the function used to create the object. When set this function will override . + This function is called with a collection of arguments which are defined by the collection. + + The function used to create the object. + + + + Gets or sets the extension data setter. + + + + + Gets or sets the extension data getter. + + + + + Gets or sets the extension data value type. + + + + + Gets or sets the extension data name resolver. + + The extension data name resolver. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization of a member. + + The numeric order of serialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the for this property. + + The for this property. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes precedence over the contract converter for the property type. + + The converter. + + + + Gets or sets the member converter. + + The member converter. + + + + Gets or sets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets or sets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets or sets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets or sets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets or sets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets a value indicating whether has a value specified. + + + + + Gets or sets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets or sets the property null value handling. + + The null value handling. + + + + Gets or sets the property default value handling. + + The default value handling. + + + + Gets or sets the property reference loop handling. + + The reference loop handling. + + + + Gets or sets the property object creation handling. + + The object creation handling. + + + + Gets or sets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets a predicate used to determine whether the property should be deserialized. + + A predicate used to determine whether the property should be deserialized. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Lookup and create an instance of the type described by the argument. + + The type to create. + Optional arguments to pass to an initializing constructor of the JsonConverter. + If null, the default constructor is used. + + + + A kebab case naming strategy. + + + + + Initializes a new instance of the class. + + + A flag indicating whether dictionary keys should be processed. + + + A flag indicating whether explicitly specified property names should be processed, + e.g. a property name customized with a . + + + + + Initializes a new instance of the class. + + + A flag indicating whether dictionary keys should be processed. + + + A flag indicating whether explicitly specified property names should be processed, + e.g. a property name customized with a . + + + A flag indicating whether extension data names should be processed. + + + + + Initializes a new instance of the class. + + + + + Resolves the specified property name. + + The property name to resolve. + The resolved property name. + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of will exclude messages and include , + and messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + A base class for resolving how property names and dictionary keys are serialized. + + + + + A flag indicating whether dictionary keys should be processed. + Defaults to false. + + + + + A flag indicating whether extension data names should be processed. + Defaults to false. + + + + + A flag indicating whether explicitly specified property names, + e.g. a property name customized with a , should be processed. + Defaults to false. + + + + + Gets the serialized name for a given property name. + + The initial property name. + A flag indicating whether the property has had a name explicitly specified. + The serialized property name. + + + + Gets the serialized name for a given extension data name. + + The initial extension data name. + The serialized extension data name. + + + + Gets the serialized key for a given dictionary key. + + The initial dictionary key. + The serialized dictionary key. + + + + Resolves the specified property name. + + The property name to resolve. + The resolved property name. + + + + Hash code calculation + + + + + + Object equality implementation + + + + + + + Compare to another NamingStrategy + + + + + + + Represents a method that constructs an object. + + The object type to create. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Provides methods to get attributes from a , , or . + + + + + Initializes a new instance of the class. + + The instance to get attributes for. This parameter should be a , , or . + + + + Returns a collection of all of the attributes, or an empty collection if there are no attributes. + + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Returns a collection of attributes, identified by type, or an empty collection if there are no attributes. + + The type of the attributes. + When true, look up the hierarchy chain for the inherited custom attribute. + A collection of s, or an empty collection. + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + A snake case naming strategy. + + + + + Initializes a new instance of the class. + + + A flag indicating whether dictionary keys should be processed. + + + A flag indicating whether explicitly specified property names should be processed, + e.g. a property name customized with a . + + + + + Initializes a new instance of the class. + + + A flag indicating whether dictionary keys should be processed. + + + A flag indicating whether explicitly specified property names should be processed, + e.g. a property name customized with a . + + + A flag indicating whether extension data names should be processed. + + + + + Initializes a new instance of the class. + + + + + Resolves the specified property name. + + The property name to resolve. + The resolved property name. + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Indicates the method that will be used during deserialization for locating and loading assemblies. + + + + + In simple mode, the assembly used during deserialization need not match exactly the assembly used during serialization. Specifically, the version numbers need not match as the LoadWithPartialName method of the class is used to load the assembly. + + + + + In full mode, the assembly used during deserialization must match exactly the assembly used during serialization. The Load method of the class is used to load the assembly. + + + + + Specifies type name handling options for the . + + + should be used with caution when your application deserializes JSON from an external source. + Incoming types should be validated with a custom + when deserializing with a value other than . + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + Note that this doesn't include the root serialized object by default. To include the root object's type name in JSON + you must specify a root type object with + or . + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic . + + The list to add to. + The collection of elements to add. + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic that returns a result + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic, but uses one of the arguments for + the result. + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic, but uses one of the arguments for + the result. + + + + + Returns a Restrictions object which includes our current restrictions merged + with a restriction limiting our type + + + + + Helper class for serializing immutable collections. + Note that this is used by all builds, even those that don't support immutable collections, in case the DLL is GACed + https://github.com/JamesNK/pyRevitLabs.Json/issues/652 + + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Builds a string. Unlike this class lets you reuse its internal buffer. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls result in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + An array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + diff --git a/dev/libs/netcore/pyRevitLabs.MahAppsMetro.dll b/dev/libs/netcore/pyRevitLabs.MahAppsMetro.dll new file mode 100644 index 000000000..62ffa87e9 Binary files /dev/null and b/dev/libs/netcore/pyRevitLabs.MahAppsMetro.dll differ diff --git a/dev/libs/pyRevitLabs.MahAppsMetro.xml b/dev/libs/netcore/pyRevitLabs.MahAppsMetro.xml similarity index 100% rename from dev/libs/pyRevitLabs.MahAppsMetro.xml rename to dev/libs/netcore/pyRevitLabs.MahAppsMetro.xml diff --git a/dev/libs/netcore/pyRevitLabs.NLog.dll b/dev/libs/netcore/pyRevitLabs.NLog.dll new file mode 100644 index 000000000..997b0c57e Binary files /dev/null and b/dev/libs/netcore/pyRevitLabs.NLog.dll differ diff --git a/dev/libs/netcore/pyRevitLabs.NLog.xml b/dev/libs/netcore/pyRevitLabs.NLog.xml new file mode 100644 index 000000000..32f9593c8 --- /dev/null +++ b/dev/libs/netcore/pyRevitLabs.NLog.xml @@ -0,0 +1,28363 @@ + + + + pyRevitLabs.NLog + + + + + Interface for serialization of object values into JSON format + + + + + Serialization of an object into JSON format. + + The object to serialize to JSON. + Output destination. + Serialize succeeded (true/false) + + + + Auto-generated Logger members for binary compatibility with NLog 1.0. + + + Provides logging interface and utility functions. + + + + + Writes the diagnostic message at the Trace level. + + A to be written. + + + + Writes the diagnostic message at the Trace level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format.s + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level. + + A to be written. + + + + Writes the diagnostic message at the Debug level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level. + + A to be written. + + + + Writes the diagnostic message at the Info level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Info level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Info level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level. + + A to be written. + + + + Writes the diagnostic message at the Warn level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Warn level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Warn level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level. + + A to be written. + + + + Writes the diagnostic message at the Error level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Error level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Error level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level. + + A to be written. + + + + Writes the diagnostic message at the Fatal level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Fatal level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Gets a value indicating whether logging is enabled for the Trace level. + + A value of if logging is enabled for the Trace level, otherwise it returns . + + + + Gets a value indicating whether logging is enabled for the Debug level. + + A value of if logging is enabled for the Debug level, otherwise it returns . + + + + Gets a value indicating whether logging is enabled for the Info level. + + A value of if logging is enabled for the Info level, otherwise it returns . + + + + Gets a value indicating whether logging is enabled for the Warn level. + + A value of if logging is enabled for the Warn level, otherwise it returns . + + + + Gets a value indicating whether logging is enabled for the Error level. + + A value of if logging is enabled for the Error level, otherwise it returns . + + + + Gets a value indicating whether logging is enabled for the Fatal level. + + A value of if logging is enabled for the Fatal level, otherwise it returns . + + + + Writes the diagnostic message at the Trace level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Trace level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Trace level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Trace level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Trace level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message and exception at the Trace level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Trace level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Trace level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Trace level. + + Log message. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Trace level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message at the Trace level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Trace level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Debug level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Debug level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Debug level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Debug level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Debug level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message and exception at the Debug level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Debug level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Debug level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Debug level. + + Log message. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Debug level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message at the Debug level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Info level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Info level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Info level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Info level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Info level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message and exception at the Info level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Info level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Info level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Info level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Info level. + + Log message. + + + + Writes the diagnostic message at the Info level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Info level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message at the Info level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Info level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Info level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Info level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Warn level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Warn level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Warn level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Warn level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Warn level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message and exception at the Warn level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Warn level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Warn level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Warn level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Warn level. + + Log message. + + + + Writes the diagnostic message at the Warn level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Warn level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message at the Warn level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Warn level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Warn level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Warn level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Error level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Error level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Error level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Error level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Error level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message and exception at the Error level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Error level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Error level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Error level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Error level. + + Log message. + + + + Writes the diagnostic message at the Error level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Error level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message at the Error level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Error level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Error level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Error level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Fatal level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Fatal level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Fatal level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Fatal level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message and exception at the Fatal level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Fatal level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Fatal level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Fatal level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Fatal level. + + Log message. + + + + Writes the diagnostic message at the Fatal level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the Fatal level. + + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message at the Fatal level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Auto-generated Logger members for binary compatibility with NLog 1.0. + + + Logger with only generic methods (passing 'LogLevel' to methods) and core properties. + + + + + Writes the diagnostic message at the specified level. + + The log level. + A to be written. + + + + Writes the diagnostic message at the specified level. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the specified level using the specified parameters. + + The log level. + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the specified level using the specified parameters. + + The log level. + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Occurs when logger configuration changes. + + + + + Gets the name of the logger. + + + + + Gets the factory that created this logger. + + + + + Gets a value indicating whether logging is enabled for the specified level. + + Log level to be checked. + A value of if logging is enabled for the specified level, otherwise it returns . + + + + Writes the specified diagnostic message. + + Log event. + + + + Writes the specified diagnostic message. + + Type of custom Logger wrapper. + Log event. + + + + Writes the diagnostic message at the specified level using the specified format provider and format parameters. + + + Writes the diagnostic message at the specified level. + + Type of the value. + The log level. + The value to be written. + + + + Writes the diagnostic message at the specified level. + + Type of the value. + The log level. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the specified level. + + The log level. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the specified level. + + The log level. + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message and exception at the specified level. + + The log level. + A to be written. + Arguments to format. + An exception to be logged. + + + + Writes the diagnostic message and exception at the specified level. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + Arguments to format. + An exception to be logged. + + + + Writes the diagnostic message at the specified level using the specified parameters and formatting them with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the specified level. + + The log level. + Log message. + + + + Writes the diagnostic message at the specified level using the specified parameters. + + The log level. + A containing format items. + Arguments to format. + + + + Obsolete and replaced by - Writes the diagnostic message and exception at the specified level. + + The log level. + A to be written. + An exception to be logged. + This method was marked as obsolete before NLog 4.3.11 and it may be removed in a future release. + + + + Writes the diagnostic message at the specified level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified parameter. + + The type of the argument. + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the specified level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The log level. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the specified level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the specified level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + The log level. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Provides an interface to execute System.Actions without surfacing any exceptions raised for that action. + + + + + Runs the provided action. If the action throws, the exception is logged at Error level. The exception is not propagated outside of this method. + + Action to execute. + + + + Runs the provided function and returns its result. If an exception is thrown, it is logged at Error level. + The exception is not propagated outside of this method; a default value is returned instead. + + Return type of the provided function. + Function to run. + Result returned by the provided function or the default value of type in case of exception. + + + + Runs the provided function and returns its result. If an exception is thrown, it is logged at Error level. + The exception is not propagated outside of this method; a fallback value is returned instead. + + Return type of the provided function. + Function to run. + Fallback value to return in case of exception. + Result returned by the provided function or fallback value in case of exception. + + + + Logs an exception is logged at Error level if the provided task does not run to completion. + + The task for which to log an error if it does not run to completion. + This method is useful in fire-and-forget situations, where application logic does not depend on completion of task. This method is avoids C# warning CS4014 in such situations. + + + + Returns a task that completes when a specified task to completes. If the task does not run to completion, an exception is logged at Error level. The returned task always runs to completion. + + The task for which to log an error if it does not run to completion. + A task that completes in the state when completes. + + + + Runs async action. If the action throws, the exception is logged at Error level. The exception is not propagated outside of this method. + + Async action to execute. + A task that completes in the state when completes. + + + + Runs the provided async function and returns its result. If the task does not run to completion, an exception is logged at Error level. + The exception is not propagated outside of this method; a default value is returned instead. + + Return type of the provided function. + Async function to run. + A task that represents the completion of the supplied task. If the supplied task ends in the state, the result of the new task will be the result of the supplied task; otherwise, the result of the new task will be the default value of type . + + + + Runs the provided async function and returns its result. If the task does not run to completion, an exception is logged at Error level. + The exception is not propagated outside of this method; a fallback value is returned instead. + + Return type of the provided function. + Async function to run. + Fallback value to return if the task does not end in the state. + A task that represents the completion of the supplied task. If the supplied task ends in the state, the result of the new task will be the result of the supplied task; otherwise, the result of the new task will be the fallback value. + + + + Render a message template property to a string + + + + + Serialization of an object, e.g. JSON and append to + + The object to serialize to string. + Parameter Format + Parameter CaptureType + An object that supplies culture-specific formatting information. + Output destination. + Serialize succeeded (true/false) + + + + Support implementation of + + + + + + + + + + + + + + + + + Mark a parameter of a method for message templating + + + + + Specifies which parameter of an annotated method should be treated as message-template-string + + + + + The name of the parameter that should be as treated as message-template-string + + + + + Asynchronous continuation delegate - function invoked at the end of asynchronous + processing. + + Exception during asynchronous processing or null if no exception + was thrown. + + + + Helpers for asynchronous operations. + + + + + Iterates over all items in the given collection and runs the specified action + in sequence (each action executes only after the preceding one has completed without an error). + + Type of each item. + The items to iterate. + The asynchronous continuation to invoke once all items + have been iterated. + The action to invoke for each item. + + + + Repeats the specified asynchronous action multiple times and invokes asynchronous continuation at the end. + + The repeat count. + The asynchronous continuation to invoke at the end. + The action to invoke. + + + + Modifies the continuation by pre-pending given action to execute just before it. + + The async continuation. + The action to pre-pend. + Continuation which will execute the given action before forwarding to the actual continuation. + + + + Attaches a timeout to a continuation which will invoke the continuation when the specified + timeout has elapsed. + + The asynchronous continuation. + The timeout. + Wrapped continuation. + + + + Iterates over all items in the given collection and runs the specified action + in parallel (each action executes on a thread from thread pool). + + Type of each item. + The items to iterate. + The asynchronous continuation to invoke once all items + have been iterated. + The action to invoke for each item. + + + + Runs the specified asynchronous action synchronously (blocks until the continuation has + been invoked). + + The action. + + Using this method is not recommended because it will block the calling thread. + + + + + Wraps the continuation with a guard which will only make sure that the continuation function + is invoked only once. + + The asynchronous continuation. + Wrapped asynchronous continuation. + + + + Gets the combined exception from all exceptions in the list. + + The exceptions. + Combined exception or null if no exception was thrown. + + + + Disposes the Timer, and waits for it to leave the Timer-callback-method + + The Timer object to dispose + Timeout to wait (TimeSpan.Zero means dispose without waiting) + Timer disposed within timeout (true/false) + + + + Asynchronous action. + + Continuation to be invoked at the end of action. + + + + Asynchronous action with one argument. + + Type of the argument. + Argument to the action. + Continuation to be invoked at the end of action. + + + + Represents the logging event with asynchronous continuation. + + + + + Initializes a new instance of the struct. + + The log event. + The continuation. + + + + Gets the log event. + + + + + Gets the continuation. + + + + + Implements the operator ==. + + The event info1. + The event info2. + The result of the operator. + + + + Implements the operator ==. + + The event info1. + The event info2. + The result of the operator. + + + + + + + + + + + + + String Conversion Helpers + + + + + Converts input string value into . Parsing is case-insensitive. + + Input value + Output value + Default value + Returns false if the input value could not be parsed + + + + Converts input string value into . Parsing is case-insensitive. + + Input value + The type of the enum + Output value. Null if parse failed + + + + Converts the string representation of the name or numeric value of one or more enumerated constants to an equivalent enumerated object. A parameter specifies whether the operation is case-sensitive. The return value indicates whether the conversion succeeded. + + The enumeration type to which to convert value. + The string representation of the enumeration name or underlying value to convert. + true to ignore case; false to consider case. + When this method returns, result contains an object of type TEnum whose value is represented by value if the parse operation succeeds. If the parse operation fails, result contains the default value of the underlying type of TEnum. Note that this value need not be a member of the TEnum enumeration. This parameter is passed uninitialized. + true if the value parameter was converted successfully; otherwise, false. + Wrapper because Enum.TryParse is not present in .net 3.5 + + + + Enum.TryParse implementation for .net 3.5 + + + Don't uses reflection + + + + Enables to extract extra context details for + + + + + Name of context + + + + + The current LogFactory next to LogManager + + + + + NLog internal logger. + + Writes to file, console or custom text writer (see ) + + + Don't use as that can lead to recursive calls - stackoverflow + + + + + Gets a value indicating whether internal log includes Trace messages. + + + + + Gets a value indicating whether internal log includes Debug messages. + + + + + Gets a value indicating whether internal log includes Info messages. + + + + + Gets a value indicating whether internal log includes Warn messages. + + + + + Gets a value indicating whether internal log includes Error messages. + + + + + Gets a value indicating whether internal log includes Fatal messages. + + + + + Logs the specified message without an at the Trace level. + + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Trace level. + + Log message. + + + + Logs the specified message without an at the Trace level. + will be only called when logging is enabled for level Trace. + + Function that returns the log message. + + + + Logs the specified message with an at the Trace level. + + Exception to be logged. + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + Message which may include positional parameters. + Argument {0} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + Argument {2} to the message. + + + + Logs the specified message with an at the Trace level. + + Exception to be logged. + Log message. + + + + Logs the specified message with an at the Trace level. + will be only called when logging is enabled for level Trace. + + Exception to be logged. + Function that returns the log message. + + + + Logs the specified message without an at the Debug level. + + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Debug level. + + Log message. + + + + Logs the specified message without an at the Debug level. + will be only called when logging is enabled for level Debug. + + Function that returns the log message. + + + + Logs the specified message with an at the Debug level. + + Exception to be logged. + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + Message which may include positional parameters. + Argument {0} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + Argument {2} to the message. + + + + Logs the specified message with an at the Debug level. + + Exception to be logged. + Log message. + + + + Logs the specified message with an at the Debug level. + will be only called when logging is enabled for level Debug. + + Exception to be logged. + Function that returns the log message. + + + + Logs the specified message without an at the Info level. + + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Info level. + + Log message. + + + + Logs the specified message without an at the Info level. + will be only called when logging is enabled for level Info. + + Function that returns the log message. + + + + Logs the specified message with an at the Info level. + + Exception to be logged. + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + Message which may include positional parameters. + Argument {0} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + Argument {2} to the message. + + + + Logs the specified message with an at the Info level. + + Exception to be logged. + Log message. + + + + Logs the specified message with an at the Info level. + will be only called when logging is enabled for level Info. + + Exception to be logged. + Function that returns the log message. + + + + Logs the specified message without an at the Warn level. + + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Warn level. + + Log message. + + + + Logs the specified message without an at the Warn level. + will be only called when logging is enabled for level Warn. + + Function that returns the log message. + + + + Logs the specified message with an at the Warn level. + + Exception to be logged. + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + Message which may include positional parameters. + Argument {0} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + Argument {2} to the message. + + + + Logs the specified message with an at the Warn level. + + Exception to be logged. + Log message. + + + + Logs the specified message with an at the Warn level. + will be only called when logging is enabled for level Warn. + + Exception to be logged. + Function that returns the log message. + + + + Logs the specified message without an at the Error level. + + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Error level. + + Log message. + + + + Logs the specified message without an at the Error level. + will be only called when logging is enabled for level Error. + + Function that returns the log message. + + + + Logs the specified message with an at the Error level. + + Exception to be logged. + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + Message which may include positional parameters. + Argument {0} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + Argument {2} to the message. + + + + Logs the specified message with an at the Error level. + + Exception to be logged. + Log message. + + + + Logs the specified message with an at the Error level. + will be only called when logging is enabled for level Error. + + Exception to be logged. + Function that returns the log message. + + + + Logs the specified message without an at the Fatal level. + + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Fatal level. + + Log message. + + + + Logs the specified message without an at the Fatal level. + will be only called when logging is enabled for level Fatal. + + Function that returns the log message. + + + + Logs the specified message with an at the Fatal level. + + Exception to be logged. + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + Message which may include positional parameters. + Argument {0} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + + + + Logs the specified message without an at the Trace level. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + Message which may include positional parameters. + Argument {0} to the message. + Argument {1} to the message. + Argument {2} to the message. + + + + Logs the specified message with an at the Fatal level. + + Exception to be logged. + Log message. + + + + Logs the specified message with an at the Fatal level. + will be only called when logging is enabled for level Fatal. + + Exception to be logged. + Function that returns the log message. + + + + Set the config of the InternalLogger with defaults and config. + + + + + Gets or sets the minimal internal log level. + + If set to , then messages of the levels , and will be written. + + + + Gets or sets a value indicating whether internal messages should be written to the console output stream. + + Your application must be a console application. + + + + Gets or sets a value indicating whether internal messages should be written to the console error stream. + + Your application must be a console application. + + + + Gets or sets a value indicating whether internal messages should be written to the .Trace + + + + + Gets or sets the file path of the internal log file. + + A value of value disables internal logging to a file. + + + + Gets or sets the text writer that will receive internal logs. + + + + + Event written to the internal log. + + + EventHandler will only be triggered for events, where severity matches the configured . + + Avoid using/calling NLog Logger-objects when handling these internal events, as it will lead to deadlock / stackoverflow. + + + + + Gets or sets a value indicating whether timestamp should be included in internal log output. + + + + + Is there an thrown when writing the message? + + + + + Logs the specified message without an at the specified level. + + Log level. + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message without an at the specified level. + + Log level. + Log message. + + + + Logs the specified message without an at the specified level. + will be only called when logging is enabled for level . + + Log level. + Function that returns the log message. + + + + Logs the specified message with an at the specified level. + will be only called when logging is enabled for level . + + Exception to be logged. + Log level. + Function that returns the log message. + + + + Logs the specified message with an at the specified level. + + Exception to be logged. + Log level. + Message which may include positional parameters. + Arguments to the message. + + + + Logs the specified message with an at the specified level. + + Exception to be logged. + Log level. + Log message. + + + + Write to internallogger. + + optional exception to be logged. + level + message + optional args for + + + + Create log line with timestamp, exception message etc (if configured) + + + + + Determine if logging should be avoided because of exception type. + + The exception to check. + true if logging should be avoided; otherwise, false. + + + + Determine if logging is enabled for given LogLevel + + The for the log event. + true if logging is enabled; otherwise, false. + + + + Determine if logging is enabled. + + true if logging is enabled; otherwise, false. + + + + Write internal messages to the log file defined in . + + Message to write. + + Message will be logged only when the property is not null, otherwise the + method has no effect. + + + + + Write internal messages to the defined in . + + Message to write. + + Message will be logged only when the property is not null, otherwise the + method has no effect. + + + + + Write internal messages to the . + + Message to write. + + Message will be logged only when the property is true, otherwise the + method has no effect. + + + + + Write internal messages to the . + + Message to write. + + Message will be logged when the property is true, otherwise the + method has no effect. + + + + + Write internal messages to the . + + A message to write. + + Works when property set to true. + The is used in Debug and Release configuration. + The works only in Debug configuration and this is reason why is replaced by . + in DEBUG + + + + + Logs the assembly version and file version of the given Assembly. + + The assembly to log. + + + + A message has been written to the internal logger + + + + + The rendered message + + + + + The log level + + + + + The exception. Could be null. + + + + + The type that triggered this internal log event, for example the FileTarget. + This property is not always populated. + + + + + The context name that triggered this internal log event, for example the name of the Target. + This property is not always populated. + + + + + A cyclic buffer of object. + + + + + Initializes a new instance of the class. + + Buffer size. + Whether buffer should grow as it becomes full. + The maximum number of items that the buffer can grow to. + + + + Gets the capacity of the buffer + + + + + Gets the number of items in the buffer + + + + + Adds the specified log event to the buffer. + + Log event. + The number of items in the buffer. + + + + Gets the array of events accumulated in the buffer and clears the buffer as one atomic operation. + + Events in the buffer. + + + + Marks class as a log event Condition and assigns a name to it. + + + + + Initializes a new instance of the class. + + Condition method name. + + + + Marks the class as containing condition methods. + + + + + A bunch of utility methods (mostly predicates) which can be used in + condition expressions. Partially inspired by XPath 1.0. + + + + + Compares two values for equality. + + The first value. + The second value. + true when two objects are equal, false otherwise. + + + + Compares two strings for equality. + + The first string. + The second string. + Optional. If true, case is ignored; if false (default), case is significant. + true when two strings are equal, false otherwise. + + + + Gets or sets a value indicating whether the second string is a substring of the first one. + + The first string. + The second string. + Optional. If true (default), case is ignored; if false, case is significant. + true when the second string is a substring of the first string, false otherwise. + + + + Gets or sets a value indicating whether the second string is a prefix of the first one. + + The first string. + The second string. + Optional. If true (default), case is ignored; if false, case is significant. + true when the second string is a prefix of the first string, false otherwise. + + + + Gets or sets a value indicating whether the second string is a suffix of the first one. + + The first string. + The second string. + Optional. If true (default), case is ignored; if false, case is significant. + true when the second string is a prefix of the first string, false otherwise. + + + + Returns the length of a string. + + A string whose lengths is to be evaluated. + The length of the string. + + + + Indicates whether the specified regular expression finds a match in the specified input string. + + The string to search for a match. + The regular expression pattern to match. + A string consisting of the desired options for the test. The possible values are those of the separated by commas. + true if the regular expression finds a match; otherwise, false. + + + + + + + + + + + Relational operators used in conditions. + + + + + Equality (==). + + + + + Inequality (!=). + + + + + Less than (<). + + + + + Greater than (>). + + + + + Less than or equal (<=). + + + + + Greater than or equal (>=). + + + + + Exception during evaluation of condition expression. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The message. + + + + Initializes a new instance of the class. + + The message. + The inner exception. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + + The parameter is null. + + + The class name is null or is zero (0). + + + + + Exception during parsing of condition expression. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The message. + + + + Initializes a new instance of the class. + + The message. + The inner exception. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + + The parameter is null. + + + The class name is null or is zero (0). + + + + + Condition and expression. + + + + + Initializes a new instance of the class. + + Left hand side of the AND expression. + Right hand side of the AND expression. + + + + Gets the left hand side of the AND expression. + + + + + Gets the right hand side of the AND expression. + + + + + Returns a string representation of this expression. + + A concatenated '(Left) and (Right)' string. + + + + Evaluates the expression by evaluating and recursively. + + Evaluation context. + The value of the conjunction operator. + + + + Condition message expression (represented by the exception keyword). + + + + + + + + Evaluates the current . + + Evaluation context. + The object. + + + + Base class for representing nodes in condition expression trees. + + Documentation on NLog Wiki + + + + Converts condition text to a condition expression tree. + + Condition text to be converted. + Condition expression tree. + + + + Evaluates the expression. + + Evaluation context. + Expression result. + + + + Returns a string representation of the expression. + + + + + Evaluates the expression. + + Evaluation context. + Expression result. + + + + Condition layout expression (represented by a string literal + with embedded ${}). + + + + + Initializes a new instance of the class. + + The layout. + + + + Gets the layout. + + The layout. + + + + + + + Evaluates the expression by rendering the formatted output from + the + + Evaluation context. + The output rendered from the layout. + + + + Condition level expression (represented by the level keyword). + + + + + + + + Evaluates to the current log level. + + Evaluation context. + The object representing current log level. + + + + Condition literal expression (numeric, LogLevel.XXX, true or false). + + + + + Initializes a new instance of the class. + + Literal value. + + + + Gets the literal value. + + The literal value. + + + + + + + Evaluates the expression. + + Evaluation context. Ignored. + The literal value as passed in the constructor. + + + + Condition logger name expression (represented by the logger keyword). + + + + + + + + Evaluates to the logger name. + + Evaluation context. + The logger name. + + + + Condition message expression (represented by the message keyword). + + + + + + + + Evaluates to the logger message. + + Evaluation context. + The logger message. + + + + Gets the method parameters + + + + + + + + + + + Condition not expression. + + + + + Initializes a new instance of the class. + + The expression. + + + + Gets the expression to be negated. + + The expression. + + + + + + + + + + Condition or expression. + + + + + Initializes a new instance of the class. + + Left hand side of the OR expression. + Right hand side of the OR expression. + + + + Gets the left expression. + + The left expression. + + + + Gets the right expression. + + The right expression. + + + + + + + Evaluates the expression by evaluating and recursively. + + Evaluation context. + The value of the alternative operator. + + + + Condition relational (==, !=, <, <=, + > or >=) expression. + + + + + Initializes a new instance of the class. + + The left expression. + The right expression. + The relational operator. + + + + Gets the left expression. + + The left expression. + + + + Gets the right expression. + + The right expression. + + + + Gets the relational operator. + + The operator. + + + + + + + + + + Compares the specified values using specified relational operator. + + The first value. + The second value. + The relational operator. + Result of the given relational operator. + + + + Promote values to the type needed for the comparison, e.g. parse a string to int. + + + + + + + Promotes to type + + + + success? + + + + Try to promote both values. First try to promote to , + when failed, try to . + + + + + + Get the order for the type for comparison. + + + index, 0 to max int. Lower is first + + + + Dictionary from type to index. Lower index should be tested first. + + + + + Build the dictionary needed for the order of the types. + + + + + + Get the string representing the current + + + + + + Condition parser. Turns a string representation of condition expression + into an expression tree. + + + + + Initializes a new instance of the class. + + The string reader. + Instance of used to resolve references to condition methods and layout renderers. + + + + Parses the specified condition string and turns it into + tree. + + The expression to be parsed. + The root of the expression syntax tree which can be used to get the value of the condition in a specified context. + + + + Parses the specified condition string and turns it into + tree. + + The expression to be parsed. + Instance of used to resolve references to condition methods and layout renderers. + The root of the expression syntax tree which can be used to get the value of the condition in a specified context. + + + + Parses the specified condition string and turns it into + tree. + + The string reader. + Instance of used to resolve references to condition methods and layout renderers. + + The root of the expression syntax tree which can be used to get the value of the condition in a specified context. + + + + + Try stringed keyword to + + + + success? + + + + Parse number + + negative number? minus should be parsed first. + + + + + Hand-written tokenizer for conditions. + + + + + Initializes a new instance of the class. + + The string reader. + + + + Asserts current token type and advances to the next token. + + Expected token type. + If token type doesn't match, an exception is thrown. + + + + Asserts that current token is a keyword and returns its value and advances to the next token. + + Keyword value. + + + + Gets or sets a value indicating whether current keyword is equal to the specified value. + + The keyword. + + A value of true if current keyword is equal to the specified value; otherwise, false. + + + + + Gets or sets a value indicating whether the tokenizer has reached the end of the token stream. + + + A value of true if the tokenizer has reached the end of the token stream; otherwise, false. + + + + + Gets or sets a value indicating whether current token is a number. + + + A value of true if current token is a number; otherwise, false. + + + + + Gets or sets a value indicating whether the specified token is of specified type. + + The token type. + + A value of true if current token is of specified type; otherwise, false. + + + + + Gets the next token and sets and properties. + + + + + Try the comparison tokens (greater, smaller, greater-equals, smaller-equals) + + current char + is match + + + + Try the logical tokens (and, or, not, equals) + + current char + is match + + + + Mapping between characters and token types for punctuations. + + + + + Initializes a new instance of the CharToTokenType struct. + + The character. + Type of the token. + + + + Token types for condition expressions. + + + + + Marks the class or a member as advanced. Advanced classes and members are hidden by + default in generated documentation. + + + + + Initializes a new instance of the class. + + + + + Identifies that the output of layout or layout render does not change for the lifetime of the current appdomain. + + + + Implementors must have the [ThreadAgnostic] attribute + + A layout(renderer) could be converted to a literal when: + - The layout and all layout properties are SimpleLayout or [AppDomainFixedOutput] + + Recommendation: Apply this attribute to a layout or layout-renderer which have the result only changes by properties of type Layout. + + + + + Used to mark configurable parameters which are arrays. + Specifies the mapping between XML elements and .NET types. + + + + + Initializes a new instance of the class. + + The type of the array item. + The XML element name that represents the item. + + + + Gets the .NET type of the array item. + + + + + Gets the XML element name. + + + + + Load from url + + file or path, including .dll + basepath, optional + + + + + Load from url + + + + + Provides logging interface and utility functions. + + + + + Obsolete since dynamic assembly loading is not compatible with publish as trimmed application. + Event notification about trying to load assembly with NLog extensions. + + + + + Initializes a new instance of the class. + + Assembly that have been loaded + + + + The assembly that is trying to load. + + + + + Obsolete since dynamic tyope loading is not compatible with publish as trimmed application. + Constructs a new instance the configuration item (target, layout, layout renderer, etc.) given its type. + + Type of the item. + Created object of the specified type. + + + + Provides registration information for named items (targets, layouts, layout renderers, etc.) + + Supports creating item-instance from their type-alias, when parsing NLog configuration + + + + + Obsolete since dynamic assembly loading is not compatible with publish as trimmed application. + Called before the assembly with NLog extensions is being loaded. + + + + + Initializes a new instance of the class. + + + + + Obsolete since dynamic assembly loading is not compatible with publish as trimmed application. + Initializes a new instance of the class. + + The assemblies to scan for named items. + + + + Gets or sets default singleton instance of . + + + This property implements lazy instantiation so that the is not built before + the internal logger is configured. + + + + + Gets the factory. + + + + + Gets the factory. + + + + + Gets the factory. + + + + + Gets the ambient property factory. + + + + + Gets the factory. + + + + + Gets the factory. + + + + + Obsolete and replaced by with NLog v5.2. + Gets or sets the creator delegate used to instantiate configuration objects. + + + By overriding this property, one can enable dependency injection or interception for created objects. + + + + + Obsolete and replaced by with NLog v5.2. + Gets the factory. + + The target factory. + + + + Obsolete and replaced by with NLog v5.2. + Gets the factory. + + The layout factory. + + + + Obsolete and replaced by with NLog v5.2. + Gets the factory. + + The layout renderer factory. + + + + Obsolete and replaced by with NLog v5.2. + Gets the ambient property factory. + + The ambient property factory. + + + + Obsolete and replaced by with NLog v5.2. + Gets the factory. + + The filter factory. + + + + Obsolete and replaced by with NLog v5.2. + Gets the time source factory. + + The time source factory. + + + + Obsolete and replaced by with NLog v5.2. + Gets the condition method factory. + + The condition method factory. + + + + Obsolete and replaced by with NLog v5.2. + Gets or sets the JSON serializer to use with + + + + + Obsolete and replaced by with NLog v5.2. + Gets or sets the string serializer to use with + + + + + Obsolete and replaced by with NLog v5.2. + Gets or sets the parameter converter to use with or + + + + + Perform message template parsing and formatting of LogEvent messages (True = Always, False = Never, Null = Auto Detect) + + + - Null (Auto Detect) : NLog-parser checks for positional parameters, and will then fallback to string.Format-rendering. + - True: Always performs the parsing of and rendering of using the NLog-parser (Allows custom formatting with ) + - False: Always performs parsing and rendering using string.Format (Fastest if not using structured logging) + + + + + Obsolete since dynamic assembly loading is not compatible with publish as trimmed application. + Registers named items from the assembly. + + The assembly. + + + + Obsolete since dynamic assembly loading is not compatible with publish as trimmed application. + Registers named items from the assembly. + + The assembly. + Item name prefix. + + + + Obsolete since dynamic assembly loading is not compatible with publish as trimmed application. + Call Preload for NLogPackageLoader + + + Every package could implement a class "NLogPackageLoader" (namespace not important) with the public static method "Preload" (no arguments) + This method will be called just before registering all items in the assembly. + + + + + + Call the Preload method for . The Preload method must be static. + + + + + + Clears the contents of all factories. + + + + + Obsolete since dynamic type loading is not compatible with publish as trimmed application. + Registers the type. + + The type to register. + The item name prefix. + + + + Builds the default configuration item factory. + + Default factory. + + + + Registers items in using late-bound types, so that we don't need a reference to the dll. + + + + + Attribute used to mark the default parameters for layout renderers. + + + + + Initializes a new instance of the class. + + + + + Dynamic filtering with a positive list of enabled levels + + + + + Dynamic filtering with a minlevel and maxlevel range + + + + + Format of the exception output to the specific target. + + + + + Appends the Message of an Exception to the specified target. + + + + + Appends the type of an Exception to the specified target. + + + + + Appends the short type of an Exception to the specified target. + + + + + Appends the result of calling ToString() on an Exception to the specified target. + + + + + Appends the method name from Exception's stack trace to the specified target. + + + + + Appends the stack trace from an Exception to the specified target. + + + + + Appends the contents of an Exception's Data property to the specified target. + + + + + Destructure the exception (usually into JSON) + + + + + Appends the from the application or the object that caused the error. + + + + + Appends the from the application or the object that caused the error. + + + + + Appends any additional properties that specific type of Exception might have. + + + + + Factory for class-based items. + + The base type of each item. + The type of the attribute used to annotate items. + + + + Scans the assembly. + + The types to scan. + The assembly name for the types. + The prefix. + + + + Registers the type. + + The type to register. + The item name prefix. + + + + Registers the item based on a type name. + + Name of the item. + Name of the type. + + + + Clears the contents of the factory. + + + + + + + + + + + + + + + + + Factory specialized for s. + + + + + + + + Register a layout renderer with a callback function. + + Name of the layoutrenderer, without ${}. + the renderer that renders the value. + + + + + + + Factory of named items (such as , , , etc.). + + + + + Factory of named items (such as , , , etc.). + + + + + Registers type-creation with type-alias + + + + + Tries to create an item instance with type-alias + + True if instance was created successfully, false otherwise. + + + + Include context properties + + + + + Gets or sets the option to include all properties from the log events + + + + + + Gets or sets whether to include the contents of the properties-dictionary. + + + + + + Gets or sets whether to include the contents of the nested-state-stack. + + + + + + Did the Initialize Succeeded? true= success, false= error, null = initialize not started yet. + + + + + Implemented by objects which support installation and uninstallation. + + + + + Performs installation which requires administrative permissions. + + The installation context. + + + + Performs uninstallation which requires administrative permissions. + + The installation context. + + + + Determines whether the item is installed. + + The installation context. + + Value indicating whether the item is installed or null if it is not possible to determine. + + + + + Interface for accessing configuration details + + + + + Name of this configuration element + + + + + Configuration Key/Value Pairs + + + + + Child configuration elements + + + + + Interface for loading NLog + + + + + Finds and loads the NLog configuration + + LogFactory that owns the NLog configuration + Name of NLog.config file (optional) + NLog configuration (or null if none found) + + + + Notifies when LoggingConfiguration has been successfully applied + + LogFactory that owns the NLog configuration + NLog Config + + + + Get file paths (including filename) for the possible NLog config files. + + Name of NLog.config file (optional) + The file paths to the possible config file + + + + Level enabled flags for each LogLevel ordinal + + + + + Converts the filter into a simple + + + + + Obsolete since dynamic type loading is not compatible with publish as trimmed application. Replaced by . + Represents a factory of named items (such as targets, layouts, layout renderers, etc.). + + Base type for each item instance. + Item definition type (typically ). + + + + Registers new item definition. + + Name of the item. + Item definition. + + + + Tries to get registered item definition. + + Name of the item. + Reference to a variable which will store the item definition. + Item definition. + + + + Creates item instance. + + Name of the item. + Newly created item instance. + + + + Tries to create an item instance. + + Name of the item. + The result. + True if instance was created successfully, false otherwise. + + + + Provides context for install/uninstall operations. + + + + + Mapping between log levels and console output colors. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The log output. + + + + Gets or sets the installation log level. + + + + + Gets or sets a value indicating whether to ignore failures during installation. + + + + + Whether installation exceptions should be rethrown. If IgnoreFailures is set to true, + this property has no effect (there are no exceptions to rethrow). + + + + + Gets the installation parameters. + + + + + Gets or sets the log output. + + + + + Logs the specified trace message. + + The message. + The arguments. + + + + Logs the specified debug message. + + The message. + The arguments. + + + + Logs the specified informational message. + + The message. + The arguments. + + + + Logs the specified warning message. + + The message. + The arguments. + + + + Logs the specified error message. + + The message. + The arguments. + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Creates the log event which can be used to render layouts during install/uninstall. + + Log event info object. + + + + Convert object-value into specified type + + + + + Parses the input value and converts into the wanted type + + Input Value + Wanted Type + Format to use when parsing + Culture to use when parsing + Output value with wanted type + + + + Interface for fluent setup of LogFactory options + + + + + LogFactory under configuration + + + + + Interface for fluent setup of LoggingRules for LoggingConfiguration + + + + + LoggingRule being built + + + + + Interface for fluent setup of target for LoggingRule + + + + + LoggingConfiguration being built + + + + + LogFactory under configuration + + + + + Collection of targets that should be written to + + + + + Interface for fluent setup of LogFactory options for extension loading + + + + + LogFactory under configuration + + + + + Interface for fluent setup of LogFactory options for enabling NLog + + + + + LogFactory under configuration + + + + + Interface for fluent setup of LoggingConfiguration for LogFactory + + + + + LogFactory under configuration + + + + + LoggingConfiguration being built + + + + + Interface for fluent setup of LogFactory options + + + + + LogFactory under configuration + + + + + Interface for fluent setup of LogFactory options for logevent serialization + + + + + LogFactory under configuration + + + + + Allows components to request stack trace information to be provided in the . + + + + + Gets the level of stack trace information required by the implementing class. + + + + + Encapsulates and the logic to match the actual logger name + All subclasses defines immutable objects. + Concrete subclasses defines various matching rules through + + + + + Creates a concrete based on . + + + Rules used to select the concrete implementation returned: + + if is null => returns (never matches) + if doesn't contains any '*' nor '?' => returns (matches only on case sensitive equals) + if == '*' => returns (always matches) + if doesn't contain '?' + + if contains exactly 2 '*' one at the beginning and one at the end (i.e. "*foobar*) => returns + if contains exactly 1 '*' at the beginning (i.e. "*foobar") => returns + if contains exactly 1 '*' at the end (i.e. "foobar*") => returns + + + returns + + + + It may include one or more '*' or '?' wildcards at any position. + + '*' means zero or more occurrences of any character + '?' means exactly one occurrence of any character + + + A concrete + + + + Returns the argument passed to + + + + + Checks whether given name matches the logger name pattern. + + String to be matched. + A value of when the name matches, otherwise. + + + + Defines a that never matches. + Used when pattern is null + + + + + Defines a that always matches. + Used when pattern is '*' + + + + + Defines a that matches with a case-sensitive Equals + Used when pattern is a string without wildcards '?' '*' + + + + + Defines a that matches with a case-sensitive StartsWith + Used when pattern is a string like "*foobar" + + + + + Defines a that matches with a case-sensitive EndsWith + Used when pattern is a string like "foobar*" + + + + + Defines a that matches with a case-sensitive Contains + Used when pattern is a string like "*foobar*" + + + + + Defines a that matches with a complex wildcards combinations: + + '*' means zero or more occurrences of any character + '?' means exactly one occurrence of any character + + used when pattern is a string containing any number of '?' or '*' in any position + i.e. "*Server[*].Connection[?]" + + + + + Keeps logging configuration and provides simple API to modify it. + + This class is thread-safe..ToList() is used for that purpose. + + + + Gets the factory that will be configured + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + + + Gets the variables defined in the configuration or assigned from API + + Name is case insensitive. + + + + Gets a collection of named targets specified in the configuration. + + + A list of named targets. + + + Unnamed targets (such as those wrapped by other targets) are not returned. + + + + + Gets the collection of file names which should be watched for changes by NLog. + + + + + Gets the collection of logging rules. + + + + + Gets or sets the default culture info to use as . + + + Specific culture info or null to use + + + + + Gets all targets. + + + + + Inserts NLog Config Variable without overriding NLog Config Variable assigned from API + + + + + Lookup NLog Config Variable Layout + + + + + Registers the specified target object. The name of the target is read from . + + + The target object with a non + + when is + + + + Registers the specified target object under a given name. + + Name of the target. + The target object. + when is + when is + + + + Finds the target with the specified name. + + + The name of the target to be found. + + + Found target or when the target is not found. + + + + + Finds the target with the specified name and specified type. + + + The name of the target to be found. + + Type of the target + + Found target or when the target is not found of not of type + + + + + Add a rule with min- and maxLevel. + + Minimum log level needed to trigger this rule. + Maximum log level needed to trigger this rule. + Name of the target to be written when the rule matches. + Logger name pattern. It may include the '*' wildcard at the beginning, at the end or at both ends. + + + + Add a rule with min- and maxLevel. + + Minimum log level needed to trigger this rule. + Maximum log level needed to trigger this rule. + Target to be written to when the rule matches. + Logger name pattern. It may include the '*' wildcard at the beginning, at the end or at both ends. + + + + Add a rule with min- and maxLevel. + + Minimum log level needed to trigger this rule. + Maximum log level needed to trigger this rule. + Target to be written to when the rule matches. + Logger name pattern. It may include the '*' wildcard at the beginning, at the end or at both ends. + Gets or sets a value indicating whether to quit processing any further rule when this one matches. + + + + Add a rule object. + + rule object to add + + + + Add a rule for one loglevel. + + log level needed to trigger this rule. + Name of the target to be written when the rule matches. + Logger name pattern. It may include the '*' wildcard at the beginning, at the end or at both ends. + + + + Add a rule for one loglevel. + + log level needed to trigger this rule. + Target to be written to when the rule matches. + Logger name pattern. It may include the '*' wildcard at the beginning, at the end or at both ends. + + + + Add a rule for one loglevel. + + log level needed to trigger this rule. + Target to be written to when the rule matches. + Logger name pattern. It may include the '*' wildcard at the beginning, at the end or at both ends. + Gets or sets a value indicating whether to quit processing any further rule when this one matches. + + + + Add a rule for all loglevels. + + Name of the target to be written when the rule matches. + Logger name pattern. It may include the '*' wildcard at the beginning, at the end or at both ends. + + + + Add a rule for all loglevels. + + Target to be written to when the rule matches. + Logger name pattern. It may include the '*' wildcard at the beginning, at the end or at both ends. + + + + Add a rule for all loglevels. + + Target to be written to when the rule matches. + Logger name pattern. It may include the '*' wildcard at the beginning, at the end or at both ends. + Gets or sets a value indicating whether to quit processing any further rule when this one matches. + + + + Lookup the logging rule with matching + + The name of the logging rule to be found. + Found logging rule or when not found. + + + + Removes the specified named logging rule with matching + + The name of the logging rule to be removed. + Found one or more logging rule to remove, or when not found. + + + + Called by LogManager when one of the log configuration files changes. + + + A new instance of that represents the updated configuration. + + Must assign the returned object to LogManager.Configuration to activate it + + + + Allow this new configuration to capture state from the old configuration + + Old config that is about to be replaced + Checks KeepVariablesOnReload and copies all NLog Config Variables assigned from API into the new config + + + + Removes the specified named target. + + Name of the target. + + + + Installs target-specific objects on current system. + + The installation context. + + Installation typically runs with administrative permissions. + + + + + Uninstalls target-specific objects from current system. + + The installation context. + + Uninstallation typically runs with administrative permissions. + + + + + Closes all targets and releases any unmanaged resources. + + + + + Log to the internal (NLog) logger the information about the and associated with this instance. + + + The information are only recorded in the internal logger if Debug level is enabled, otherwise nothing is + recorded. + + + + + Validates the configuration. + + + + + Replace a simple variable with a value. The original value is removed and thus we cannot redo this in a later stage. + + + + + + + Checks whether unused targets exist. If found any, just write an internal log at Warn level. + If initializing not started or failed, then checking process will be canceled + + + + + + + + Arguments for events. + + + + + Initializes a new instance of the class. + + The new configuration. + The old configuration. + + + + Gets the old configuration. + + The old configuration. + + + + Gets the new configuration. + + + New value can be null when unloading configuration during shutdown. + + The new configuration. + + + + Gets the optional boolean attribute value. + + + Name of the attribute. + Default value to return if the attribute is not found or if there is a parse error + Boolean attribute value or default. + + + + Remove the namespace (before :) + + + x:a, will be a + + + + + + + Enables loading of NLog configuration from a file + + + + + Get default file paths (including filename) for possible NLog config files. + + + + + Get default file paths (including filename) for possible NLog config files. + + + + + Loads NLog configuration from + + + + + Constructor + + + + + + Loads NLog configuration from provided config section + + + Directory where the NLog-config-file was loaded from + + + + Builds list with unique keys, using last value of duplicates. High priority keys placed first. + + + + + + + Parse loglevel, but don't throw if exception throwing is disabled + + Name of attribute for logging. + Value of parse. + Used if there is an exception + + + + + Parses a single config section within the NLog-config + + + Section was recognized + + + + Parse {Rules} xml element + + + Rules are added to this parameter. + + + + Parse {Logger} xml element + + + + + + Parse boolean + + Name of the property for logging. + value to parse + Default value to return if the parse failed + Boolean attribute value or default. + + + + Config element that's validated and having extra context + + + + + Explicit cast because NET35 doesn't support covariance. + + + + + Obsolete and replaced by and with NLog v5.2. + + + + + Initializes a new instance of the class. + + Whether configuration reload has succeeded. + + + + Initializes a new instance of the class. + + Whether configuration reload has succeeded. + The exception during configuration reload. + + + + Gets a value indicating whether configuration reload has succeeded. + + A value of true if succeeded; otherwise, false. + + + + Gets the exception which occurred during configuration reload. + + The exception. + + + + Enables FileWatcher for the currently loaded NLog Configuration File, + and supports automatic reload on file modification. + + + + + Represents a logging rule. An equivalent of <logger /> configuration element. + + + + + Create an empty . + + + + + Create an empty . + + + + + Create a new with a and which writes to . + + Logger name pattern used for . It may include one or more '*' or '?' wildcards at any position. + Minimum log level needed to trigger this rule. + Maximum log level needed to trigger this rule. + Target to be written to when the rule matches. + + + + Create a new with a which writes to . + + Logger name pattern used for . It may include one or more '*' or '?' wildcards at any position. + Minimum log level needed to trigger this rule. + Target to be written to when the rule matches. + + + + Create a (disabled) . You should call or to enable logging. + + Logger name pattern used for . It may include one or more '*' or '?' wildcards at any position. + Target to be written to when the rule matches. + + + + Rule identifier to allow rule lookup + + + + + Gets a collection of targets that should be written to when this rule matches. + + + + + Gets a collection of child rules to be evaluated when this rule matches. + + + + + Gets a collection of filters to be checked before writing to targets. + + + + + Gets or sets a value indicating whether to quit processing any following rules when this one matches. + + + + + Gets or sets the whether to quit processing any following rules when lower severity and this one matches. + + + Loggers matching will be restricted to specified minimum level for following rules. + + + + + Gets or sets logger name pattern. + + + Logger name pattern used by to check if a logger name matches this rule. + It may include one or more '*' or '?' wildcards at any position. + + '*' means zero or more occurrences of any character + '?' means exactly one occurrence of any character + + + + + + Gets the collection of log levels enabled by this rule. + + + + + Obsolete and replaced by with NLog v5. + + Default action when filters not matching + + + NLog v4.6 introduced the setting with default value . + NLog v5 marked it as obsolete and change default value to + + + + + Default action if none of the filters match + + + NLog v5 changed default value to + + + + + Enables logging for a particular level. + + Level to be enabled. + + + + Enables logging for a particular levels between (included) and . + + Minimum log level needed to trigger this rule. + Maximum log level needed to trigger this rule. + + + + Disables logging for a particular level. + + Level to be disabled. + + + + Disables logging for particular levels between (included) and . + + Minimum log level to be disables. + Maximum log level to be disabled. + + + + Enables logging the levels between (included) and . All the other levels will be disabled. + + Minimum log level needed to trigger this rule. + Maximum log level needed to trigger this rule. + + + + Returns a string representation of . Used for debugging. + + + + + Checks whether the particular log level is enabled for this rule. + + Level to be checked. + A value of when the log level is enabled, otherwise. + + + + Checks whether given name matches the . + + String to be matched. + A value of when the name matches, otherwise. + + + + Default filtering with static level config + + + + + Factory for locating methods. + + + + + Initializes a new instance of the class. + + + + + Scans the assembly for classes marked with expected class + and methods marked with expected and adds them + to the factory. + + The types to scan. + The assembly name for the type. + The item name prefix. + + + + Registers the type. + + The type to register. + The item name prefix. + + + + Registers the type. + + The type to register. + The item name prefix. + + + + Scans a type for relevant methods with their symbolic names + + Include types that are marked with this attribute + Include methods that are marked with this attribute + Class Type to scan + Collection of methods with their symbolic names + + + + Clears contents of the factory. + + + + + Registers the definition of a single method. + + The method name. + The method info. + + + + Tries to retrieve method by name. + + The method name. + The result. + A value of true if the method was found, false otherwise. + + + + Retrieves method by name. + + Method name. + MethodInfo object. + + + + Tries to get method definition. + + The method name. + The result. + A value of true if the method was found, false otherwise. + + + + Marks the layout or layout renderer depends on mutable objects from the LogEvent + + This can be or + + + + + Attaches a type-alias for an item (such as , + , , etc.). + + + + + Initializes a new instance of the class. + + The type-alias for use in NLog configuration. + + + + Gets the name of the type-alias + + + + + Indicates NLog should not scan this property during configuration. + + + + + Initializes a new instance of the class. + + + + + Marks the object as configuration item for NLog. + + + + + Initializes a new instance of the class. + + + + + Failed to resolve the interface of service type + + + + + Typed we tried to resolve + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + + + Default implementation of + + + + + Singleton instance of the serializer. + + + + + + + + Attribute used to mark the required parameters for targets, + layout targets and filters. + + + + + Interface to register available configuration objects type + + + + + Registers instance of singleton object for use in NLog + + Type of service/interface to register + Instance of service + + + + Gets the service object of the specified type. + + Avoid calling this while handling a LogEvent, since random deadlocks can occur. + + + + Registers singleton-object as implementation of specific interface. + + + If the same single-object implements multiple interfaces then it must be registered for each interface + + Type of interface + The repo + Singleton object to use for override + + + + Registers the string serializer to use with + + + + + Repository of interfaces used by NLog to allow override for dependency injection + + + + + Initializes a new instance of the class. + + + + + Registered service type in the service repository + + + + + Initializes a new instance of the class. + + Type of service that have been registered + + + + Type of service-interface that has been registered + + + + + Obsolete and replaced by with NLog v5.2. + + Provides simple programmatic configuration API used for trivial logging cases. + + Warning, these methods will overwrite the current config. + + + + + Obsolete and replaced by and with NLog v5.2. + + Configures NLog for console logging so that all messages above and including + the level are output to the console. + + + + + Obsolete and replaced by and with NLog v5.2. + + Configures NLog for console logging so that all messages above and including + the specified level are output to the console. + + The minimal logging level. + + + + Obsolete and replaced by with NLog v5.2. + + Configures NLog for to log to the specified target so that all messages + above and including the level are output. + + The target to log all messages to. + + + + Obsolete and replaced by with NLog v5.2. + + Configures NLog for to log to the specified target so that all messages + above and including the specified level are output. + + The target to log all messages to. + The minimal logging level. + + + + Obsolete and replaced by and with NLog v5.2. + + Configures NLog for file logging so that all messages above and including + the level are written to the specified file. + + Log file name. + + + + Obsolete and replaced by and with NLog v5.2. + + Configures NLog for file logging so that all messages above and including + the specified level are written to the specified file. + + Log file name. + The minimal logging level. + + + + Value indicating how stack trace should be captured when processing the log event. + + + + + No Stack trace needs to be captured. + + + + + Stack trace should be captured. This option won't add the filenames and linenumbers + + + + + Capture also filenames and linenumbers + + + + + Capture the location of the call + + + + + Capture the class name for location of the call + + + + + Stack trace should be captured. This option won't add the filenames and linenumbers. + + + + + Stack trace should be captured including filenames and linenumbers. + + + + + Capture maximum amount of the stack trace information supported on the platform. + + + + + Marks the layout or layout renderer as thread independent - it producing correct results + regardless of the thread it's running on. + + Without this attribute everything is rendered on the main thread. + + + If this attribute is set on a layout, it could be rendered on the another thread. + This could be more efficient as it's skipped when not needed. + + If context like HttpContext.Current is needed, which is only available on the main thread, this attribute should not be applied. + + See the AsyncTargetWrapper and BufferTargetWrapper with the , using + + Apply this attribute when: + - The result can we rendered in another thread. Delaying this could be more efficient. And/Or, + - The result should not be precalculated, for example the target sends some extra context information. + + + + + Marks the layout or layout renderer as thread safe - it producing correct results + regardless of the number of threads it's running on. + + Without this attribute then the target concurrency will be reduced + + + + + A class for configuring NLog through an XML configuration file + (App.config style or App.nlog style). + + Parsing of the XML file is also implemented in this class. + + + - This class is thread-safe..ToList() is used for that purpose. + - Update TemplateXSD.xml for changes outside targets + + + + + Initializes a new instance of the class. + + Configuration file to be read. + + + + Initializes a new instance of the class. + + Configuration file to be read. + The to which to apply any applicable configuration values. + + + + Obsolete and replaced by with NLog v4.7. + + Initializes a new instance of the class. + + Configuration file to be read. + Ignore any errors during configuration. + + + + Obsolete and replaced by with NLog v4.7. + + Initializes a new instance of the class. + + Configuration file to be read. + Ignore any errors during configuration. + The to which to apply any applicable configuration values. + + + + Initializes a new instance of the class. + + XML reader to read from. + + + + Initializes a new instance of the class. + + containing the configuration section. + Name of the file that contains the element (to be used as a base for including other files). null is allowed. + + + + Initializes a new instance of the class. + + containing the configuration section. + Name of the file that contains the element (to be used as a base for including other files). null is allowed. + The to which to apply any applicable configuration values. + + + + Obsolete and replaced by with NLog v4.7. + + Initializes a new instance of the class. + + containing the configuration section. + Name of the file that contains the element (to be used as a base for including other files). null is allowed. + Ignore any errors during configuration. + + + + Obsolete and replaced by with NLog v4.7. + + Initializes a new instance of the class. + + containing the configuration section. + Name of the file that contains the element (to be used as a base for including other files). null is allowed. + Ignore any errors during configuration. + The to which to apply any applicable configuration values. + + + + Initializes a new instance of the class. + + NLog configuration as XML string. + Name of the XML file. + The to which to apply any applicable configuration values. + + + + Parse XML string as NLog configuration + + NLog configuration in XML to be parsed + + + + Parse XML string as NLog configuration + + NLog configuration in XML to be parsed + NLog LogFactory + + + + Did the Succeeded? true= success, false= error, null = initialize not started yet. + + + + + Gets or sets a value indicating whether all of the configuration files + should be watched for changes and reloaded automatically when changed. + + + + + Gets the collection of file names which should be watched for changes by NLog. + This is the list of configuration files processed. + If the autoReload attribute is not set it returns empty collection. + + + + + Re-reads the original configuration file and returns the new object. + + The newly loaded instance. + Must assign the returned object to LogManager.Configuration to activate it + + + + Get file paths (including filename) for the possible NLog config files. + + The file paths to the possible config file + + + + Overwrite the paths (including filename) for the possible NLog config files. + + The file paths to the possible config file + + + + Clear the candidate file paths and return to the defaults. + + + + + Create XML reader for (xml config) file. + + filepath + reader or null if filename is empty. + + + + Initializes the configuration. + + containing the configuration section. + Name of the file that contains the element (to be used as a base for including other files). null is allowed. + Ignore any errors during configuration. + + + + Add a file with configuration. Check if not already included. + + + + + + + Parse the root + + + path to config file. + The default value for the autoReload option. + + + + Parse {configuration} xml element. + + + path to config file. + The default value for the autoReload option. + + + + Parse {NLog} xml element. + + + path to config file. + The default value for the autoReload option. + + + + Parses a single config section within the NLog-config + + + Section was recognized + + + + Include (multiple) files by filemask, e.g. *.nlog + + base directory in case if is relative + relative or absolute fileMask + + + + + + + + Represents simple XML element with case-insensitive attribute semantics. + + + + + Initializes a new instance of the class. + + The reader to initialize element from. + + + + Gets the element name. + + + + + Gets the dictionary of attribute values. + + + + + Gets the collection of child elements. + + + + + Gets the value of the element. + + + + + Returns children elements with the specified element name. + + Name of the element. + Children elements with the specified element name. + + + + Asserts that the name of the element is among specified element names. + + The allowed names. + + + + Special attribute we could ignore + + + + + Global Diagnostics Context - a dictionary structure to hold per-application-instance values. + + + + + Sets the value with the specified key in the Global Diagnostics Context (GDC) dictionary + + Item name. + Item value. + + + + Sets the value with the specified key in the Global Diagnostics Context (GDC) dictionary + + Item name. + Item value. + + + + Gets the value with the specified key in the Global Diagnostics Context (GDC) dictionary + + Item name. + The value of , if defined; otherwise . + If the value isn't a already, this call locks the for reading the needed for converting to . + + + + Gets the value with the specified key in the Global Diagnostics Context (GDC) dictionary + + Item name. + to use when converting the item's value to a string. + The value of as a string, if defined; otherwise . + If is null and the value isn't a already, this call locks the for reading the needed for converting to . + + + + Gets the value with the specified key in the Global Diagnostics Context (GDC) dictionary + + Item name. + The item value, if defined; otherwise null. + + + + Gets all key-names from Global Diagnostics Context (GDC) dictionary + + A collection of the names of all items in the Global Diagnostics Context. + + + + Determines whether the Global Diagnostics Context (GDC) dictionary contains the specified key. + + Item name. + A boolean indicating whether the specified item exists in current thread GDC. + + + + Removes the value with the specified key from the Global Diagnostics Context (GDC) dictionary + + Item name. + + + + Clears the content of the Global Diagnostics Context (GDC) dictionary. + + + + + Obsolete and replaced by with NLog v5. + + Mapped Diagnostics Context (MDC) is a dictionary of keys and values. + Stores the dictionary in the thread-local static variable, and provides methods to output dictionary values in layouts. + + + + + Sets the current thread MDC item to the specified value. + + Item name. + Item value. + An that can be used to remove the item from the current thread MDC. + + + + Sets the current thread MDC item to the specified value. + + Item name. + Item value. + >An that can be used to remove the item from the current thread MDC. + + + + Sets the current thread MDC item to the specified value. + + Item name. + Item value. + + + + Sets the current thread MDC item to the specified value. + + Item name. + Item value. + + + + Gets the current thread MDC named item, as . + + Item name. + The value of , if defined; otherwise . + If the value isn't a already, this call locks the for reading the needed for converting to . + + + + Gets the current thread MDC named item, as . + + Item name. + The to use when converting a value to a . + The value of , if defined; otherwise . + If is null and the value isn't a already, this call locks the for reading the needed for converting to . + + + + Gets the current thread MDC named item, as . + + Item name. + The value of , if defined; otherwise null. + + + + Returns all item names + + A set of the names of all items in current thread-MDC. + + + + Checks whether the specified item exists in current thread MDC. + + Item name. + A boolean indicating whether the specified exists in current thread MDC. + + + + Removes the specified from current thread MDC. + + Item name. + + + + Clears the content of current thread MDC. + + + + + Obsolete and replaced by with NLog v5. + + Mapped Diagnostics Logical Context (MDLC) is a dictionary of keys and values. + Stores the dictionary in the logical thread callcontext, and provides methods to output dictionary values in layouts. + Allows for maintaining state across asynchronous tasks and call contexts. + + + Ideally, these changes should be incorporated as a new version of the MappedDiagnosticsContext class in the original + NLog library so that state can be maintained for multiple threads in asynchronous situations. + + + + + Gets the current logical context named item, as . + + Item name. + The value of , if defined; otherwise . + If the value isn't a already, this call locks the for reading the needed for converting to . + + + + Gets the current logical context named item, as . + + Item name. + The to use when converting a value to a string. + The value of , if defined; otherwise . + If is null and the value isn't a already, this call locks the for reading the needed for converting to . + + + + Gets the current logical context named item, as . + + Item name. + The value of , if defined; otherwise null. + + + + Sets the current logical context item to the specified value. + + Item name. + Item value. + >An that can be used to remove the item from the current logical context. + + + + Sets the current logical context item to the specified value. + + Item name. + Item value. + >An that can be used to remove the item from the current logical context. + + + + Sets the current logical context item to the specified value. + + Item name. + Item value. + >An that can be used to remove the item from the current logical context. + + + + Updates the current logical context with multiple items in single operation + + . + >An that can be used to remove the item from the current logical context (null if no items). + + + + Sets the current logical context item to the specified value. + + Item name. + Item value. + + + + Sets the current logical context item to the specified value. + + Item name. + Item value. + + + + Sets the current logical context item to the specified value. + + Item name. + Item value. + + + + Returns all item names + + A collection of the names of all items in current logical context. + + + + Checks whether the specified exists in current logical context. + + Item name. + A boolean indicating whether the specified exists in current logical context. + + + + Removes the specified from current logical context. + + Item name. + + + + Clears the content of current logical context. + + + + + Clears the content of current logical context. + + Free the full slot. + + + + Obsolete and replaced by with NLog v5. + + Nested Diagnostics Context (NDC) is a stack of nested values. + Stores the stack in the thread-local static variable, and provides methods to output the values in layouts. + + + + + Gets the top NDC message but doesn't remove it. + + The top message. . + + + + Gets the top NDC object but doesn't remove it. + + The object at the top of the NDC stack if defined; otherwise null. + + + + Pushes the specified text on current thread NDC. + + The text to be pushed. + An instance of the object that implements IDisposable that returns the stack to the previous level when IDisposable.Dispose() is called. To be used with C# using() statement. + + + + Pushes the specified object on current thread NDC. + + The object to be pushed. + An instance of the object that implements IDisposable that returns the stack to the previous level when IDisposable.Dispose() is called. To be used with C# using() statement. + + + + Pops the top message off the NDC stack. + + The top message which is no longer on the stack. + + + + Pops the top message from the NDC stack. + + The to use when converting the value to a string. + The top message, which is removed from the stack, as a string value. + + + + Pops the top object off the NDC stack. + + The object from the top of the NDC stack, if defined; otherwise null. + + + + Peeks the first object on the NDC stack + + The object from the top of the NDC stack, if defined; otherwise null. + + + + Clears current thread NDC stack. + + + + + Gets all messages on the stack. + + Array of strings on the stack. + + + + Gets all messages from the stack, without removing them. + + The to use when converting a value to a string. + Array of strings. + + + + Gets all objects on the stack. + + Array of objects on the stack. + + + + Obsolete and replaced by with NLog v5. + + Nested Diagnostics Logical Context (NDLC) is a stack of nested values. + Stores the stack in the logical thread callcontexte, and provides methods to output the values in layouts. + + + + + Pushes the specified value on current stack + + The value to be pushed. + An instance of the object that implements IDisposable that returns the stack to the previous level when IDisposable.Dispose() is called. To be used with C# using() statement. + + + + Pushes the specified value on current stack + + The value to be pushed. + An instance of the object that implements IDisposable that returns the stack to the previous level when IDisposable.Dispose() is called. To be used with C# using() statement. + + + + Pops the top message off the NDLC stack. + + The top message which is no longer on the stack. + this methods returns a object instead of string, this because of backwards-compatibility + + + + Pops the top message from the NDLC stack. + + The to use when converting the value to a string. + The top message, which is removed from the stack, as a string value. + + + + Pops the top message off the current NDLC stack + + The object from the top of the NDLC stack, if defined; otherwise null. + + + + Peeks the top object on the current NDLC stack + + The object from the top of the NDLC stack, if defined; otherwise null. + + + + Clears current stack. + + + + + Gets all messages on the stack. + + Array of strings on the stack. + + + + Gets all messages from the stack, without removing them. + + The to use when converting a value to a string. + Array of strings. + + + + Gets all objects on the stack. The objects are not removed from the stack. + + Array of objects on the stack. + + + + stores state in the async thread execution context. All LogEvents created + within a scope can include the scope state in the target output. The logical context scope supports + both scope-properties and scope-nested-state-stack (Similar to log4j2 ThreadContext) + + + (MDLC), (MDC), (NDLC) + and (NDC) have been deprecated and replaced by . + + .NetCore (and .Net46) uses AsyncLocal for handling the thread execution context. Older .NetFramework uses System.Runtime.Remoting.CallContext + + + + + Pushes new state on the logical context scope stack together with provided properties + + Value to added to the scope stack + Properties being added to the scope dictionary + A disposable object that pops the nested scope state on dispose (including properties). + Scope dictionary keys are case-insensitive + + + + Updates the logical scope context with provided properties + + Properties being added to the scope dictionary + A disposable object that removes the properties from logical context scope on dispose. + Scope dictionary keys are case-insensitive + + + + Updates the logical scope context with provided properties + + Properties being added to the scope dictionary + A disposable object that removes the properties from logical context scope on dispose. + Scope dictionary keys are case-insensitive + + + + Updates the logical scope context with provided property + + Name of property + Value of property + A disposable object that removes the properties from logical context scope on dispose. + Scope dictionary keys are case-insensitive + + + + Updates the logical scope context with provided property + + Name of property + Value of property + A disposable object that removes the properties from logical context scope on dispose. + Scope dictionary keys are case-insensitive + + + + Pushes new state on the logical context scope stack + + Value to added to the scope stack + A disposable object that pops the nested scope state on dispose. + Skips casting of to check for scope-properties + + + + Pushes new state on the logical context scope stack + + Value to added to the scope stack + A disposable object that pops the nested scope state on dispose. + + + + Clears all the entire logical context scope, and removes any properties and nested-states + + + + + Retrieves all properties stored within the logical context scopes + + Collection of all properties + + + + Lookup single property stored within the logical context scopes + + Name of property + When this method returns, contains the value associated with the specified key + Returns true when value is found with the specified key + Scope dictionary keys are case-insensitive + + + + Retrieves all nested states inside the logical context scope stack + + Array of nested state objects. + + + + Peeks the top value from the logical context scope stack + + Value from the top of the stack. + + + + Peeks the inner state (newest) from the logical context scope stack, and returns its running duration + + Scope Duration Time + + + + Peeks the outer state (oldest) from the logical context scope stack, and returns its running duration + + Scope Duration Time + + + + Special bookmark that can restore original parent, after scopes has been collapsed + + + + + Matches when the specified condition is met. + + + Conditions are expressed using a simple language. + + Documentation on NLog Wiki + + + + Gets or sets the condition expression. + + + + + + + + + An abstract filter class. Provides a way to eliminate log messages + based on properties other than logger name and log level. + + + + + Initializes a new instance of the class. + + + + + Gets or sets the action to be taken when filter matches. + + + + + + Gets the result of evaluating filter against given log event. + + The log event. + Filter result. + + + + Checks whether log event should be logged or not. + + Log event. + + - if the log event should be ignored
+ - if the filter doesn't want to decide
+ - if the log event should be logged
+ .
+
+ + + Marks class as a layout renderer and assigns a name to it. + + + + + Initializes a new instance of the class. + + Name of the filter. + + + + Filter result. + + + + + The filter doesn't want to decide whether to log or discard the message. + + + + + The message should be logged. + + + + + The message should not be logged. + + + + + The message should be logged and processing should be finished. + + + + + The message should not be logged and processing should be finished. + + + + + A base class for filters that are based on comparing a value to a layout. + + + + + Initializes a new instance of the class. + + + + + Gets or sets the layout to be used to filter log messages. + + The layout. + + + + + Matches when the calculated layout contains the specified substring. + This filter is deprecated in favor of <when /> which is based on conditions. + + + + + Gets or sets a value indicating whether to ignore case when comparing strings. + + + + + + Gets or sets the substring to be matched. + + + + + + + + + Matches when the calculated layout is equal to the specified substring. + This filter is deprecated in favor of <when /> which is based on conditions. + + + + + Gets or sets a value indicating whether to ignore case when comparing strings. + + + + + + Gets or sets a string to compare the layout to. + + + + + + + + + Matches the provided filter-method + + + + + Initializes a new instance of the class. + + + + + + + + Matches when the calculated layout does NOT contain the specified substring. + This filter is deprecated in favor of <when /> which is based on conditions. + + + + + Gets or sets the substring to be matched. + + + + + + Gets or sets a value indicating whether to ignore case when comparing strings. + + + + + + + + + Matches when the calculated layout is NOT equal to the specified substring. + This filter is deprecated in favor of <when /> which is based on conditions. + + + + + Initializes a new instance of the class. + + + + + Gets or sets a string to compare the layout to. + + + + + + Gets or sets a value indicating whether to ignore case when comparing strings. + + + + + + + + + Matches when the result of the calculated layout has been repeated a moment ago + + + + + How long before a filter expires, and logging is accepted again + + + + + + Max length of filter values, will truncate if above limit + + + + + + Applies the configured action to the initial logevent that starts the timeout period. + Used to configure that it should ignore all events until timeout. + + + + + + Max number of unique filter values to expect simultaneously + + + + + + Default number of unique filter values to expect, will automatically increase if needed + + + + + + Insert FilterCount value into when an event is no longer filtered + + + + + + Append FilterCount to the when an event is no longer filtered + + + + + + Reuse internal buffers, and doesn't have to constantly allocate new buffers + + + + + + Default buffer size for the internal buffers + + + + + + Checks whether log event should be logged or not. In case the LogEvent has just been repeated. + + Log event. + + - if the log event should be ignored
+ - if the filter doesn't want to decide
+ - if the log event should be logged
+ .
+
+ + + Uses object pooling, and prunes stale filter items when the pool runs dry + + + + + Remove stale filter-value from the cache, and fill them into the pool for reuse + + + + + Renders the Log Event into a filter value, that is used for checking if just repeated + + + + + Repeated LogEvent detected. Checks if it should activate filter-action + + + + + Filter Value State (mutable) + + + + + Filter Lookup Key (immutable) + + + + + A global logging class using caller info to find the logger. + + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event with the specified . + + The log level. + The full path of the source file that contains the caller. This is the file path at the time of compile. + An instance of the fluent . + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Trace level. + + The full path of the source file that contains the caller. This is the file path at the time of compile. + An instance of the fluent . + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Debug level. + + The full path of the source file that contains the caller. This is the file path at the time of compile. + An instance of the fluent . + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Info level. + + The full path of the source file that contains the caller. This is the file path at the time of compile. + An instance of the fluent . + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Warn level. + + The full path of the source file that contains the caller. This is the file path at the time of compile. + An instance of the fluent . + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Error level. + + The full path of the source file that contains the caller. This is the file path at the time of compile. + An instance of the fluent . + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Fatal level. + + The full path of the source file that contains the caller. This is the file path at the time of compile. + An instance of the fluent . + + + + Obsolete and replaced by with NLog v5. + + A fluent class to build log events for NLog. + + + + + Initializes a new instance of the class. + + The to send the log event. + + + + Initializes a new instance of the class. + + The to send the log event. + The for the log event. + + + + Gets the created by the builder. + + + + + Sets the information of the logging event. + + The exception information of the logging event. + current for chaining calls. + + + + Sets the level of the logging event. + + The level of the logging event. + current for chaining calls. + + + + Sets the logger name of the logging event. + + The logger name of the logging event. + current for chaining calls. + + + + Sets the log message on the logging event. + + The log message for the logging event. + current for chaining calls. + + + + Sets the log message and parameters for formatting on the logging event. + + A composite format string. + The object to format. + current for chaining calls. + + + + Sets the log message and parameters for formatting on the logging event. + + A composite format string. + The first object to format. + The second object to format. + current for chaining calls. + + + + Sets the log message and parameters for formatting on the logging event. + + A composite format string. + The first object to format. + The second object to format. + The third object to format. + current for chaining calls. + + + + Sets the log message and parameters for formatting on the logging event. + + A composite format string. + The first object to format. + The second object to format. + The third object to format. + The fourth object to format. + current for chaining calls. + + + + Sets the log message and parameters for formatting on the logging event. + + A composite format string. + An object array that contains zero or more objects to format. + current for chaining calls. + + + + Sets the log message and parameters for formatting on the logging event. + + An object that supplies culture-specific formatting information. + A composite format string. + An object array that contains zero or more objects to format. + current for chaining calls. + + + + Sets a per-event context property on the logging event. + + The name of the context property. + The value of the context property. + current for chaining calls. + + + + Sets multiple per-event context properties on the logging event. + + The properties to set. + current for chaining calls. + + + + Sets the timestamp of the logging event. + + The timestamp of the logging event. + current for chaining calls. + + + + Sets the stack trace for the event info. + + The stack trace. + Index of the first user stack frame within the stack trace. + current for chaining calls. + + + + Writes the log event to the underlying logger. + + The method or property name of the caller to the method. This is set at by the compiler. + The full path of the source file that contains the caller. This is set at by the compiler. + The line number in the source file at which the method is called. This is set at by the compiler. + + + + Writes the log event to the underlying logger if the condition delegate is true. + + If condition is true, write log event; otherwise ignore event. + The method or property name of the caller to the method. This is set at by the compiler. + The full path of the source file that contains the caller. This is set at by the compiler. + The line number in the source file at which the method is called. This is set at by the compiler. + + + + Writes the log event to the underlying logger if the condition is true. + + If condition is true, write log event; otherwise ignore event. + The method or property name of the caller to the method. This is set at by the compiler. + The full path of the source file that contains the caller. This is set at by the compiler. + The line number in the source file at which the method is called. This is set at by the compiler. + + + + Extension methods for NLog . + + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event with the specified . + + The logger to write the log event to. + The log level. + current for chaining calls. + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Trace level. + + The logger to write the log event to. + current for chaining calls. + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Debug level. + + The logger to write the log event to. + current for chaining calls. + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Info level. + + The logger to write the log event to. + current for chaining calls. + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Warn level. + + The logger to write the log event to. + current for chaining calls. + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Error level. + + The logger to write the log event to. + current for chaining calls. + + + + Obsolete and replaced by with NLog v5. + + Starts building a log event at the Fatal level. + + The logger to write the log event to. + current for chaining calls. + + + + Extensions for NLog . + + + + + Starts building a log event with the specified . + + The logger to write the log event to. + The log level. When not + for chaining calls. + + + + Starts building a log event at the Trace level. + + The logger to write the log event to. + for chaining calls. + + + + Starts building a log event at the Debug level. + + The logger to write the log event to. + for chaining calls. + + + + Starts building a log event at the Info level. + + The logger to write the log event to. + for chaining calls. + + + + Starts building a log event at the Warn level. + + The logger to write the log event to. + for chaining calls. + + + + Starts building a log event at the Error level. + + The logger to write the log event to. + for chaining calls. + + + + Starts building a log event at the Fatal level. + + The logger to write the log event to. + for chaining calls. + + + + Starts building a log event at the Exception level. + + The logger to write the log event to. + The exception information of the logging event. + The for the log event. Defaults to when not specified. + for chaining calls. + + + + Writes the diagnostic message at the Debug level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + Type of the value. + A logger implementation that will handle the message. + The value to be written. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + Type of the value. + A logger implementation that will handle the message. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message and exception at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + An exception to be logged. + A to be written. + Arguments to format. + + + + Writes the diagnostic message and exception at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + An exception to be logged. + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + Arguments to format. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + Log message. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Debug level using the specified parameter. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the argument. + A logger implementation that will handle the message. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + A logger implementation that will handle the message. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + The type of the third argument. + A logger implementation that will handle the message. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Debug level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + Type of the value. + A logger implementation that will handle the message. + The value to be written. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + Type of the value. + A logger implementation that will handle the message. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message and exception at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + An exception to be logged. + A to be written. + Arguments to format. + + + + Writes the diagnostic message and exception at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + An exception to be logged. + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + Arguments to format. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + Log message. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + A logger implementation that will handle the message. + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Debug level using the specified parameter. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the argument. + A logger implementation that will handle the message. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + A logger implementation that will handle the message. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + The type of the third argument. + A logger implementation that will handle the message. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message and exception at the specified level. + + A logger implementation that will handle the message. + The log level. + An exception to be logged. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message and exception at the Trace level. + + A logger implementation that will handle the message. + An exception to be logged. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message and exception at the Debug level. + + A logger implementation that will handle the message. + An exception to be logged. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message and exception at the Info level. + + A logger implementation that will handle the message. + An exception to be logged. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message and exception at the Warn level. + + A logger implementation that will handle the message. + An exception to be logged. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message and exception at the Error level. + + A logger implementation that will handle the message. + An exception to be logged. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message and exception at the Fatal level. + + A logger implementation that will handle the message. + An exception to be logged. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Interface for fakeable of the current AppDomain. + + + + + Gets or sets the base directory that the assembly resolver uses to probe for assemblies. + + + + + Gets or sets the name of the configuration file for an application domain. + + + + + Gets or sets the list of directories under the application base directory that are probed for private assemblies. + + + + + Gets or set the friendly name. + + + + + Gets an integer that uniquely identifies the application domain within the process. + + + + + Gets the assemblies that have been loaded into the execution context of this application domain. + + A list of assemblies in this application domain. + + + + Process exit event. + + + + + Domain unloaded event. + + + + + Abstract calls for the application environment + + + + + Gets current process name (excluding filename extension, if any). + + + + + Process exit event. + + + + + Abstract calls to FileSystem + + + + Determines whether the specified file exists. + The file to check. + + + Returns the content of the specified file + The file to load. + + + + Adapter for to + + + + + Initializes a new instance of the class. + + The to wrap. + + + + Creates an AppDomainWrapper for the current + + + + + Gets or sets the base directory that the assembly resolver uses to probe for assemblies. + + + + + Gets or sets the name of the configuration file for an application domain. + + + + + Gets or sets the list of directories under the application base directory that are probed for private assemblies. + + + + + Gets or set the friendly name. + + + + + Gets an integer that uniquely identifies the application domain within the process. + + + + + Gets the assemblies that have been loaded into the execution context of this application domain. + + A list of assemblies in this application domain. + + + + Process exit event. + + + + + Domain unloaded event. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Format a log message + + + + + Perform message template parsing and formatting of LogEvent messages (True = Always, False = Never, Null = Auto Detect) + + + + + Format the message and return + + LogEvent with message to be formatted + formatted message + + + + Has the logevent properties? + + LogEvent with message to be formatted + False when logevent has no properties to be extracted + + + + Appends the logevent message to the provided StringBuilder + + LogEvent with message to be formatted + The to append the formatted message. + + + + Get the Raw, unformatted value without stringify + + + Implementors must has the [ThreadAgnostic] attribute + + + + + Get the raw value + + + The value + RawValue supported? + + + + Interface implemented by layouts and layout renderers. + + + + + Renders the value of layout or layout renderer in the context of the specified log event. + + The log event. + String representation of a layout. + + + + Supports rendering as string value with limited or no allocations (preferred) + + + Implementors must not have the [AppDomainFixedOutput] attribute + + + + + Renders the value of layout renderer in the context of the specified log event + + + null if not possible or unknown + + + + Supports object initialization and termination. + + + + + Initializes this instance. + + The configuration. + + + + Closes this instance. + + + + + Helpers for . + + + + + Gets all usable exported types from the given assembly. + + Assembly to scan. + Usable types from the given assembly. + Types which cannot be loaded are skipped. + + + + Forward declare of system delegate type for use by other classes + + + + + Keeps track of pending operation count, and can notify when pending operation count reaches zero + + + + + Mark operation has started + + + + + Mark operation has completed + + Exception coming from the completed operation [optional] + + + + Registers an AsyncContinuation to be called when all pending operations have completed + + Invoked on completion + AsyncContinuation operation + + + + Clear o + + + + + Sets the stack trace for the event info. + + The stack trace. + Index of the first user stack frame within the stack trace. + Type of the logger or logger wrapper. This is still Logger if it's a subclass of Logger. + + + + Sets the details retrieved from the Caller Information Attributes + + + + + + + + + Gets the stack frame of the method that did the logging. + + + + + Gets the number index of the stack frame that represents the user + code (not the NLog code). + + + + + Legacy attempt to skip async MoveNext, but caused source file line number to be lost + + + + + Gets the entire stack trace. + + + + + Finds first user stack frame in a stack trace + + The stack trace of the logging method invocation + Type of the logger or logger wrapper. This is still Logger if it's a subclass of Logger. + Index of the first user stack frame or 0 if all stack frames are non-user + + + + This is only done for legacy reason, as the correct method-name and line-number should be extracted from the MoveNext-StackFrame + + The stack trace of the logging method invocation + Starting point for skipping async MoveNext-frames + + + + Assembly to skip? + + Find assembly via this frame. + true, we should skip. + + + + Is this the type of the logger? + + get type of this logger in this frame. + Type of the logger. + + + + + Memory optimized filtering + + Passing state too avoid delegate capture and memory-allocations. + + + + Ensures that IDictionary.GetEnumerator returns DictionaryEntry values + + + + + Most-Recently-Used-Cache, that discards less frequently used items on overflow + + + + + Constructor + + Maximum number of items the cache will hold before discarding. + + + + Attempt to insert item into cache. + + Key of the item to be inserted in the cache. + Value of the item to be inserted in the cache. + true when the key does not already exist in the cache, false otherwise. + + + + Lookup existing item in cache. + + Key of the item to be searched in the cache. + Output value of the item found in the cache. + True when the key is found in the cache, false otherwise. + + + + Dictionary that combines the standard with the + MessageTemplate-properties extracted from the . + + The are returned as the first items + in the collection, and in positional order. + + + + + Value of the property + + + + + Has property been captured from message-template ? + + + + + The properties of the logEvent + + + + + The properties extracted from the message-template + + + + + Wraps the list of message-template-parameters as IDictionary-interface + + Message-template-parameters + + + + Transforms the list of event-properties into IDictionary-interface + + Message-template-parameters + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Check if the message-template-parameters can be used directly without allocating a dictionary + + Message-template-parameters + Are all parameter names unique (true / false) + + + + Attempt to insert the message-template-parameters into an empty dictionary + + Message-template-parameters + The dictionary that initially contains no message-template-parameters + + + + + + + + + + + + + + + + + + + + + Will always throw, as collection is readonly + + + Will always throw, as collection is readonly + + + Will always throw, as collection is readonly + + + + + + + + + + + + + + + + + + + Special property-key for lookup without being case-sensitive + + + + + Property-Key equality-comparer that uses string-hashcode from OrdinalIgnoreCase + Enables case-insensitive lookup using + + + + + HashSet optimized for single item + + + + + + Insert single item on scope start, and remove on scope exit + + Item to insert in scope + Existing hashset to update + Force allocation of real hashset-container + HashSet EqualityComparer + + + + Add item to collection, if it not already exists + + Item to insert + + + + Clear hashset + + + + + Check if hashset contains item + + + Item exists in hashset (true/false) + + + + Remove item from hashset + + + Item removed from hashset (true/false) + + + + Copy items in hashset to array + + Destination array + Array offset + + + + Create hashset enumerator + + Enumerator + + + + Provides helpers to sort log events and associated continuations. + + + + + Key selector delegate. + + The type of the value. + The type of the key. + Value to extract key information from. + Key selected from log event. + + + + Performs bucket sort (group by) on an array of items and returns a dictionary for easy traversal of the result set. + + The type of the value. + The type of the key. + The inputs. + The key selector function. + + Dictionary where keys are unique input keys, and values are lists of . + + + + + Performs bucket sort (group by) on an array of items and returns a dictionary for easy traversal of the result set. + + The type of the value. + The type of the key. + The inputs. + The key selector function. + + Dictionary where keys are unique input keys, and values are lists of . + + + + + Performs bucket sort (group by) on an array of items and returns a dictionary for easy traversal of the result set. + + The type of the value. + The type of the key. + The inputs. + The key selector function. + The key comparer function. + + Dictionary where keys are unique input keys, and values are lists of . + + + + + Single-Bucket optimized readonly dictionary. Uses normal internally Dictionary if multiple buckets are needed. + + Avoids allocating a new dictionary, when all items are using the same bucket + + The type of the key. + The type of the value. + + + + + + + + + + + + + + + + Allows direct lookup of existing keys. If trying to access non-existing key exception is thrown. + Consider to use instead for better safety. + + Key value for lookup + Mapped value found + + + + Non-Allocating struct-enumerator + + + + + + + + + + + + + Will always throw, as dictionary is readonly + + + Will always throw, as dictionary is readonly + + + + + + Will always throw, as dictionary is readonly + + + Will always throw, as dictionary is readonly + + + + + + + + + Will always throw, as dictionary is readonly + + + + UTF-8 BOM 239, 187, 191 + + + + + Safe way to get environment variables. + + + + + Helper class for dealing with exceptions. + + + + + Mark this exception as logged to the . + + + + + + + Is this exception logged to the ? + + + trueif the has been logged to the . + + + + Determines whether the exception must be rethrown and logs the error to the if is false. + + Advised to log first the error to the before calling this method. + + The exception to check. + Target Object context of the exception. + Target Method context of the exception. + trueif the must be rethrown, false otherwise. + + + + Determines whether the exception must be rethrown immediately, without logging the error to the . + + Only used this method in special cases. + + The exception to check. + trueif the must be rethrown, false otherwise. + + + + FormatProvider that renders an exception-object as $"{ex.GetType()}: {ex.Message}" + + + + + Object construction helper. + + + + + Base class for optimized file appenders. + + + + + Initializes a new instance of the class. + + Name of the file. + The create parameters. + + + + Gets the path of the file, including file extension. + + The name of the file. + + + + Gets or sets the creation time for a file associated with the appender. The time returned is in Coordinated + Universal Time [UTC] standard. + + The creation time of the file. + + + + Gets or sets the creation time for a file associated with the appender. Synchronized by + The time format is based on + + + + + Gets the last time the file associated with the appender is opened. The time returned is in Coordinated + Universal Time [UTC] standard. + + The time the file was last opened. + + + + Gets the file creation parameters. + + The file creation parameters. + + + + Writes the specified bytes. + + The bytes. + + + + Writes the specified bytes to a file. + + The bytes array. + The bytes array offset. + The number of bytes. + + + + Flushes this file-appender instance. + + + + + Closes this file-appender instance. + + + + + Gets the creation time for a file associated with the appender. The time returned is in Coordinated Universal + Time [UTC] standard. + + The file creation time. + + + + Gets the length in bytes of the file associated with the appender. + + A long value representing the length of the file in bytes. + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources. + + True to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Creates the file stream. + + If set to true sets the file stream to allow shared writing. + If larger than 0 then it will be used instead of the default BufferSize for the FileStream. + A object which can be used to write to the file. + + + + Base class for optimized file appenders which require the usage of a mutex. + + It is possible to use this class as replacement of BaseFileAppender and the mutex functionality + is not enforced to the implementing subclasses. + + + + + Initializes a new instance of the class. + + Name of the file. + The create parameters. + + + + Gets the mutually-exclusive lock for archiving files. + + The mutex for archiving. + + + + + + + Creates a mutex that is sharable by more than one process. + + The prefix to use for the name of the mutex. + A object which is sharable by multiple processes. + + + + Implementation of which caches + file information. + + + + + Initializes a new instance of the class. + + Name of the file. + The parameters. + + + + + + + + + + + + + + + + + + + Factory class which creates objects. + + + + + + + + Maintains a collection of file appenders usually associated with file targets. + + + + + An "empty" instance of the class with zero size and empty list of appenders. + + + + + Initializes a new "empty" instance of the class with zero size and empty + list of appenders. + + + + + Initializes a new instance of the class. + + + The size of the list should be positive. No validations are performed during initialization as it is an + internal class. + + Total number of appenders allowed in list. + Factory used to create each appender. + Parameters used for creating a file. + + + + The archive file path pattern that is used to detect when archiving occurs. + + + + + Invalidates appenders for all files that were archived. + + + + + Gets the parameters which will be used for creating a file. + + + + + Gets the file appender factory used by all the appenders in this list. + + + + + Gets the number of appenders which the list can hold. + + + + + Subscribe to background monitoring of active file appenders + + + + + It allocates the first slot in the list when the file name does not already in the list and clean up any + unused slots. + + File name associated with a single appender. + The allocated appender. + + + + Close all the allocated appenders. + + + + + Close the allocated appenders initialized before the supplied time. + + The time which prior the appenders considered expired + + + + Flush all the allocated appenders. + + + + + File Archive Logic uses the File-Creation-TimeStamp to detect if time to archive, and the File-LastWrite-Timestamp to name the archive-file. + + + NLog always closes all relevant appenders during archive operation, so no need to lookup file-appender + + + + + Closes the specified appender and removes it from the list. + + File name of the appender to be closed. + File Appender that matched the filePath (null if none found) + + + + Interface that provides parameters for create file function. + + + + + Gets or sets the delay in milliseconds to wait before attempting to write to the file again. + + + + + Gets or sets the number of times the write is appended on the file before NLog + discards the log message. + + + + + Gets or sets a value indicating whether concurrent writes to the log file by multiple processes on the same host. + + + This makes multi-process logging possible. NLog uses a special technique + that lets it keep the files open for writing. + + + + + Gets or sets a value indicating whether to create directories if they do not exist. + + + Setting this to false may improve performance a bit, but you'll receive an error + when attempting to write to a directory that's not present. + + + + + Gets or sets a value indicating whether to enable log file(s) to be deleted. + + + + + Gets or sets the log file buffer size in bytes. + + + + + Gets or set a value indicating whether a managed file stream is forced, instead of using the native implementation. + + + + + Gets or sets the file attributes (Windows only). + + + + + Should archive mutex be created? + + + + + Should manual simple detection of file deletion be enabled? + + + + + Gets the parameters which will be used for creating a file. + + + + + Gets the file appender factory used by all the appenders in this list. + + + + + Gets the number of appenders which the list can hold. + + + + + Subscribe to background monitoring of active file appenders + + + + + It allocates the first slot in the list when the file name does not already in the list and clean up any + unused slots. + + File name associated with a single appender. + The allocated appender. + + + + Close all the allocated appenders. + + + + + Close the allocated appenders initialized before the supplied time. + + The time which prior the appenders considered expired + + + + Flush all the allocated appenders. + + + + + File Archive Logic uses the File-Creation-TimeStamp to detect if time to archive, and the File-LastWrite-Timestamp to name the archive-file. + + + NLog always closes all relevant appenders during archive operation, so no need to lookup file-appender + + + + + Closes the specified appender and removes it from the list. + + File name of the appender to be closed. + File Appender that matched the filePath (null if none found) + + + + The archive file path pattern that is used to detect when archiving occurs. + + + + + Invalidates appenders for all files that were archived. + + + + + Interface implemented by all factories capable of creating file appenders. + + + + + Opens the appender for given file name and parameters. + + Name of the file. + Creation parameters. + Instance of which can be used to write to the file. + + + + Provides a multi process-safe atomic file appends while + keeping the files open. + + + On Unix you can get all the appends to be atomic, even when multiple + processes are trying to write to the same file, because setting the file + pointer to the end of the file and appending can be made one operation. + On Win32 we need to maintain some synchronization between processes + (global named mutex is used for this) + + + + + Initializes a new instance of the class. + + Name of the file. + The parameters. + + + + + + + + + + + + + + + + + + + Factory class. + + + + + + + + Appender used to discard data for the FileTarget. + Used mostly for testing entire stack except the actual writing to disk. + Throws away all data. + + + + + Factory class. + + + + + + + + Multi-process and multi-host file appender which attempts + to get exclusive write access and retries if it's not available. + + + + + Initializes a new instance of the class. + + Name of the file. + The parameters. + + + + + + + + + + + + + + + + + + + Factory class. + + + + + + + + Optimized single-process file appender which keeps the file open for exclusive write. + + + + + Initializes a new instance of the class. + + Name of the file. + The parameters. + + + + + + + + + + + + + + + + + + + Factory class. + + + + + + + + A layout that represents a filePath. + + + + + Cached directory separator char array to avoid memory allocation on each method call. + + + + + Cached invalid file names char array to avoid memory allocation every time Path.GetInvalidFileNameChars() is called. + + + + + not null when == false + + + + + non null is fixed, + + + + + is the cache-key, and when newly rendered filename matches the cache-key, + then it reuses the cleaned cache-value . + + + + + is the cache-value that is reused, when the newly rendered filename + matches the cache-key + + + + Initializes a new instance of the class. + + + + Render the raw filename from Layout + + The log event. + StringBuilder to minimize allocations [optional]. + String representation of a layout. + + + + Convert the raw filename to a correct filename + + The filename generated by Layout. + String representation of a correct filename. + + + + Is this (templated/invalid) path an absolute, relative or unknown? + + + + + Watches multiple files at the same time and raises an event whenever + a single change is detected in any of those files. + + + + + The types of changes to watch for. + + + + + Occurs when a change is detected in one of the monitored files. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Stops watching all files. + + + + + Stops watching the specified file. + + + + + + Watches the specified files for changes. + + The file names. + + + + Combine paths + + basepath, not null + optional dir + optional file + + + + + Cached directory separator char array to avoid memory allocation on each method call. + + + + + Trims directory separators from the path + + path, could be null + never null + + + + Convert object to string + + value + format for conversion. + + + If is null and isn't a already, then the will get a locked by + + + + + Retrieve network interfaces + + + + + Retrieve network interfaces + + + + + Supports mocking of SMTP Client code. + + + + + Specifies how outgoing email messages will be handled. + + + + + Gets or sets the name or IP address of the host used for SMTP transactions. + + + + + Gets or sets the port used for SMTP transactions. + + + + + Gets or sets a value that specifies the amount of time after which a synchronous Send call times out. + + + + + Gets or sets the credentials used to authenticate the sender. + + + + + Sends an e-mail message to an SMTP server for delivery. These methods block while the message is being transmitted. + + + System.Net.Mail.MailMessage + MailMessage + A MailMessage that contains the message to send. + + + + Gets or sets the folder where applications save mail messages to be processed by the local SMTP server. + + + + + The MessageFormatter delegate + + + + + When true: Do not fallback to StringBuilder.Format for positional templates + + + + + New formatter + + + When true: Do not fallback to StringBuilder.Format for positional templates + + + + + The MessageFormatter delegate + + + + + + + + Render a template to a string. + + The template. + Culture. + Parameters for the holes. + The String Builder destination. + Parameters for the holes. + + + + Detects the platform the NLog is running on. + + + + + Gets a value indicating whether current runtime supports use of mutex + + + + + Will creating a mutex succeed runtime? + + + + + Supports mocking of SMTP Client code. + + + Disabled Error CS0618 'SmtpClient' is obsolete: 'SmtpClient and its network of types are poorly designed, + we strongly recommend you use https://github.com/jstedfast/MailKit and https://github.com/jstedfast/MimeKit instead' + + + + + Retrieve network interfaces + + + + + Retrieve network interfaces + + + + + Network sender which uses HTTP or HTTPS POST. + + + + + Initializes a new instance of the class. + + The network URL. + + + + Creates instances of objects for given URLs. + + + + + Creates a new instance of the network sender based on a network URL. + + URL that determines the network sender to be created. + The maximum queue size. + The overflow action when reaching maximum queue size. + The maximum message size. + SSL protocols for TCP + KeepAliveTime for TCP + + A newly created network sender. + + + + + Interface for mocking socket calls. + + + + + A base class for all network senders. Supports one-way sending of messages + over various protocols. + + + + + Initializes a new instance of the class. + + The network URL. + + + + Gets the address of the network endpoint. + + + + + Gets the last send time. + + + + + Initializes this network sender. + + + + + Closes the sender and releases any unmanaged resources. + + The continuation. + + + + Flushes any pending messages and invokes the on completion. + + The continuation. + + + + Send the given text over the specified protocol. + + Bytes to be sent. + Offset in buffer. + Number of bytes to send. + The asynchronous continuation. + + + + Closes the sender and releases any unmanaged resources. + + + + + Initializes resources for the protocol specific implementation. + + + + + Closes resources for the protocol specific implementation. + + The continuation. + + + + Performs the flush and invokes the on completion. + + The continuation. + + + + Sends the payload using the protocol specific implementation. + + The bytes to be sent. + Offset in buffer. + Number of bytes to send. + The async continuation to be invoked after the buffer has been sent. + + + + Parses the URI into an IP address. + + The URI to parse. + The address family. + Parsed endpoint. + + + + Default implementation of . + + + + + + + + A base class for network senders that can block or send out-of-order + + + + + Initializes a new instance of the class. + + URL. Must start with tcp://. + + + + Socket proxy for mocking Socket code. + + + + + Initializes a new instance of the class. + + The address family. + Type of the socket. + Type of the protocol. + + + + Gets underlying socket instance. + + + + + Closes the wrapped socket. + + + + + Invokes ConnectAsync method on the wrapped socket. + + The instance containing the event data. + Result of original method. + + + + Invokes SendAsync method on the wrapped socket. + + The instance containing the event data. + Result of original method. + + + + Invokes SendToAsync method on the wrapped socket. + + The instance containing the event data. + Result of original method. + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Sends messages over a TCP network connection. + + + + + Initializes a new instance of the class. + + URL. Must start with tcp://. + The address family. + + + + Creates the socket with given parameters. + + The host address. + The address family. + Type of the socket. + Type of the protocol. + Instance of which represents the socket. + + + + Facilitates mocking of class. + + + + + Raises the Completed event. + + + + + Sends messages over the network as UDP datagrams. + + + + + Initializes a new instance of the class. + + URL. Must start with udp://. + The address family. + + + + Creates the socket. + + The IP address. + Implementation of to use. + + + + Allocates new builder and appends to the provided target builder on dispose + + + + + Access the new builder allocated + + + + + Controls a single allocated AsyncLogEventInfo-List for reuse (only one active user) + + + + + Controls a single allocated char[]-buffer for reuse (only one active user) + + + + + Controls a single allocated StringBuilder for reuse (only one active user) + + + + + Controls a single allocated object for reuse (only one active user) + + + + + Creates handle to the reusable char[]-buffer for active usage + + Handle to the reusable item, that can release it again + + + + Access the acquired reusable object + + + + + Controls a single allocated MemoryStream for reuse (only one active user) + + + + + Constructor + + Max number of items + Initial StringBuilder Size + Max StringBuilder Size + + + + Takes StringBuilder from pool + + Allow return to pool + + + + Releases StringBuilder back to pool at its right place + + + + + Keeps track of acquired pool item + + + + + Releases pool item back into pool + + + + + Detects the platform the NLog is running on. + + + + + Gets the current runtime OS. + + + + + Gets a value indicating whether current OS is Win32-based (desktop or mobile). + + + + + Gets a value indicating whether current OS is Unix-based. + + + + + Scans (breadth-first) the object graph following all the edges whose are + instances have attached and returns + all objects implementing a specified interfaces. + + + + + Finds the objects which have attached which are reachable + from any of the given root objects when traversing the object graph over public properties. + + Type of the objects to return. + Configuration Reflection Helper + Also search the properties of the wanted objects. + The root objects. + Ordered list of objects implementing T. + + + + Object Path to check + + + + + Converts object into a List of property-names and -values using reflection + + + + + Try get value from , using , and set into + + + + + Scans properties for name (Skips string-compare and value-lookup until finding match) + + + + + Scans properties for name (Skips property value lookup until finding match) + + + + + Scans properties for name + + + + + Binder for retrieving value of + + + + + + + + Reflection helpers for accessing properties. + + + + + Get property info + + Configuration Reflection Helper + object which could have property + property name on + result when success. + success. + + + + Try parse of string to (Generic) list, comma separated. + + + If there is a comma in the value, then (single) quote the value. For single quotes, use the backslash as escape + + + + + Attempt to reuse the HashSet.Comparer from the original HashSet-object (Ex. StringComparer.OrdinalIgnoreCase) + + + + + Reflection helpers. + + + + + Is this a static class? + + + + This is a work around, as Type doesn't have this property. + From: https://stackoverflow.com/questions/1175888/determine-if-a-type-is-static + + + + + Optimized delegate for calling MethodInfo + + Object instance, use null for static methods. + Complete list of parameters that matches the method, including optional/default parameters. + + + + Optimized delegate for calling a constructor + + Complete list of parameters that matches the constructor, including optional/default parameters. Could be null for no parameters. + + + + Creates an optimized delegate for calling the MethodInfo using Expression-Trees + + Method to optimize + Optimized delegate for invoking the MethodInfo + + + + Creates an optimized delegate for calling the constructors using Expression-Trees + + Constructor to optimize + Optimized delegate for invoking the constructor + + + + Compile the ? This can improve the performance, but at the costs of more memory usage. If false, the Regex Cache is used. + + + + + Gets or sets a value indicating whether to match whole words only. + + + + + Gets or sets a value indicating whether to ignore case when comparing texts. + + + + + Supported operating systems. + + + If you add anything here, make sure to add the appropriate detection + code to + + + + + Unknown operating system. + + + + + Unix/Linux operating systems. + + + + + Desktop versions of Windows (95,98,ME). + + + + + Windows NT, 2000, 2003 and future versions based on NT technology. + + + + + Macintosh Mac OSX + + + + + Immutable state that combines ScopeContext MDLC + NDLC for + + + + + Immutable state that combines ScopeContext MDLC + NDLC for + + + + + Immutable state for ScopeContext Mapped Context (MDLC) + + + + + Immutable state for ScopeContext Nested State (NDLC) + + + + + Immutable state for ScopeContext Single Property (MDLC) + + + + + Immutable state for ScopeContext Multiple Properties (MDLC) + + + + + Immutable state for ScopeContext handling legacy MDLC + NDLC operations + + + + + + + + + + + + + + Collection of targets that should be written to + + + + + Implements a single-call guard around given continuation function. + + + + + Initializes a new instance of the class. + + The asynchronous continuation. + + + + Continuation function which implements the single-call guard. + + The exception. + + + + Utilities for dealing with values. + + + + + Gets the fully qualified name of the class invoking the calling method, including the + namespace but not the assembly. + + + + + Gets the fully qualified name of the class invoking the calling method, including the + namespace but not the assembly. + + StackFrame from the calling method + Fully qualified class name + + + + Returns the assembly from the provided StackFrame (If not internal assembly) + + Valid assembly, or null if assembly was internal + + + + Returns the classname from the provided StackFrame (If not from internal assembly) + + + Valid class name, or empty string if assembly was internal + + + + Stream helpers + + + + + Copy to output stream and skip BOM if encoding is UTF8 + + + + + + + + Copy stream input to output. Skip the first bytes + + stream to read from + stream to write to + .net35 doesn't have a .copyto + + + + Copy stream input to output. Skip the first bytes + + stream to read from + stream to write to + first bytes to skip (optional) + + + + Simple character tokenizer. + + + + + Initializes a new instance of the class. + + The text to be tokenized. + + + + Current position in + + + + + Full text to be parsed + + + + + Check current char while not changing the position. + + + + + + Read the current char and change position + + + + + + Get the substring of the + + + + + + + + Helpers for , which is used in e.g. layout renderers. + + + + + Renders the specified log event context item and appends it to the specified . + + append to this + value to be appended + format string. If @, then serialize the value with the Default JsonConverter. + provider, for example culture + NLog string.Format interface + + + + Appends int without using culture, and most importantly without garbage + + + value to append + + + + Appends uint without using culture, and most importantly without garbage + + Credits Gavin Pugh - https://www.gavpugh.com/2010/04/01/xnac-avoiding-garbage-when-working-with-stringbuilder/ + + + value to append + + + + Convert DateTime into UTC and format to yyyy-MM-ddTHH:mm:ss.fffffffZ - ISO 8601 Compliant Date Format (Round-Trip-Time) + + + + + Clears the provider StringBuilder + + + + + + Copies the contents of the StringBuilder to the MemoryStream using the specified encoding (Without BOM/Preamble) + + StringBuilder source + MemoryStream destination + Encoding used for converter string into byte-stream + Helper char-buffer to minimize memory allocations + + + + Copies the contents of the StringBuilder to the destination StringBuilder + + StringBuilder source + StringBuilder destination + + + + Scans the StringBuilder for the position of needle character + + StringBuilder source + needle character to search for + + Index of the first occurrence (Else -1) + + + + Scans the StringBuilder for the position of needle character + + StringBuilder source + needle characters to search for + + Index of the first occurrence (Else -1) + + + + Compares the contents of two StringBuilders + + + Correct implementation of that also works when is not the same + + True when content is the same + + + + Compares the contents of a StringBuilder and a String + + True when content is the same + + + + Append a number and pad with 0 to 2 digits + + append to this + the number + + + + Append a number and pad with 0 to 4 digits + + append to this + the number + + + + Append a numeric type (byte, int, double, decimal) as string + + + + + Helpers for . + + + + + IsNullOrWhiteSpace, including for .NET 3.5 + + + + + + + Replace string with + + + + + + The same reference of nothing has been replaced. + + + Concatenates all the elements of a string array, using the specified separator between each element. + The string to use as a separator. is included in the returned string only if has more than one element. + An collection that contains the elements to concatenate. + A string that consists of the elements in delimited by the string. If is an empty array, the method returns . + + is . + + + + Split a string + + + + + Split a string, optional quoted value + + Text to split + Character to split the + Quote character + + Escape for the , not escape for the + , use quotes for that. + + + + + Split a string, optional quoted value + + Text to split + Character to split the + Quote character + + Escape for the , not escape for the + , use quotes for that. + + + + + Represents target with a chain of filters which determine + whether logging should happen. + + + + + Initializes a new instance of the class. + + The target. + The filter chain. + Default action if none of the filters match. + + + + Gets the target. + + The target. + + + + Gets the filter chain. + + The filter chain. + + + + Gets or sets the next item in the chain. + + The next item in the chain. + This is for example the 'target2' logger in writeTo='target1,target2' + + + + Gets the stack trace usage. + + A value that determines stack trace handling. + + + + Default action if none of the filters match. + + + + + Serves as a hash function for a particular type. + + + + + Determines if two objects are equal in value. + + Other object to compare to. + True if objects are equal, false otherwise. + + + + Determines if two objects of the same type are equal in value. + + Other object to compare to. + True if objects are equal, false otherwise. + + + + Wraps with a timeout. + + + + + Initializes a new instance of the class. + + The asynchronous continuation. + The timeout. + + + + Continuation function which implements the timeout logic. + + The exception. + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + URL Encoding helper. + + + + Allow UnreservedMarks instead of ReservedMarks, as specified by chosen RFC + + + Use RFC2396 standard (instead of RFC3986) + + + Should use lowercase when doing HEX escaping of special characters + + + Replace space ' ' with '+' instead of '%20' + + + Skip UTF8 encoding, and prefix special characters with '%u' + + + + Escape unicode string data for use in http-requests + + unicode string-data to be encoded + target for the encoded result + s for how to perform the encoding + + + + Convert the wide-char into utf8-bytes, and then escape + + + + + + + + + Is allowed? + + + + + + + + Is a-z / A-Z / 0-9 + + + + + + + Prevents the Xamarin linker from linking the target. + + + By applying this attribute all of the members of the target will be kept as if they had been referenced by the code. + + + + + Ensures that all members of this type are preserved + + + + + Flags the method as a method to preserve during linking if the container class is pulled in. + + + + + Helper class for XML + + + + + removes any unusual unicode characters that can't be encoded into XML + + + + + Cleans string of any invalid XML chars found + + unclean string + string with only valid XML chars + + + + Pretest, small text and not escape needed + + + + + + + + Converts object value to invariant format, and strips any invalid xml-characters + + Object value + Object value converted to string + + + + Converts object value to invariant format (understood by JavaScript) + + Object value + Object value converted to string + + + + XML elements must follow these naming rules: + - Element names are case-sensitive + - Element names must start with a letter or underscore + - Element names can contain letters, digits, hyphens, underscores, and periods + - Element names cannot contain spaces + + + + + + Converts object value to invariant format (understood by JavaScript) + + Object value + Object TypeCode + Check and remove unusual unicode characters from the result string. + Object value converted to string + + + + Safe version of WriteAttributeString + + + + + + + + Safe version of WriteElementSafeString + + + + + + + + + + Safe version of WriteCData + + + + + + + Interface for handling object transformation + + + + + Takes a dangerous (or massive) object and converts into a safe (or reduced) object + + + Null if unknown object, or object cannot be handled + + + + + Used to render the application domain name. + + + + + Create a new renderer + + + + + Create a new renderer + + + + + Format string. Possible values: "Short", "Long" or custom like {0} {1}. Default "Long" + The first parameter is the AppDomain.Id, the second the second the AppDomain.FriendlyName + This string is used in + + + + + + + + + + + + + + + Renders the assembly version information for the entry assembly or a named assembly. + + + As this layout renderer uses reflection and version information is unlikely to change during application execution, + it is recommended to use it in conjunction with the . + + + The entry assembly can't be found in some cases e.g. ASP.NET, unit tests, etc. + + + + + The (full) name of the assembly. If null, using the entry assembly. + + + + + + Gets or sets the type of assembly version to retrieve. + + + Some version type and platform combinations are not fully supported. + - UWP earlier than .NET Standard 1.5: Value for is always returned unless the parameter is specified. + + + + + + The default value to render if the Version is not available + + + + + + Gets or sets the custom format of the assembly version output. + + + Supported placeholders are 'major', 'minor', 'build' and 'revision'. + The default .NET template for version numbers is 'major.minor.build.revision'. See + https://docs.microsoft.com/en-gb/dotnet/api/system.version?view=netframework-4.7.2#remarks + for details. + + + + + + + + + + + + + + + Gets the assembly specified by , or entry assembly otherwise + + + + + Type of assembly version to retrieve. + + + + + Gets the assembly version. + + + + + Gets the file version. + + + + + Gets the product version, extracted from the additional version information. + + + + + Thread identity information (username). + + + + + Gets or sets a value indicating whether username should be included. + + + + + + Gets or sets a value indicating whether domain name should be included. + + + + + + Gets or sets the default value to be used when the User is not set. + + + + + + Gets or sets the default value to be used when the Domain is not set. + + + + + + + + + The information about the garbage collector. + + + + + Gets or sets the property to retrieve. + + + + + + + + + Gets or sets the property of System.GC to retrieve. + + + + + Total memory allocated. + + + + + Total memory allocated (perform full garbage collection first). + + + + + Gets the number of Gen0 collections. + + + + + Gets the number of Gen1 collections. + + + + + Gets the number of Gen2 collections. + + + + + Maximum generation number supported by GC. + + + + + The identifier of the current process. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + + + + + + The information about the running process. + + + + + Gets or sets the property to retrieve. + + + + + + Gets or sets the format-string to use if the property supports it (Ex. DateTime / TimeSpan / Enum) + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + + + + + + + Property of System.Diagnostics.Process to retrieve. + + + + + Base Priority. + + + + + Exit Code. + + + + + Exit Time. + + + + + Process Handle. + + + + + Handle Count. + + + + + Whether process has exited. + + + + + Process ID. + + + + + Machine name. + + + + + Handle of the main window. + + + + + Title of the main window. + + + + + Maximum Working Set. + + + + + Minimum Working Set. + + + + + Non-paged System Memory Size. + + + + + Non-paged System Memory Size (64-bit). + + + + + Paged Memory Size. + + + + + Paged Memory Size (64-bit).. + + + + + Paged System Memory Size. + + + + + Paged System Memory Size (64-bit). + + + + + Peak Paged Memory Size. + + + + + Peak Paged Memory Size (64-bit). + + + + + Peak Virtual Memory Size. + + + + + Peak Virtual Memory Size (64-bit).. + + + + + Peak Working Set Size. + + + + + Peak Working Set Size (64-bit). + + + + + Whether priority boost is enabled. + + + + + Priority Class. + + + + + Private Memory Size. + + + + + Private Memory Size (64-bit). + + + + + Privileged Processor Time. + + + + + Process Name. + + + + + Whether process is responding. + + + + + Session ID. + + + + + Process Start Time. + + + + + Total Processor Time. + + + + + User Processor Time. + + + + + Virtual Memory Size. + + + + + Virtual Memory Size (64-bit). + + + + + Working Set Size. + + + + + Working Set Size (64-bit). + + + + + The name of the current process. + + + + + Gets or sets a value indicating whether to write the full path to the process executable. + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + + + + + + Designates a property of the class as an ambient property. + + + non-ambient: ${uppercase:${level}} + ambient : ${level:uppercase} + + + + + Initializes a new instance of the class. + + Ambient property name. + + + + Marks class as layout-renderer and attaches a type-alias name for use in NLog configuration. + + + + + Initializes a new instance of the class. + + The layout-renderer type-alias for use in NLog configuration - without '${ }' + + + + The call site source file name. Full callsite + + + + + Gets or sets a value indicating whether to include source file path. + + + + + + Gets or sets the number of frames to skip. + + + + + + Logger should capture StackTrace, if it was not provided manually + + + + + + + + + + + + The call site (class name, method name and source information). + + + + + Gets or sets a value indicating whether to render the class name. + + + + + + Gets or sets a value indicating whether to render the include the namespace with . + + + + + + Gets or sets a value indicating whether to render the method name. + + + + + + Gets or sets a value indicating whether the method name will be cleaned up if it is detected as an anonymous delegate. + + + + + + Gets or sets a value indicating whether the method and class names will be cleaned up if it is detected as an async continuation + (everything after an await-statement inside of an async method). + + + + + + Gets or sets the number of frames to skip. + + + + + + Gets or sets a value indicating whether to render the source file name and line number. + + + + + + Gets or sets a value indicating whether to include source file path. + + + + + + Logger should capture StackTrace, if it was not provided manually + + + + + + + + + + + + The call site source line number. Full callsite + + + + + Gets or sets the number of frames to skip. + + + + + + Logger should capture StackTrace, if it was not provided manually + + + + + + + + + + + + Format of the ${stacktrace} layout renderer output. + + + + + Raw format (multiline - as returned by StackFrame.ToString() method). + + + + + Flat format (class and method names displayed in a single line). + + + + + Detailed flat format (method signatures displayed in a single line). + + + + + Stack trace renderer. + + + + + Gets or sets the output format of the stack trace. + + + + + + Gets or sets the number of top stack frames to be rendered. + + + + + + Gets or sets the number of frames to skip. + + + + + + Gets or sets the stack frame separator string. + + + + + + Logger should capture StackTrace, if it was not provided manually + + + + + + Gets or sets whether to render StackFrames in reverse order + + + + + + + + + + + + Log event context data. + + + + + Initializes a new instance of the class. + + + + + Gets or sets string that will be used to separate key/value pairs. + + + + + + Get or set if empty values should be included. + + A value is empty when null or in case of a string, null or empty string. + + + + + + Gets or sets whether to include the contents of the properties-dictionary. + + + + + + Gets or sets the keys to exclude from the output. If omitted, none are excluded. + + + + + + Enables capture of ScopeContext-properties from active thread context + + + + + Gets or sets how key/value pairs will be formatted. + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + Log event context data. See . + + + + + Gets or sets the name of the item. + + + + + + Format string for conversion from object to string. + + + + + + Gets or sets the culture used for rendering. + + + + + + Gets or sets the object-property-navigation-path for lookup of nested property + + + + + + Gets or sets whether to perform case-sensitive property-name lookup + + + + + + + + Render a Global Diagnostics Context item. See + + + + + Gets or sets the name of the item. + + + + + + Format string for conversion from object to string. + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + Installation parameter (passed to InstallNLogConfig). + + + + + Gets or sets the name of the parameter. + + + + + + + + + Obsolete and replaced by with NLog v5. + Render Mapped Diagnostics Logical (MDC) from + + + + + Gets or sets the name of the item. + + + + + + Format string for conversion from object to string. + + + + + + + + + Obsolete and replaced by with NLog v5. + Render Mapped Diagnostics Logical Context (MDLC) from + + + + + Gets or sets the name of the item. + + + + + + Format string for conversion from object to string. + + + + + + + + + Obsolete and replaced by with NLog v5. + Render Nested Diagnostic Context (NDC) from + + + + + Gets or sets the number of top stack frames to be rendered. + + + + + + Gets or sets the number of bottom stack frames to be rendered. + + + + + + Gets or sets the separator to be used for concatenating nested diagnostics context output. + + + + + + + + + Obsolete and replaced by with NLog v5. + Render Nested Diagnostic Context (NDLC) from + + + + + Gets or sets the number of top stack frames to be rendered. + + + + + + Gets or sets the number of bottom stack frames to be rendered. + + + + + + Gets or sets the separator to be used for concatenating nested logical context output. + + + + + + + + + Obsolete and replaced by with NLog v5. + Render Nested Diagnostic Context (NDLC) timings from + + + + + Gets or sets whether to only include the duration of the last scope created + + + + + + Gets or sets whether to just display the scope creation time, and not the duration + + + + + + Gets or sets the TimeSpan format. Can be any argument accepted by TimeSpan.ToString(format). + + + + + + + + + Renders the nested states from like a callstack + + + + + Gets or sets the indent token. + + + + + + + + + Renders the nested states from like a callstack + + + + + Gets or sets the number of top stack frames to be rendered. + + + + + + Gets or sets the number of bottom stack frames to be rendered. + + + + + + Gets or sets the separator to be used for concatenating nested logical context output. + + + + + + Gets or sets how to format each nested state. Ex. like JSON = @ + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + Renders specified property-item from + + + + + Gets or sets the name of the item. + + + + + + Format string for conversion from object to string. + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + Timing Renderer (Async scope) + + + + + Gets or sets whether to only include the duration of the last scope created + + + + + + Gets or sets whether to just display the scope creation time, and not the duration + + + + + + Gets or sets the TimeSpan format. Can be any argument accepted by TimeSpan.ToString(format). + + When Format has not been specified, then it will render TimeSpan.TotalMilliseconds + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + A renderer that puts into log a System.Diagnostics trace correlation id. + + + + + + + + A counter value (increases on each layout rendering). + + + + + Gets or sets the initial value of the counter. + + + + + + Gets or sets the value to be added to the counter after each layout rendering. + + + + + + Gets or sets the name of the sequence. Different named sequences can have individual values. + + + + + + + + + Globally-unique identifier (GUID). + + + + + Gets or sets the GUID format as accepted by Guid.ToString() method. + + + + + + Generate the Guid from the NLog LogEvent (Will be the same for all targets) + + + + + + + + + The sequence ID + + + + + + + + Current date and time. + + + + + Initializes a new instance of the class. + + + + + Gets or sets the culture used for rendering. + + + + + + Gets or sets the date format. Can be any argument accepted by DateTime.ToString(format). + + + + + + Gets or sets a value indicating whether to output UTC time instead of local time. + + + + + + + + + The date and time in a long, sortable format yyyy-MM-dd HH:mm:ss.ffff. + + + + + Gets or sets a value indicating whether to output UTC time instead of local time. + + + + + + + + + The process time in format HH:mm:ss.mmm. + + + + + Gets or sets a value indicating whether to output in culture invariant format + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + Write timestamp to builder with format hh:mm:ss:fff + + + + + The short date in a sortable format yyyy-MM-dd. + + + + + Gets or sets a value indicating whether to output UTC time instead of local time. + + + + + + + + + The Ticks value of current date and time. + + + + + + + + The time in a 24-hour, sortable format HH:mm:ss.mmmm. + + + + + Gets or sets a value indicating whether to output UTC time instead of local time. + + + + + + Gets or sets a value indicating whether to output in culture invariant format + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + DB null for a database + + + + + + + + The current application domain's base directory. + + + + + cached + + + + + Use base dir of current process. Alternative one can just use ${processdir} + + + + + + Fallback to the base dir of current process, when AppDomain.BaseDirectory is Temp-Path (.NET Core 3 - Single File Publish) + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + + + Gets or sets the name of the file to be Path.Combine()'d with the base directory. + + + + + + Gets or sets the name of the directory to be Path.Combine()'d with the base directory. + + + + + + + + + The current working directory of the application. + + + + + Gets or sets the name of the file to be Path.Combine()'d with the current directory. + + + + + + Gets or sets the name of the directory to be Path.Combine()'d with the current directory. + + + + + + + + + The directory where NLog.dll is located. + + + + + Gets or sets the name of the file to be Path.Combine()'d with the directory name. + + + + + + Gets or sets the name of the directory to be Path.Combine()'d with the directory name. + + + + + + + + + + + + + + + The executable directory from the FileName, + using the current process + + + + + Gets or sets the name of the file to be Path.Combine()'d with the process directory. + + + + + + Gets or sets the name of the directory to be Path.Combine()'d with the process directory. + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + + + + + + System special folder path from + + + + + Initializes a new instance of the class. + + + + + System special folder path from + + + + + Initializes a new instance of the class. + + + + + System special folder path (includes My Documents, My Music, Program Files, Desktop, and more). + + + + + Gets or sets the system special folder to use. + + + Full list of options is available at MSDN. + The most common ones are: +
    +
  • CommonApplicationData - application data for all users.
  • +
  • ApplicationData - roaming application data for current user.
  • +
  • LocalApplicationData - non roaming application data for current user
  • +
  • UserProfile - Profile folder for current user
  • +
  • DesktopDirectory - Desktop-directory for current user
  • +
  • MyDocuments - My Documents-directory for current user
  • +
  • System - System directory
  • +
+
+ +
+ + + Gets or sets the name of the file to be Path.Combine()'d with the directory name. + + + + + + Gets or sets the name of the directory to be Path.Combine()'d with the directory name. + + + + + + + + + System special folder path from + + + + + Initializes a new instance of the class. + + + + + A temporary directory. + + + + + Gets or sets the name of the file to be Path.Combine()'d with the directory name. + + + + + + Gets or sets the name of the directory to be Path.Combine()'d with the directory name. + + + + + + + + + + + + The OS dependent directory separator + + + + + + + + Render information of + for the exception passed to the logger call + + + + + Gets or sets the key to search the exception Data for + + + + + + Gets or sets whether to render innermost Exception from + + + + + + Format string for conversion from object to string. + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + Exception information provided through + a call to one of the Logger.*Exception() methods. + + + + + Initializes a new instance of the class. + + + + + Gets or sets the format of the output. Must be a comma-separated list of exception + properties: Message, Type, ShortType, ToString, Method, StackTrace. + This parameter value is case-insensitive. + + + + + + + + Gets or sets the format of the output of inner exceptions. Must be a comma-separated list of exception + properties: Message, Type, ShortType, ToString, Method, StackTrace. + This parameter value is case-insensitive. + + + + + + Gets or sets the separator used to concatenate parts specified in the Format. + + + + + + Gets or sets the separator used to concatenate exception data specified in the Format. + + + + + + Gets or sets the maximum number of inner exceptions to include in the output. + By default inner exceptions are not enabled for compatibility with NLog 1.0. + + + + + + Gets or sets the separator between inner exceptions. + + + + + + Gets or sets whether to render innermost Exception from + + + + + + Gets or sets whether to collapse exception tree using + + + + + + Gets the formats of the output of inner exceptions to be rendered in target. + + + + + + Gets the formats of the output to be rendered in target. + + + + + + + + + Appends the Message of an Exception to the specified . + + The to append the rendered data to. + The exception containing the Message to append. + + + + Appends the method name from Exception's stack trace to the specified . + + The to append the rendered data to. + The Exception whose method name should be appended. + + + + Appends the stack trace from an Exception to the specified . + + The to append the rendered data to. + The Exception whose stack trace should be appended. + + + + Appends the result of calling ToString() on an Exception to the specified . + + The to append the rendered data to. + The Exception whose call to ToString() should be appended. + + + + Appends the type of an Exception to the specified . + + The to append the rendered data to. + The Exception whose type should be appended. + + + + Appends the short type of an Exception to the specified . + + The to append the rendered data to. + The Exception whose short type should be appended. + + + + Appends the application source of an Exception to the specified . + + The to append the rendered data to. + The Exception whose source should be appended. + + + + Appends the HResult of an Exception to the specified . + + The to append the rendered data to. + The Exception whose HResult should be appended. + + + + Appends the contents of an Exception's Data property to the specified . + + The to append the rendered data to. + The Exception whose Data property elements should be appended. + + + + Appends all the serialized properties of an Exception into the specified . + + The to append the rendered data to. + The Exception whose properties should be appended. + + + + Appends all the additional properties of an Exception like Data key-value-pairs + + The to append the rendered data to. + The Exception whose properties should be appended. + + + + Split the string and then compile into list of Rendering formats. + + + + + Renders contents of the specified file. + + + + + Initializes a new instance of the class. + + + + + Gets or sets the name of the file. + + + + + + Gets or sets the encoding used in the file. + + The encoding. + + + + + + + + A layout renderer which could have different behavior per instance by using a . + + + + + Initializes a new instance of the class. + + Name without ${}. + + + + Initializes a new instance of the class. + + Name without ${}. + Method that renders the layout. + + + + Name used in config without ${}. E.g. "test" could be used as "${test}". + + + + + Method that renders the layout. + + This public property will be removed in NLog 5. + + + + + Format string for conversion from object to string. + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + Render the value for this log event + + The logging event. + The value. + + + + A layout renderer which could have different behavior per instance by using a . + + + + + Initializes a new instance of the class. + + Name without ${}. + Method that renders the layout. + + + + Thread identity information (name and authentication information). + + + + + Gets or sets the separator to be used when concatenating + parts of identity information. + + + + + + Gets or sets a value indicating whether to render Thread.CurrentPrincipal.Identity.Name. + + + + + + Gets or sets a value indicating whether to render Thread.CurrentPrincipal.Identity.AuthenticationType. + + + + + + Gets or sets a value indicating whether to render Thread.CurrentPrincipal.Identity.IsAuthenticated. + + + + + + + + + Render environmental information related to logging events. + + + + + Gets the logging configuration this target is part of. + + + + + Value formatter + + + + + + + + Renders the value of layout renderer in the context of the specified log event. + + The log event. + String representation of a layout renderer. + + + + + + + + + + Initializes this instance. + + The configuration. + + + + Closes this instance. + + + + + Renders the value of layout renderer in the context of the specified log event. + + The log event. + The layout render output is appended to builder + + + + Renders the value of layout renderer in the context of the specified log event into . + + The to append the rendered data to. + Logging event. + + + + Initializes the layout renderer. + + + + + Closes the layout renderer. + + + + + Get the for rendering the messages to a + + LogEvent with culture + Culture in on Layout level + + + + + Get the for rendering the messages to a + + LogEvent with culture + Culture in on Layout level + + + is preferred + + + + + Obsolete and replaced by with NLog v5.2. + + Register a custom layout renderer. + + Short-cut for registering to default + Type of the layout renderer. + The layout-renderer type-alias for use in NLog configuration - without '${ }' + + + + Obsolete and replaced by with NLog v5.2 + + Register a custom layout renderer. + + Short-cut for registering to default + Type of the layout renderer. + The layout-renderer type-alias for use in NLog configuration - without '${ }' + + + + Obsolete and replaced by with NLog v5.2 + + Register a custom layout renderer with a callback function . The callback receives the logEvent. + + The layout-renderer type-alias for use in NLog configuration - without '${ }' + Callback that returns the value for the layout renderer. + + + + Obsolete and replaced by with NLog v5.2 + + Register a custom layout renderer with a callback function . The callback receives the logEvent and the current configuration. + + The layout-renderer type-alias for use in NLog configuration - without '${ }' + Callback that returns the value for the layout renderer. + + + + Obsolete and replaced by with NLog v5.2 + + Register a custom layout renderer with a callback function . The callback receives the logEvent and the current configuration. + + Renderer with callback func + + + + Resolves the interface service-type from the service-repository + + + + + Format of the ${level} layout renderer output. + + + + + Render the LogLevel standard name. + + + + + Render the first character of the level. + + + + + Render the first character of the level. + + + + + Render the ordinal (aka number) for the level. + + + + + Render the LogLevel full name, expanding Warn / Info abbreviations + + + + + Render the LogLevel as 3 letter abbreviations (Trc, Dbg, Inf, Wrn, Err, Ftl) + + + + + The log level. + + + + + Gets or sets a value indicating the output format of the level. + + + + + + Gets or sets a value indicating whether upper case conversion should be applied. + + A value of true if upper case conversion should be applied otherwise, false. + + + + + + + + A string literal. + + + This is used to escape '${' sequence + as ;${literal:text=${}' + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The literal text value. + This is used by the layout compiler. + + + + Gets or sets the literal text. + + + + + + + + + A string literal with a fixed raw value + + + + + Initializes a new instance of the class. + + The literal text value. + + Fixed raw value + This is used by the layout compiler. + + + + XML event description compatible with log4j, Chainsaw and NLogViewer. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + + + + + + Gets or sets a value indicating whether to include NLog-specific extensions to log4j schema. + + + + + + Gets or sets a value indicating whether the XML should use spaces for indentation. + + + + + + Gets or sets the AppInfo field. By default it's the friendly name of the current AppDomain. + + + + + + Gets or sets a value indicating whether to include call site (class and method name) in the information sent over the network. + + + + + + Gets or sets a value indicating whether to include source info (file name and line number) in the information sent over the network. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets a value indicating whether to include contents of the dictionary. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets a value indicating whether to include contents of the dictionary. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets a value indicating whether to include contents of the stack. + + + + + + Gets or sets whether to include log4j:NDC in output from nested context. + + + + + + Gets or sets whether to include the contents of the properties-dictionary. + + + + + + Gets or sets whether to include log4j:NDC in output from nested context. + + + + + + Gets or sets the stack separator for log4j:NDC in output from nested context. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets the stack separator for log4j:NDC in output from nested context. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets the option to include all properties from the log events + + + + + + Gets or sets the option to include all properties from the log events + + + + + + Gets or sets the stack separator for log4j:NDC in output from nested context. + + + + + + Gets or sets the log4j:event logger-xml-attribute (Default ${logger}) + + + + + + Gets or sets whether the log4j:throwable xml-element should be written as CDATA + + + + + + + + + + + + The logger name. + + + + + Gets or sets a value indicating whether to render short logger name (the part after the trailing dot character). + + + + + + + + + The environment variable. + + + + + Gets or sets the name of the environment variable. + + + + + + Gets or sets the default value to be used when the environment variable is not set. + + + + + + + + + The host name that the process is running on. + + + + + + + + Gets the host name and falls back to computer name if not available + + + + + Tries the lookup value. + + The lookup function. + Type of the lookup. + + + + + + + + The IP address from the network interface card (NIC) on the local machine + + + Skips loopback-adapters and tunnel-interfaces. Skips devices without any MAC-address + + + + + Get or set whether to prioritize IPv6 or IPv4 (default) + + + + + + + + + + + + + + + The machine name that the process is running on. + + + + + + + + + + + The formatted log message. + + + + + Initializes a new instance of the class. + + + + + Gets or sets a value indicating whether to log exception along with message. + + + + + + Gets or sets the string that separates message from the exception. + + + + + + Gets or sets whether it should render the raw message without formatting parameters + + + + + + + + + A newline literal. + + + + + + + + The identifier of the current thread. + + + + + + + + The name of the current thread. + + + + + + + + Render a NLog Configuration variable assigned from API or loaded from config-file + + + + + Gets or sets the name of the NLog variable. + + + + + + Gets or sets the default value to be used when the variable is not set. + + Not used if Name is null + + + + + Gets the configuration variable layout matching the configured Name + + Mostly relevant for the scanning of active NLog Layouts (Ex. CallSite capture) + + + + + + + Try lookup the configuration variable layout matching the configured Name + + + + + + + + Applies caching to another layout output. + + + The value of the inner layout will be rendered only once and reused subsequently. + + + + + A value indicating when the cache is cleared. + + + + Never clear the cache. + + + Clear the cache whenever the is initialized. + + + Clear the cache whenever the is closed. + + + + Gets or sets a value indicating whether this is enabled. + + + + + + Gets or sets a value indicating when the cache is cleared. + + + + + + Cachekey. If the cachekey changes, resets the value. For example, the cachekey would be the current day.s + + + + + + Gets or sets a value indicating how many seconds the value should stay cached until it expires + + + + + + + + + + + + + + + + + + Filters characters not allowed in the file names by replacing them with safe character. + + + + + Gets or sets a value indicating whether to modify the output of this renderer so it can be used as a part of file path + (illegal characters are replaced with '_'). + + + + + + + + + + + + Escapes output of another layout using JSON rules. + + + + + Gets or sets whether output should be encoded with Json-string escaping. + + + + + + Gets or sets a value indicating whether to escape non-ascii characters + + + + + + Should forward slashes be escaped? If true, / will be converted to \/ + + + If not set explicitly then the value of the parent will be used as default. + + + + + + + + + + + + Left part of a text + + + + + Gets or sets the length in characters. + + + + + + Same as -property, so it can be used as ambient property. + + + ${message:truncate=80} + + + + + + + + + + + + Converts the result of another layout output to lower case. + + + + + Gets or sets a value indicating whether lower case conversion should be applied. + + A value of true if lower case conversion should be applied; otherwise, false. + + + + + Same as -property, so it can be used as ambient property. + + + ${level:tolower} + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + + + + Render the non-raw value of an object. + + For performance and/or full (formatted) control of the output. + + + + Gets or sets a value indicating whether to disable the IRawValue-interface + + A value of true if IRawValue-interface should be ignored; otherwise, false. + + + + + + + + + + + Render a single property of a object + + + + + Gets or sets the object-property-navigation-path for lookup of nested property + + Shortcut for + + + + + + Gets or sets the object-property-navigation-path for lookup of nested property + + + + + + Format string for conversion from object to string. + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + + + + Lookup property-value from source object based on + + Could resolve property-value? + + + + Only outputs the inner layout when exception has been defined for log message. + + + + + If is not found, print this layout. + + + + + + + + + + + + Outputs alternative layout when the inner layout produces empty result. + + + ${onhasproperties:, Properties\: ${all-event-properties}} + + + + + If is not found, print this layout. + + + + + + + + + + + + Horizontal alignment for padding layout renderers. + + + + + When layout text is too long, align it to the left + (remove characters from the right). + + + + + When layout text is too long, align it to the right + (remove characters from the left). + + + + + Applies padding to another layout output. + + + + + Gets or sets the number of characters to pad the output to. + + + Positive padding values cause left padding, negative values + cause right padding to the desired width. + + + + + + Gets or sets the padding character. + + + + + + Gets or sets a value indicating whether to trim the + rendered text to the absolute value of the padding length. + + + + + + Gets or sets a value indicating whether a value that has + been truncated (when is true) + will be left-aligned (characters removed from the right) + or right-aligned (characters removed from the left). The + default is left alignment. + + + + + + + + + + + + Replaces a string in the output of another layout with another string. + + + ${replace:searchFor=\\n+:replaceWith=-:regex=true:inner=${message}} + + + + + Gets or sets the text to search for. + + The text search for. + + + + + Gets or sets a value indicating whether regular expressions should be used. + + A value of true if regular expressions should be used otherwise, false. + + + + + Gets or sets the replacement string. + + The replacement string. + + + + + Gets or sets the group name to replace when using regular expressions. + Leave null or empty to replace without using group name. + + The group name. + + + + + Gets or sets a value indicating whether to ignore case. + + A value of true if case should be ignored when searching; otherwise, false. + + + + + Gets or sets a value indicating whether to search for whole words. + + A value of true if whole words should be searched for; otherwise, false. + + + + + Compile the ? This can improve the performance, but at the costs of more memory usage. If false, the Regex Cache is used. + + + + + + + + + + + + This class was created instead of simply using a lambda expression so that the "ThreadAgnosticAttributeTest" will pass + + + + + A match evaluator for Regular Expression based replacing + + Input string. + Group name in the regex. + Replace value. + Match from regex. + Groups replaced with . + + + + Replaces newline characters from the result of another layout renderer with spaces. + + + + + Gets or sets a value indicating the string that should be used for separating lines. + + + + + + + + + + + + Right part of a text + + + + + Gets or sets the length in characters. + + + + + + + + + + + + Decodes text "encrypted" with ROT-13. + + + See https://en.wikipedia.org/wiki/ROT13. + + + + + Gets or sets the layout to be wrapped. + + The layout to be wrapped. + This variable is for backwards compatibility + + + + + Encodes/Decodes ROT-13-encoded string. + + The string to be encoded/decoded. + Encoded/Decoded text. + + + + + + + + + + Encodes/Decodes ROT-13-encoded string. + + + + + Substring the result + + + ${substring:${level}:start=2:length=2} + ${substring:${level}:start=-2:length=2} + ${substring:Inner=${level}:start=2:length=2} + + + + + Gets or sets the start index. + + Index + + + + + Gets or sets the length in characters. If null, then the whole string + + Index + + + + + + + + + + + Calculate start position + + 0 or positive number + + + + Calculate needed length + + 0 or positive number + + + + Trims the whitespace from the result of another layout renderer. + + + + + Gets or sets a value indicating whether lower case conversion should be applied. + + A value of true if lower case conversion should be applied; otherwise, false. + + + + + + + + + + + Converts the result of another layout output to upper case. + + + ${uppercase:${level}} //[DefaultParameter] + ${uppercase:Inner=${level}} + ${level:uppercase} // [AmbientProperty] + + + + + Gets or sets a value indicating whether upper case conversion should be applied. + + A value of true if upper case conversion should be applied otherwise, false. + + + + + Same as -property, so it can be used as ambient property. + + + ${level:toupper} + + + + + + Gets or sets the culture used for rendering. + + + + + + + + + + + + Encodes the result of another layout output for use with URLs. + + + + + Initializes a new instance of the class. + + + + + Gets or sets a value indicating whether spaces should be translated to '+' or '%20'. + + A value of true if space should be translated to '+'; otherwise, false. + + + + + Gets or sets a value whether escaping be done according to Rfc3986 (Supports Internationalized Resource Identifiers - IRIs) + + A value of true if Rfc3986; otherwise, false for legacy Rfc2396. + + + + + Gets or sets a value whether escaping be done according to the old NLog style (Very non-standard) + + A value of true if legacy encoding; otherwise, false for standard UTF8 encoding. + + + + + + + + + + + Outputs alternative layout when the inner layout produces empty result. + + + + + Gets or sets the layout to be rendered when original layout produced empty result. + + + + + + + + + + + + + + + Only outputs the inner layout when the specified condition has been met. + + + + + Gets or sets the condition that must be met for the layout to be printed. + + + + + + If is not met, print this layout. + + + + + + + + + + + + Replaces newline characters from the result of another layout renderer with spaces. + + + + + Gets or sets the line length for wrapping. + + + Only positive values are allowed + + + + + + + + + Base class for s which wrapping other s. + + This has the property (which is default) and can be used to wrap. + + + ${uppercase:${level}} //[DefaultParameter] + ${uppercase:Inner=${level}} + + + + + Gets or sets the wrapped layout. + + [DefaultParameter] so Inner: is not required if it's the first + + + + + + + + + + + + Appends the rendered output from -layout and transforms the added output (when necessary) + + Logging event. + The to append the rendered data to. + Start position for any necessary transformation of . + + + + Transforms the output of another layout. + + Logging event. + Output to be transform. + Transformed text. + + + + Transforms the output of another layout. + + Output to be transform. + Transformed text. + + + + Renders the inner layout contents. + + The log event. + Contents of inner layout. + + + + Base class for s which wrapping other s. + + This expects the transformation to work on a + + + + + + + + + + + Transforms the output of another layout. + + Output to be transform. + + + + Renders the inner layout contents. + + + for the result + + + + + + + + + + Converts the result of another layout output to be XML-compliant. + + + + + Gets or sets whether output should be encoded with Xml-string escaping. + + Ensures always valid XML, but gives a performance hit + + + + + Gets or sets a value indicating whether to transform newlines (\r\n) into ( ) + + + + + + + + + + + + A layout containing one or more nested layouts. + + + See NLog Wiki + + Documentation on NLog Wiki + + + + Initializes a new instance of the class. + + + + + Gets the inner layouts. + + + + + + + + + + + + + + + + + + + + + A column in the CSV. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The name of the column. + The layout of the column. + + + + Gets or sets the name of the column. + + + + + + Gets or sets the layout of the column. + + + + + + Gets or sets the override of Quoting mode + + + and are faster than the default + + + + + + Specifies allowed column delimiters. + + + + + Automatically detect from regional settings. + + + + + Comma (ASCII 44). + + + + + Semicolon (ASCII 59). + + + + + Tab character (ASCII 9). + + + + + Pipe character (ASCII 124). + + + + + Space character (ASCII 32). + + + + + Custom string, specified by the . + + + + + A specialized layout that renders CSV-formatted events. + + + + If is set, then the header generation with column names will be disabled. + + See NLog Wiki + + Documentation on NLog Wiki + + + + Initializes a new instance of the class. + + + + + Gets the array of parameters to be passed. + + + + + + Gets or sets a value indicating whether CVS should include header. + + A value of true if CVS should include header; otherwise, false. + + + + + Gets or sets the column delimiter. + + + + + + Gets or sets the quoting mode. + + + + + + Gets or sets the quote Character. + + + + + + Gets or sets the custom column delimiter value (valid when is set to ). + + + + + + + + + + + + + + + + + + Get the headers with the column names. + + + + + + Header with column names for CSV layout. + + + + + Initializes a new instance of the class. + + The parent. + + + + + + + + + + + + + + + + Specifies CSV quoting modes. + + + + + Quote Always (Fast) + + + + + Quote nothing (Very fast) + + + + + Quote only whose values contain the quote symbol or the separator (Slow) + + + + + A specialized layout that renders LogEvent as JSON-Array + + + See NLog Wiki + + Documentation on NLog Wiki + + + + Gets the array of items to include in JSON-Array + + + + + + Gets or sets the option to suppress the extra spaces in the output json + + + + + + Gets or sets the option to render the empty object value {} + + + + + + + + + + + + + + + + + + + + + JSON attribute. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The name of the attribute. + The layout of the attribute's value. + + + + Initializes a new instance of the class. + + The name of the attribute. + The layout of the attribute's value. + Encode value with json-encode + + + + Gets or sets the name of the attribute. + + + + + + Gets or sets the layout that will be rendered as the attribute's value. + + + + + + Gets or sets the result value type, for conversion of layout rendering output + + + + + + Gets or sets the fallback value when result value is not available + + + + + + Gets or sets whether output should be encoded as Json-String-Property, or be treated as valid json. + + + + + + Gets or sets a value indicating whether to escape non-ascii characters + + + + + + Should forward slashes be escaped? If true, / will be converted to \/ + + + If not set explicitly then the value of the parent will be used as default. + + + + + + Gets or sets whether an attribute with empty value should be included in the output + + + + + + A specialized layout that renders JSON-formatted events. + + + See NLog Wiki + + Documentation on NLog Wiki + + + + Initializes a new instance of the class. + + + + + Gets the array of attributes' configurations. + + + + + + Gets or sets the option to suppress the extra spaces in the output json + + + + + + Gets or sets the option to render the empty object value {} + + + + + + Auto indent and create new lines + + + + + + Gets or sets the option to include all properties from the log event (as JSON) + + + + + + Gets or sets a value indicating whether to include contents of the dictionary. + + + + + + Gets or sets whether to include the contents of the dictionary. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets the option to include all properties from the log event (as JSON) + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets a value indicating whether to include contents of the dictionary. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets a value indicating whether to include contents of the dictionary. + + + + + + Gets or sets the option to exclude null/empty properties from the log event (as JSON) + + + + + + List of property names to exclude when is true + + + + + + How far should the JSON serializer follow object references before backing off + + + + + + Should forward slashes be escaped? If true, / will be converted to \/ + + + If not set explicitly then the value of the parent will be used as default. + + + + + + + + + + + + + + + + + + + + + Abstract interface that layouts must implement. + + + + + Is this layout initialized? See + + + + + Gets a value indicating whether this layout is thread-agnostic (can be rendered on any thread). + + + Layout is thread-agnostic if it has been marked with [ThreadAgnostic] attribute and all its children are + like that as well. + + Thread-agnostic layouts only use contents of for its output. + + + + + Gets the level of stack trace information required for rendering. + + + + + Gets the logging configuration this target is part of. + + + + + Converts a given text to a . + + Text to be converted. + object represented by the text. + + + + Implicitly converts the specified string to a . + + The layout string. + Instance of .' + + + + Implicitly converts the specified string to a . + + The layout string. + The NLog factories to use when resolving layout renderers. + Instance of . + + + + Implicitly converts the specified string to a . + + The layout string. + Whether should be thrown on parse errors (false = replace unrecognized tokens with a space). + Instance of . + + + + Create a from a lambda method. + + Method that renders the layout. + Tell if method is safe for concurrent threading. + Instance of . + + + + Precalculates the layout for the specified log event and stores the result + in per-log event cache. + + Only if the layout doesn't have [ThreadAgnostic] and doesn't contain layouts with [ThreadAgnostic]. + + The log event. + + Calling this method enables you to store the log event in a buffer + and/or potentially evaluate it in another thread even though the + layout may contain thread-dependent renderer. + + + + + Renders formatted output using the log event as context. + + Inside a , is preferred for performance reasons. + The logging event. + The formatted output as string. + + + + Optimized version of that works best when + override of is available. + + The logging event. + Appends the formatted output to target + + + + Optimized version of that works best when + override of is available. + + The logging event. + Appends the string representing log event to target + Should rendering result be cached on LogEventInfo + + + + Valid default implementation of , when having implemented the optimized + + The logging event. + The rendered layout. + + + + Renders formatted output using the log event as context. + + The logging event. + Appends the formatted output to target + + + + Initializes this instance. + + The configuration. + + + + Closes this instance. + + + + + Initializes this instance. + + The configuration. + + + + Closes this instance. + + + + + Initializes the layout. + + + + + Closes the layout. + + + + + Renders formatted output using the log event as context. + + The logging event. + The formatted output. + + + + Obsolete and replaced by with NLog v5.2. + + Register a custom Layout. + + Short-cut for registering to default + Type of the Layout. + Name of the Layout. + + + + Obsolete and replaced by with NLog v5.2. + + Register a custom Layout. + + Short-cut for registering to default + Type of the Layout. + Name of the Layout. + + + + Optimized version of for internal Layouts, when + override of is available. + + + + + Try get value + + + rawValue if return result is true + false if we could not determine the rawValue + + + + Resolve from DI + + Avoid calling this while handling a LogEvent, since random deadlocks can occur + + + + Marks class as Layout and attaches a type-alias name for use in NLog configuration. + + + + + Initializes a new instance of the class. + + The Layout type-alias for use in NLog configuration. + + + + Parses layout strings. + + + + + Add to + + + + + + + Options available for + + + + + Default options + + + + + Layout renderer method can handle concurrent threads + + + + + Layout renderer method is agnostic to current thread context. This means it will render the same result independent of thread-context. + + + + + A specialized layout that supports header and footer. + + + + + Gets or sets the body layout (can be repeated multiple times). + + + + + + Gets or sets the header layout. + + + + + + Gets or sets the footer layout. + + + + + + + + + + + + A specialized layout that renders Log4j-compatible XML events. + + + + This layout is not meant to be used explicitly. Instead you can use ${log4jxmlevent} layout renderer. + + See NLog Wiki + + Documentation on NLog Wiki + + + + Initializes a new instance of the class. + + + + + Gets the instance that renders log events. + + + + + Gets the collection of parameters. Each parameter contains a mapping + between NLog layout and a named parameter. + + + + + + Gets or sets the option to include all properties from the log events + + + + + + Gets or sets whether to include the contents of the properties-dictionary. + + + + + + Gets or sets whether to include log4j:NDC in output from nested context. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets the option to include all properties from the log events + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets a value indicating whether to include contents of the dictionary. + + + + + + Gets or sets whether to include log4j:NDC in output from nested context. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets a value indicating whether to include contents of the dictionary. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets a value indicating whether to include contents of the stack. + + + + + + Gets or sets the log4j:event logger-xml-attribute (Default ${logger}) + + + + + + Gets or sets the AppInfo field. By default it's the friendly name of the current AppDomain. + + + + + + Gets or sets whether the log4j:throwable xml-element should be written as CDATA + + + + + + Gets or sets a value indicating whether to include call site (class and method name) in the information sent over the network. + + + + + + Gets or sets a value indicating whether to include source info (file name and line number) in the information sent over the network. + + + + + + + + + + + + Represents a string with embedded placeholders that can render contextual information. + + + + This layout is not meant to be used explicitly. Instead you can just use a string containing layout + renderers everywhere the layout is required. + + See NLog Wiki + + Documentation on NLog Wiki + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The layout string to parse. + + + + Initializes a new instance of the class. + + The layout string to parse. + The NLog factories to use when creating references to layout renderers. + + + + Initializes a new instance of the class. + + The layout string to parse. + The NLog factories to use when creating references to layout renderers. + Whether should be thrown on parse errors. + + + + Original text before compile to Layout renderes + + + + + Gets or sets the layout text. + + + + + + Is the message fixed? (no Layout renderers used) + + + + + Get the fixed text. Only set when is true + + + + + Is the message a simple formatted string? (Can skip StringBuilder) + + + + + Gets a collection of objects that make up this layout. + + + + + Gets a collection of objects that make up this layout. + + + + + Gets the level of stack trace information required for rendering. + + + + + Converts a text to a simple layout. + + Text to be converted. + A object. + + + + Escapes the passed text so that it can + be used literally in all places where + layout is normally expected without being + treated as layout. + + The text to be escaped. + The escaped text. + + Escaping is done by replacing all occurrences of + '${' with '${literal:text=${}' + + + + + Evaluates the specified text by expanding all layout renderers. + + The text to be evaluated. + Log event to be used for evaluation. + The input text with all occurrences of ${} replaced with + values provided by the appropriate layout renderers. + + + + Evaluates the specified text by expanding all layout renderers + in new context. + + The text to be evaluated. + The input text with all occurrences of ${} replaced with + values provided by the appropriate layout renderers. + + + + + + + + + + + + + + + + + + + + + + Typed Layout for easy conversion from NLog Layout logic to a simple value (ex. integer or enum) + + + + + + Is fixed value? + + + + + Fixed value + + + + + Initializes a new instance of the class. + + Dynamic NLog Layout + + + + Initializes a new instance of the class. + + Dynamic NLog Layout + Format used for parsing string-value into result value type + Culture used for parsing string-value into result value type + + + + Initializes a new instance of the class. + + Fixed value + + + + Render Value + + Log event for rendering + Fallback value when no value available + Result value when available, else fallback to defaultValue + + + + Renders the value and converts the value into string format + + + Only to implement abstract method from , and only used when calling + + + + + + + + + + + + + + + + + + + + + + + Implements Equals using + + + + + + + + Converts a given value to a . + + Text to be converted. + + + + Converts a given text to a . + + Text to be converted. + + + + Implements the operator == using + + + + + Implements the operator != using + + + + + Provides access to untyped value without knowing underlying generic type + + + + + Typed Value that is easily configured from NLog.config file + + + + + Initializes a new instance of the class. + + + + + Gets or sets the layout that will render the result value + + + + + + Gets or sets the result value type, for conversion of layout rendering output + + + + + + Gets or sets the fallback value when result value is not available + + + + + + Gets or sets the fallback value should be null (instead of default value of ) when result value is not available + + + + + + Gets or sets format used for parsing parameter string-value for type-conversion + + + + + + Gets or sets the culture used for parsing parameter string-value for type-conversion + + + + + + Render Result Value + + Log event for rendering + Result value when available, else fallback to defaultValue + + + + XML attribute. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The name of the attribute. + The layout of the attribute's value. + + + + Initializes a new instance of the class. + + The name of the attribute. + The layout of the attribute's value. + Encode value with xml-encode + + + + Gets or sets the name of the attribute. + + + + + + Gets or sets the layout that will be rendered as the attribute's value. + + + + + + Gets or sets the result value type, for conversion of layout rendering output + + + + + + Gets or sets the fallback value when result value is not available + + + + + + Gets or sets whether output should be encoded with Xml-string escaping, or be treated as valid xml-attribute-value + + + + + + Gets or sets whether an attribute with empty value should be included in the output + + + + + + A XML Element + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + + + Name of the element + + + Default value "item" + + + + + + Value inside the element + + + + + + Value inside the element + + + + + + Gets or sets whether output should be encoded with Xml-string escaping, or be treated as valid xml-element-value + + + + + + A specialized layout that renders XML-formatted events. + + + + + Initializes a new instance of the class. + + The name of the top XML node + The value of the top XML node + + + + Name of the XML element + + Upgrade to private protected when using C# 7.2 + + + + Value inside the XML element + + Upgrade to private protected when using C# 7.2 + + + + Auto indent and create new lines + + + + + + Gets the array of xml 'elements' configurations. + + + + + + Gets the array of 'attributes' configurations for the element + + + + + + Gets or sets whether a ElementValue with empty value should be included in the output + + + + + + Gets or sets the option to include all properties from the log event (as XML) + + + + + + Gets or sets whether to include the contents of the dictionary. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets a value indicating whether to include contents of the dictionary. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets a value indicating whether to include contents of the dictionary. + + + + + + Obsolete and replaced by with NLog v5. + + Gets or sets the option to include all properties from the log event (as XML) + + + + + + List of property names to exclude when is true + + + + + + XML element name to use when rendering properties + + + Support string-format where {0} means property-key-name + + Skips closing element tag when having configured + + + + + + XML attribute name to use when rendering property-key + + When null (or empty) then key-attribute is not included + + + Will replace newlines in attribute-value with + + + + + + XML attribute name to use when rendering property-value + + When null (or empty) then value-attribute is not included and + value is formatted as XML-element-value + + + Skips closing element tag when using attribute for value + + Will replace newlines in attribute-value with + + + + + + XML element name to use for rendering IList-collections items + + + + + + How far should the XML serializer follow object references before backing off + + + + + + + + + + + + + + + + + + write attribute, only if is not empty + + + + + rendered + + + + + + + A specialized layout that renders XML-formatted events. + + + See NLog Wiki + + Documentation on NLog Wiki + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The name of the top XML node + The value of the top XML node + + + + Name of the root XML element + + + Default value "logevent" + + + + + + Value inside the root XML element + + + + + + Determines whether or not this attribute will be Xml encoded. + + + + + + Extensions for NLog . + + + + + Renders the logevent into a result-value by using the provided layout + + Inside a , is preferred for performance reasons. + + The layout. + The logevent info. + Fallback value when no value available + Result value when available, else fallback to defaultValue + + + + A fluent builder for logging events to NLog. + + + + + Initializes a new instance of the class. + + The to send the log event. + + + + Initializes a new instance of the class. + + The to send the log event. + The log level. LogEvent is only created when is enabled for + + + + The logger to write the log event to + + + + + Logging event that will be written + + + + + Sets a per-event context property on the logging event. + + The name of the context property. + The value of the context property. + + + + Sets multiple per-event context properties on the logging event. + + The properties to set. + + + + Sets the information of the logging event. + + The exception information of the logging event. + + + + Sets the timestamp of the logging event. + + The timestamp of the logging event. + + + + Sets the log message on the logging event. + + A to be written. + + + + Sets the log message and parameters for formatting for the logging event. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Sets the log message and parameters for formatting on the logging event. + + The type of the first argument. + The type of the second argument. + A containing format items. + The first argument to format. + The second argument to format. + + + + Sets the log message and parameters for formatting on the logging event. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing format items. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Sets the log message and parameters for formatting on the logging event. + + A containing format items. + Arguments to format. + + + + Sets the log message and parameters for formatting on the logging event. + + An object that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the log event to the underlying logger. + + The class of the caller to the method. This is captured by the NLog engine when necessary + The method or property name of the caller to the method. This is set at by the compiler. + The full path of the source file that contains the caller. This is set at by the compiler. + The line number in the source file at which the method is called. This is set at by the compiler. + + + + Writes the log event to the underlying logger. + + The log level. Optional but when assigned to then it will discard the LogEvent. + The method or property name of the caller to the method. This is set at by the compiler. + The full path of the source file that contains the caller. This is set at by the compiler. + The line number in the source file at which the method is called. This is set at by the compiler. + + + + Writes the log event to the underlying logger. + + Type of custom Logger wrapper. + + + + Represents the logging event. + + + + + Gets the date of the first log event created. + + + + + The formatted log message. + + + + + The log message including any parameter placeholders + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Log level. + Override default Logger name. Default is used when null + Log message including parameter placeholders. + + + + Initializes a new instance of the class. + + Log level. + Override default Logger name. Default is used when null + Log message including parameter placeholders. + Already parsed message template parameters. + + + + Initializes a new instance of the class. + + Log level. + Override default Logger name. Default is used when null + Pre-formatted log message for ${message}. + Log message-template including parameter placeholders for ${message:raw=true}. + Already parsed message template parameters. + + + + Initializes a new instance of the class. + + Log level. + Override default Logger name. Default is used when null + Log message. + List of event-properties + + + + Initializes a new instance of the class. + + Log level. + Override default Logger name. Default is used when null + An IFormatProvider that supplies culture-specific formatting information. + Log message including parameter placeholders. + Parameter array. + + + + Initializes a new instance of the class. + + Log level. + Override default Logger name. Default is used when null + An IFormatProvider that supplies culture-specific formatting information. + Log message including parameter placeholders. + Parameter array. + Exception information. + + + + Gets the unique identifier of log event which is automatically generated + and monotonously increasing. + + + + + Gets or sets the timestamp of the logging event. + + + + + Gets or sets the level of the logging event. + + + + + Gets a value indicating whether stack trace has been set for this event. + + + + + Gets the stack frame of the method that did the logging. + + + + + Gets the number index of the stack frame that represents the user + code (not the NLog code). + + + + + Gets the entire stack trace. + + + + + Gets the callsite class name + + + + + Gets the callsite member function name + + + + + Gets the callsite source file path + + + + + Gets the callsite source file line number + + + + + Gets or sets the exception information. + + + + + Gets or sets the logger name. + + + + + Gets or sets the log message including any parameter placeholders. + + + + + Gets or sets the parameter values or null if no parameters have been specified. + + + + + Gets or sets the format provider that was provided while logging or + when no formatProvider was specified. + + + + + Gets or sets the message formatter for generating + Uses string.Format(...) when nothing else has been configured. + + + + + Gets the formatted message. + + + + + Checks if any per-event properties (Without allocation) + + + + + Gets the dictionary of per-event context properties. + + + + + Gets the dictionary of per-event context properties. + Internal helper for the PropertiesDictionary type. + + Create the event-properties dictionary, even if no initial template parameters + Provided when having parsed the message template and capture template parameters (else null) + + + + + Gets the named parameters extracted from parsing as MessageTemplate + + + + + Creates the null event. + + Null log event. + + + + Creates the log event. + + The log level. + Override default Logger name. Default is used when null + The message. + Instance of . + + + + Creates the log event. + + The log level. + Override default Logger name. Default is used when null + The format provider. + The message. + The parameters. + Instance of . + + + + Creates the log event. + + The log level. + Override default Logger name. Default is used when null + The format provider. + The message. + Instance of . + + + + Creates the log event. + + The log level. + Override default Logger name. Default is used when null + The exception. + The format provider. + The message. + Instance of . + + + + Creates the log event. + + The log level. + Override default Logger name. Default is used when null + The exception. + The format provider. + The message. + The parameters. + Instance of . + + + + Creates from this by attaching the specified asynchronous continuation. + + The asynchronous continuation. + Instance of with attached continuation. + + + + Returns a string representation of this log event. + + String representation of the log event. + + + + Sets the stack trace for the event info. + + The stack trace. + Index of the first user stack frame within the stack trace (Negative means NLog should skip stackframes from System-assemblies). + + + + Sets the details retrieved from the Caller Information Attributes + + + + + + + + + Specialized LogFactory that can return instances of custom logger types. + + Use this only when a custom Logger type is defined. + The type of the logger to be returned. Must inherit from . + + + + Gets the logger with type . + + The logger name. + An instance of . + + + + Gets a custom logger with the full name of the current class (so namespace and class name) and type . + + An instance of . + This is a slow-running method. + Make sure you're not doing this in a loop. + + + + Creates and manages instances of objects. + + + + + Internal for unit tests + + + + + Overwrite possible file paths (including filename) for possible NLog config files. + When this property is null, the default file paths ( are used. + + + + + Occurs when logging changes. Both when assigned to new config or config unloaded. + + + Note can be null when unloading configuration at shutdown. + + + + + Obsolete and replaced by with NLog v5.2. + Occurs when logging gets reloaded. + + + + + Initializes static members of the LogManager class. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The config. + + + + Initializes a new instance of the class. + + The config loader + The custom AppEnvironmnet override + + + + Gets the current . + + + + + Gets or sets a value indicating whether exceptions should be thrown. See also . + + A value of true if exception should be thrown; otherwise, false. + By default exceptions are not thrown under any circumstances. + + + + Gets or sets a value indicating whether should be thrown. + + If null then is used. + + A value of true if exception should be thrown; otherwise, false. + + This option is for backwards-compatibility. + By default exceptions are not thrown under any circumstances. + + + + + Gets or sets a value indicating whether Variables should be kept on configuration reload. + + + + + Gets or sets a value indicating whether to automatically call + on AppDomain.Unload or AppDomain.ProcessExit + + + + + Gets or sets the current logging configuration. + + + Setter will re-configure all -objects, so no need to also call + + + + + Repository of interfaces used by NLog to allow override for dependency injection + + + + + Gets or sets the global log level threshold. Log events below this threshold are not logged. + + + + + Gets or sets the default culture info to use as . + + + Specific culture info or null to use + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting + unmanaged resources. + + + + + Begins configuration of the LogFactory options using fluent interface + + + + + Begins configuration of the LogFactory options using fluent interface + + + + + Creates a logger that discards all log messages. + + Null logger instance. + + + + Gets the logger with the full name of the current class, so namespace and class name. + + The logger. + This method introduces performance hit, because of StackTrace capture. + Make sure you are not calling this method in a loop. + + + + Gets the logger with the full name of the current class, so namespace and class name. + Use to create instance of a custom . + If you haven't defined your own class, then use the overload without the type parameter. + + The logger with type . + Type of the logger + This method introduces performance hit, because of StackTrace capture. + Make sure you are not calling this method in a loop. + + + + Gets a custom logger with the full name of the current class, so namespace and class name. + Use to create instance of a custom . + If you haven't defined your own class, then use the overload without the loggerType. + + The type of the logger to create. The type must inherit from + The logger of type . + This method introduces performance hit, because of StackTrace capture. + Make sure you are not calling this method in a loop. + + + + Gets the specified named logger. + + Name of the logger. + The logger reference. Multiple calls to GetLogger with the same argument + are not guaranteed to return the same logger reference. + + + + Gets the specified named logger. + Use to create instance of a custom . + If you haven't defined your own class, then use the overload without the type parameter. + + Name of the logger. + Type of the logger + The logger reference with type . Multiple calls to GetLogger with the same argument + are not guaranteed to return the same logger reference. + + + + Obsolete and replaced by with NLog v5.2. + Gets the specified named logger. + Use to create instance of a custom . + If you haven't defined your own class, then use the overload without the loggerType. + + Name of the logger. + The type of the logger to create. The type must inherit from . + The logger of type . Multiple calls to GetLogger with the + same argument aren't guaranteed to return the same logger reference. + + + + Loops through all loggers previously returned by GetLogger and recalculates their + target and filter list. Useful after modifying the configuration programmatically + to ensure that all loggers have been properly configured. + + + + + Loops through all loggers previously returned by GetLogger and recalculates their + target and filter list. Useful after modifying the configuration programmatically + to ensure that all loggers have been properly configured. + + Purge garbage collected logger-items from the cache + + + + Flush any pending log messages (in case of asynchronous targets) with the default timeout of 15 seconds. + + + + + Flush any pending log messages (in case of asynchronous targets). + + Maximum time to allow for the flush. Any messages after that time + will be discarded. + + + + Flush any pending log messages (in case of asynchronous targets). + + Maximum time to allow for the flush. Any messages + after that time will be discarded. + + + + Flush any pending log messages (in case of asynchronous targets). + + The asynchronous continuation. + + + + Flush any pending log messages (in case of asynchronous targets). + + The asynchronous continuation. + Maximum time to allow for the flush. Any messages + after that time will be discarded. + + + + Flush any pending log messages (in case of asynchronous targets). + + The asynchronous continuation. + Maximum time to allow for the flush. Any messages after that time will be discarded. + + + + Flushes any pending log messages on all appenders. + + Config containing Targets to Flush + Flush completed notification (success / timeout) + Optional timeout that guarantees that completed notification is called. + + + + + Suspends the logging, and returns object for using-scope so scope-exit calls + + + Logging is suspended when the number of calls are greater + than the number of calls. + + An object that implements IDisposable whose Dispose() method re-enables logging. + To be used with C# using () statement. + + + + Resumes logging if having called . + + + Logging is suspended when the number of calls are greater + than the number of calls. + + + + + Returns if logging is currently enabled. + + + Logging is suspended when the number of calls are greater + than the number of calls. + + A value of if logging is currently enabled, + otherwise. + + + + Raises the event when the configuration is reloaded. + + Event arguments. + + + + Raises the event when the configuration is reloaded. + + Event arguments + + + + Currently this is disposing? + + + + + Releases unmanaged and - optionally - managed resources. + + True to release both managed and unmanaged resources; + false to release only unmanaged resources. + + + + Dispose all targets, and shutdown logging. + + + + + Get file paths (including filename) for the possible NLog config files. + + The file paths to the possible config file + + + + Get file paths (including filename) for the possible NLog config files. + + The file paths to the possible config file + + + + Overwrite the candidates paths (including filename) for the possible NLog config files. + + The file paths to the possible config file + + + + Clear the candidate file paths and return to the defaults. + + + + + Loads logging configuration from file (Currently only XML configuration files supported) + + Configuration file to be read + LogFactory instance for fluent interface + + + + Logger cache key. + + + + + Serves as a hash function for a particular type. + + + + + Determines if two objects are equal in value. + + Other object to compare to. + True if objects are equal, false otherwise. + + + + Determines if two objects of the same type are equal in value. + + Other object to compare to. + True if objects are equal, false otherwise. + + + + Logger cache. + + + + + Inserts or updates. + + + + + + + Loops through all cached loggers and removes dangling loggers that have been garbage collected. + + + + + Internal for unit tests + + + + + Enables logging in implementation. + + + + + Initializes a new instance of the class. + + The factory. + + + + Enables logging. + + + + + Logging methods which only are executed when the DEBUG conditional compilation symbol is set. + + Remarks: + The DEBUG conditional compilation symbol is default enabled (only) in a debug build. + + If the DEBUG conditional compilation symbol isn't set in the calling library, the compiler will remove all the invocations to these methods. + This could lead to better performance. + + See: https://msdn.microsoft.com/en-us/library/4xssyw96%28v=vs.90%29.aspx + + + Provides logging interface and utility functions. + + + Auto-generated Logger members for binary compatibility with NLog 1.0. + + + Provides logging interface and utility functions. + + + + + Writes the diagnostic message at the Debug level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message and exception at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters and formatting them with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + Log message. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Debug level using the specified parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameter. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified arguments formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified arguments formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + A to be written. + + + + Writes the diagnostic message at the Debug level. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Trace level. + Only executed when the DEBUG conditional compilation symbol is set. + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Trace level. + Only executed when the DEBUG conditional compilation symbol is set. + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Trace level. + Only executed when the DEBUG conditional compilation symbol is set. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message and exception at the Trace level. + Only executed when the DEBUG conditional compilation symbol is set. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Trace level. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters and formatting them with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Trace level. + Only executed when the DEBUG conditional compilation symbol is set. + Log message. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Trace level using the specified parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameter. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified arguments formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Trace level using the specified arguments formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Trace level. + Only executed when the DEBUG conditional compilation symbol is set. + A to be written. + + + + Writes the diagnostic message at the Trace level. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + Only executed when the DEBUG conditional compilation symbol is set. + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + Only executed when the DEBUG conditional compilation symbol is set. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + Only executed when the DEBUG conditional compilation symbol is set. + A containing one format item. + The argument to format. + + + + Gets a value indicating whether logging is enabled for the Trace level. + + A value of if logging is enabled for the Trace level, otherwise it returns . + + + + Gets a value indicating whether logging is enabled for the Debug level. + + A value of if logging is enabled for the Debug level, otherwise it returns . + + + + Gets a value indicating whether logging is enabled for the Info level. + + A value of if logging is enabled for the Info level, otherwise it returns . + + + + Gets a value indicating whether logging is enabled for the Warn level. + + A value of if logging is enabled for the Warn level, otherwise it returns . + + + + Gets a value indicating whether logging is enabled for the Error level. + + A value of if logging is enabled for the Error level, otherwise it returns . + + + + Gets a value indicating whether logging is enabled for the Fatal level. + + A value of if logging is enabled for the Fatal level, otherwise it returns . + + + + Writes the diagnostic message at the Trace level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Trace level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Trace level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Trace level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message at the Trace level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Trace level. + + Log message. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Writes the diagnostic message and exception at the Trace level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Trace level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Trace level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Trace level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Trace level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Debug level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Debug level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Debug level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Debug level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message at the Debug level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Debug level. + + Log message. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Writes the diagnostic message and exception at the Debug level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Debug level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Debug level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Debug level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Info level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Info level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Info level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Info level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message at the Info level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Info level. + + Log message. + + + + Writes the diagnostic message at the Info level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Writes the diagnostic message and exception at the Info level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Info level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Info level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Info level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Info level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Info level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Info level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Warn level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Warn level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Warn level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Warn level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message at the Warn level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Warn level. + + Log message. + + + + Writes the diagnostic message at the Warn level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Writes the diagnostic message and exception at the Warn level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Warn level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Warn level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Warn level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Warn level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Warn level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Warn level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Error level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Error level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Error level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Error level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message at the Error level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Error level. + + Log message. + + + + Writes the diagnostic message at the Error level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Writes the diagnostic message and exception at the Error level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Error level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Error level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Error level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Error level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Error level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Error level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified format provider and format parameters. + + + Writes the diagnostic message at the Fatal level. + + Type of the value. + The value to be written. + + + + Writes the diagnostic message at the Fatal level. + + Type of the value. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the Fatal level. + + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message at the Fatal level using the specified parameters and formatting them with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the Fatal level. + + Log message. + + + + Writes the diagnostic message at the Fatal level using the specified parameters. + + A containing format items. + Arguments to format. + + + + Writes the diagnostic message and exception at the Fatal level. + + A to be written. + An exception to be logged. + + + + Writes the diagnostic message and exception at the Fatal level. + + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message and exception at the Fatal level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + An exception to be logged. + Arguments to format. + + + + Writes the diagnostic message at the Fatal level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified parameter. + + The type of the argument. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified parameters. + + The type of the first argument. + The type of the second argument. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the specified level. + + The log level. + A to be written. + + + + Writes the diagnostic message at the specified level. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the specified level using the specified parameters. + + The log level. + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the specified level using the specified parameters. + + The log level. + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter and formatting it with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified value as a parameter. + + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level. + + A to be written. + + + + Writes the diagnostic message at the Trace level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Trace level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Trace level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level. + + A to be written. + + + + Writes the diagnostic message at the Debug level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Debug level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Debug level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level. + + A to be written. + + + + Writes the diagnostic message at the Info level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Info level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Info level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Info level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level. + + A to be written. + + + + Writes the diagnostic message at the Warn level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Warn level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Warn level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Warn level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level. + + A to be written. + + + + Writes the diagnostic message at the Error level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Error level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Error level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Error level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level. + + A to be written. + + + + Writes the diagnostic message at the Fatal level. + + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + + + + Writes the diagnostic message at the Fatal level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified parameters. + + A containing format items. + First argument to format. + Second argument to format. + Third argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter and formatting it with the supplied format provider. + + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the Fatal level using the specified value as a parameter. + + A containing one format item. + The argument to format. + + + + + + + + + + + + + + + + + + + + + + Initializes a new instance of the class. + + + + + Occurs when logger configuration changes. + + + + + Gets the name of the logger. + + + + + Gets the factory that created this logger. + + + + + Collection of context properties for the Logger. The logger will append it for all log events + + + It is recommended to use for modifying context properties + when same named logger is used at multiple locations or shared by different thread contexts. + + + + + Gets a value indicating whether logging is enabled for the specified level. + + Log level to be checked. + A value of if logging is enabled for the specified level, otherwise it returns . + + + + Creates new logger that automatically appends the specified property to all log events (without changing current logger) + + With property, all properties can be enumerated. + + Property Name + Property Value + New Logger object that automatically appends specified property + + + + Creates new logger that automatically appends the specified properties to all log events (without changing current logger) + + With property, all properties can be enumerated. + + Collection of key-value pair properties + New Logger object that automatically appends specified properties + + + + Obsolete and replaced by that prevents unexpected side-effects in Logger-state. + + Updates the specified context property for the current logger. The logger will append it for all log events. + + With property, all properties can be enumerated (or updated). + + + It is highly recommended to ONLY use for modifying context properties. + This method will affect all locations/contexts that makes use of the same named logger object. And can cause + unexpected surprises at multiple locations and other thread contexts. + + Property Name + Property Value + + + + Updates the with provided property + + Name of property + Value of property + A disposable object that removes the properties from logical context scope on dispose. + property-dictionary-keys are case-insensitive + + + + Updates the with provided property + + Name of property + Value of property + A disposable object that removes the properties from logical context scope on dispose. + property-dictionary-keys are case-insensitive + + + + Updates the with provided properties + + Properties being added to the scope dictionary + A disposable object that removes the properties from logical context scope on dispose. + property-dictionary-keys are case-insensitive + + + + Updates the with provided properties + + Properties being added to the scope dictionary + A disposable object that removes the properties from logical context scope on dispose. + property-dictionary-keys are case-insensitive + + + + Pushes new state on the logical context scope stack + + Value to added to the scope stack + A disposable object that pops the nested scope state on dispose. + + + + Pushes new state on the logical context scope stack + + Value to added to the scope stack + A disposable object that pops the nested scope state on dispose. + + + + Writes the specified diagnostic message. + + Log event. + + + + Writes the specified diagnostic message. + + Type of custom Logger wrapper. + Log event. + + + + Writes the diagnostic message at the specified level using the specified format provider and format parameters. + + + Writes the diagnostic message at the specified level. + + Type of the value. + The log level. + The value to be written. + + + + Writes the diagnostic message at the specified level. + + Type of the value. + The log level. + An IFormatProvider that supplies culture-specific formatting information. + The value to be written. + + + + Writes the diagnostic message at the specified level. + + The log level. + A function returning message to be written. Function is not evaluated if logging is not enabled. + + + + Writes the diagnostic message at the specified level using the specified parameters and formatting them with the supplied format provider. + + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message at the specified level. + + The log level. + Log message. + + + + Writes the diagnostic message at the specified level using the specified parameters. + + The log level. + A containing format items. + Arguments to format. + + + + Writes the diagnostic message and exception at the specified level. + + The log level. + An exception to be logged. + A to be written. + Arguments to format. + + + + Writes the diagnostic message and exception at the specified level. + + The log level. + An exception to be logged. + An IFormatProvider that supplies culture-specific formatting information. + A to be written. + Arguments to format. + + + + Writes the diagnostic message at the specified level using the specified parameter and formatting it with the supplied format provider. + + The type of the argument. + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified parameter. + + The type of the argument. + The log level. + A containing one format item. + The argument to format. + + + + Writes the diagnostic message at the specified level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the specified level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The log level. + A containing one format item. + The first argument to format. + The second argument to format. + + + + Writes the diagnostic message at the specified level using the specified arguments formatting it with the supplied format provider. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + The log level. + An IFormatProvider that supplies culture-specific formatting information. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Writes the diagnostic message at the specified level using the specified parameters. + + The type of the first argument. + The type of the second argument. + The type of the third argument. + The log level. + A containing one format item. + The first argument to format. + The second argument to format. + The third argument to format. + + + + Runs the provided action. If the action throws, the exception is logged at Error level. The exception is not propagated outside of this method. + + Action to execute. + + + + Runs the provided function and returns its result. If an exception is thrown, it is logged at Error level. + The exception is not propagated outside of this method; a default value is returned instead. + + Return type of the provided function. + Function to run. + Result returned by the provided function or the default value of type in case of exception. + + + + Runs the provided function and returns its result. If an exception is thrown, it is logged at Error level. + The exception is not propagated outside of this method; a fallback value is returned instead. + + Return type of the provided function. + Function to run. + Fallback value to return in case of exception. + Result returned by the provided function or fallback value in case of exception. + + + + Logs an exception is logged at Error level if the provided task does not run to completion. + + The task for which to log an error if it does not run to completion. + This method is useful in fire-and-forget situations, where application logic does not depend on completion of task. This method is avoids C# warning CS4014 in such situations. + + + + Returns a task that completes when a specified task to completes. If the task does not run to completion, an exception is logged at Error level. The returned task always runs to completion. + + The task for which to log an error if it does not run to completion. + A task that completes in the state when completes. + + + + Runs async action. If the action throws, the exception is logged at Error level. The exception is not propagated outside of this method. + + Async action to execute. + + + + Runs the provided async function and returns its result. If the task does not run to completion, an exception is logged at Error level. + The exception is not propagated outside of this method; a default value is returned instead. + + Return type of the provided function. + Async function to run. + A task that represents the completion of the supplied task. If the supplied task ends in the state, the result of the new task will be the result of the supplied task; otherwise, the result of the new task will be the default value of type . + + + + Runs the provided async function and returns its result. If the task does not run to completion, an exception is logged at Error level. + The exception is not propagated outside of this method; a fallback value is returned instead. + + Return type of the provided function. + Async function to run. + Fallback value to return if the task does not end in the state. + A task that represents the completion of the supplied task. If the supplied task ends in the state, the result of the new task will be the result of the supplied task; otherwise, the result of the new task will be the fallback value. + + + + Raises the event when the logger is reconfigured. + + Event arguments + + + + Implementation of logging engine. + + + + + Gets the filter result. + + The filter chain. + The log event. + default result if there are no filters, or none of the filters decides. + The result of the filter. + + + + Defines available log levels. + + + Log levels ordered by severity:
+ - (Ordinal = 0) : Most verbose level. Used for development and seldom enabled in production.
+ - (Ordinal = 1) : Debugging the application behavior from internal events of interest.
+ - (Ordinal = 2) : Information that highlights progress or application lifetime events.
+ - (Ordinal = 3) : Warnings about validation issues or temporary failures that can be recovered.
+ - (Ordinal = 4) : Errors where functionality has failed or have been caught.
+ - (Ordinal = 5) : Most critical level. Application is about to abort.
+
+
+ + + Trace log level (Ordinal = 0) + + + Most verbose level. Used for development and seldom enabled in production. + + + + + Debug log level (Ordinal = 1) + + + Debugging the application behavior from internal events of interest. + + + + + Info log level (Ordinal = 2) + + + Information that highlights progress or application lifetime events. + + + + + Warn log level (Ordinal = 3) + + + Warnings about validation issues or temporary failures that can be recovered. + + + + + Error log level (Ordinal = 4) + + + Errors where functionality has failed or have been caught. + + + + + Fatal log level (Ordinal = 5) + + + Most critical level. Application is about to abort. + + + + + Off log level (Ordinal = 6) + + + + + Gets all the available log levels (Trace, Debug, Info, Warn, Error, Fatal, Off). + + + + + Gets all the log levels that can be used to log events (Trace, Debug, Info, Warn, Error, Fatal) + i.e LogLevel.Off is excluded. + + + + + Initializes a new instance of . + + The log level name. + The log level ordinal number. + + + + Gets the name of the log level. + + + + + Gets the ordinal of the log level. + + + + + Compares two objects + and returns a value indicating whether + the first one is equal to the second one. + + The first level. + The second level. + The value of level1.Ordinal == level2.Ordinal. + + + + Compares two objects + and returns a value indicating whether + the first one is not equal to the second one. + + The first level. + The second level. + The value of level1.Ordinal != level2.Ordinal. + + + + Compares two objects + and returns a value indicating whether + the first one is greater than the second one. + + The first level. + The second level. + The value of level1.Ordinal > level2.Ordinal. + + + + Compares two objects + and returns a value indicating whether + the first one is greater than or equal to the second one. + + The first level. + The second level. + The value of level1.Ordinal >= level2.Ordinal. + + + + Compares two objects + and returns a value indicating whether + the first one is less than the second one. + + The first level. + The second level. + The value of level1.Ordinal < level2.Ordinal. + + + + Compares two objects + and returns a value indicating whether + the first one is less than or equal to the second one. + + The first level. + The second level. + The value of level1.Ordinal <= level2.Ordinal. + + + + Gets the that corresponds to the specified ordinal. + + The ordinal. + The instance. For 0 it returns , 1 gives and so on. + + + + Returns the that corresponds to the supplied . + + The textual representation of the log level. + The enumeration value. + + + + Returns a string representation of the log level. + + Log level name. + + + + + + + + + + Determines whether the specified instance is equal to this instance. + + The to compare with this instance. + Value of true if the specified is equal to + this instance; otherwise, false. + + + + Compares the level to the other object. + + The other object. + + A value less than zero when this logger's is + less than the other logger's ordinal, 0 when they are equal and + greater than zero when this ordinal is greater than the + other ordinal. + + + + + Compares the level to the other object. + + The other object. + + A value less than zero when this logger's is + less than the other logger's ordinal, 0 when they are equal and + greater than zero when this ordinal is greater than the + other ordinal. + + + + + Creates and manages instances of objects. + + + LogManager wraps a singleton instance of . + + + + + Internal for unit tests + + + + + Gets the instance used in the . + + Could be used to pass the to other methods + + + + Occurs when logging changes. Both when assigned to new config or config unloaded. + + + Note can be null when unloading configuration at shutdown. + + + + + Obsolete and replaced by with NLog v5.2. + Occurs when logging gets reloaded. + + + + + Gets or sets a value indicating whether NLog should throw exceptions. + By default exceptions are not thrown under any circumstances. + + + + + Gets or sets a value indicating whether should be thrown. + + A value of true if exception should be thrown; otherwise, false. + + This option is for backwards-compatibility. + By default exceptions are not thrown under any circumstances. + + + + + + Gets or sets a value indicating whether Variables should be kept on configuration reload. + + + + + Gets or sets a value indicating whether to automatically call + on AppDomain.Unload or AppDomain.ProcessExit + + + + + Gets or sets the current logging configuration. + + + Setter will re-configure all -objects, so no need to also call + + + + + Begins configuration of the LogFactory options using fluent interface + + + + + Begins configuration of the LogFactory options using fluent interface + + + + + Obsolete and replaced by and with NLog v5.2. + Loads logging configuration from file (Only XML configuration files supported) + + Configuration file to be read + LogFactory instance for fluent interface + + + + Gets or sets the global log threshold. Log events below this threshold are not logged. + + + + + Gets the logger with the full name of the current class, so namespace and class name. + + The logger. + This is a slow-running method. + Make sure you're not doing this in a loop. + + + + Adds the given assembly which will be skipped + when NLog is trying to find the calling method on stack trace. + + The assembly to skip. + + + + Obsolete and replaced by with NLog v5.2. + Gets a custom logger with the full name of the current class, so namespace and class name. + Use to create instance of a custom . + If you haven't defined your own class, then use the overload without the loggerType. + + The logger class. This class must inherit from . + The logger of type . + This is a slow-running method. + Make sure you're not doing this in a loop. + + + + Creates a logger that discards all log messages. + + Null logger which discards all log messages. + + + + Gets the specified named logger. + + Name of the logger. + The logger reference. Multiple calls to GetLogger with the same argument aren't guaranteed to return the same logger reference. + + + + Obsolete and replaced by with NLog v5.2. + Gets the specified named custom using the parameter for creating instance. + If you haven't defined your own class, then use the overload without the loggerType. + + Name of the logger. + The logger class. This class must inherit from . + The logger of type . Multiple calls to GetLogger with the same argument aren't guaranteed to return the same logger reference. + The generic way for this method is + + + + Loops through all loggers previously returned by GetLogger. + and recalculates their target and filter list. Useful after modifying the configuration programmatically + to ensure that all loggers have been properly configured. + + + + + Loops through all loggers previously returned by GetLogger. + and recalculates their target and filter list. Useful after modifying the configuration programmatically + to ensure that all loggers have been properly configured. + + Purge garbage collected logger-items from the cache + + + + Flush any pending log messages (in case of asynchronous targets) with the default timeout of 15 seconds. + + + + + Flush any pending log messages (in case of asynchronous targets). + + Maximum time to allow for the flush. Any messages after that time will be discarded. + + + + Flush any pending log messages (in case of asynchronous targets). + + Maximum time to allow for the flush. Any messages after that time will be discarded. + + + + Flush any pending log messages (in case of asynchronous targets). + + The asynchronous continuation. + + + + Flush any pending log messages (in case of asynchronous targets). + + The asynchronous continuation. + Maximum time to allow for the flush. Any messages after that time will be discarded. + + + + Flush any pending log messages (in case of asynchronous targets). + + The asynchronous continuation. + Maximum time to allow for the flush. Any messages after that time will be discarded. + + + + Obsolete and replaced by by with NLog v5. + Suspends the logging, and returns object for using-scope so scope-exit calls + + + Logging is suspended when the number of calls are greater + than the number of calls. + + An object that implements IDisposable whose Dispose() method re-enables logging. + To be used with C# using () statement. + + + + Obsolete and replaced by disposing the scope returned from with NLog v5. + Resumes logging if having called . + + + Logging is suspended when the number of calls are greater + than the number of calls. + + + + + Suspends the logging, and returns object for using-scope so scope-exit calls + + + Logging is suspended when the number of calls are greater + than the number of calls. + + An object that implements IDisposable whose Dispose() method re-enables logging. + To be used with C# using () statement. + + + + Resumes logging if having called . + + + Logging is suspended when the number of calls are greater + than the number of calls. + + + + + Returns if logging is currently enabled. + + + Logging is suspended when the number of calls are greater + than the number of calls. + + A value of if logging is currently enabled, + otherwise. + + + + Dispose all targets, and shutdown logging. + + + + + Generates a formatted message from the log event + + Log event. + Formatted message + + + + Returns a log message. Used to defer calculation of + the log message until it's actually needed. + + Log message. + + + + The type of the captured hole + + + + + Not decided + + + + + normal {x} + + + + + Serialize operator {@x} (aka destructure) + + + + + stringification operator {$x} + + + + + A hole that will be replaced with a value + + + + + Constructor + + + + Parameter name sent to structured loggers. + This is everything between "{" and the first of ",:}". + Including surrounding spaces and names that are numbers. + + + Format to render the parameter. + This is everything between ":" and the first unescaped "}" + + + + Type + + + + When the template is positional, this is the parsed name of this parameter. + For named templates, the value of Index is undefined. + + + Alignment to render the parameter, by default 0. + This is the parsed value between "," and the first of ":}" + + + + A fixed value + + + + Number of characters from the original template to copy at the current position. + This can be 0 when the template starts with a hole or when there are multiple consecutive holes. + + + Number of characters to skip in the original template at the current position. + 0 is a special value that mean: 1 escaped char, no hole. It can also happen last when the template ends with a literal. + + + + Combines Literal and Hole + + + + Literal + + + Hole + Uninitialized when = 0. + + + + Description of a single parameter extracted from a MessageTemplate + + + + + Parameter Name extracted from + This is everything between "{" and the first of ",:}". + + + + + Parameter Value extracted from the -array + + + + + Format to render the parameter. + This is everything between ":" and the first unescaped "}" + + + + + Parameter method that should be used to render the parameter + See also + + + + + Returns index for , when + + + + + Constructs a single message template parameter + + Parameter Name + Parameter Value + Parameter Format + + + + Constructs a single message template parameter + + Parameter Name + Parameter Value + Parameter Format + Parameter CaptureType + + + + Parameters extracted from parsing as MessageTemplate + + + + + + + + + + + Gets the parameters at the given index + + + + + Number of parameters + + + + Indicates whether the template should be interpreted as positional + (all holes are numbers) or named. + + + + Indicates whether the template was parsed successful, and there are no unmatched parameters + + + + + Constructor for parsing the message template with parameters + + including any parameter placeholders + All + + + + Constructor for named parameters that already has been parsed + + + + + Create MessageTemplateParameter from + + + + + Parse templates. + + + + + Parse a template. + + Template to be parsed. + When is null. + Template, never null + + + + Gets the current literal/hole in the template + + + + + Clears the enumerator + + + + + Restarts the enumerator of the template + + + + + Moves to the next literal/hole in the template + + Found new element [true/false] + + + + Parse format after hole name/index. Handle the escaped { and } in the format. Don't read the last } + + + + + + Error when parsing a template. + + + + + Current index when the error occurred. + + + + + The template we were parsing + + + + + New exception + + The message to be shown. + Current index when the error occurred. + + + + + Convert, Render or serialize a value, with optionally backwards-compatible with + + + + + Serialization of an object, e.g. JSON and append to + + The object to serialize to string. + Parameter Format + Parameter CaptureType + An object that supplies culture-specific formatting information. + Output destination. + Serialize succeeded (true/false) + + + + Format an object to a readable string, or if it's an object, serialize + + The value to convert + + + + + + + + Try serializing a scalar (string, int, NULL) or simple type (IFormattable) + + + + + Serialize Dictionary as JSON like structure, without { and } + + + "FirstOrder"=true, "Previous login"=20-12-2017 14:55:32, "number of tries"=1 + + + format string of an item + + + + + + + + + Convert a value to a string with format and append to . + + The value to convert. + Format sting for the value. + Format provider for the value. + Append to this + + + + Exception thrown during NLog configuration. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The message. + + + + Obsolete and replaced by using normal string-interpolation with in NLog v5. + Initializes a new instance of the class. + + The message. + Parameters for the message + + + + Obsolete and replaced by using normal string-interpolation with in NLog v5. + Initializes a new instance of the class. + + The inner exception. + The message. + Parameters for the message + + + + Initializes a new instance of the class. + + The message. + The inner exception. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + + The parameter is null. + + + The class name is null or is zero (0). + + + + + Exception thrown during log event processing. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The message. + + + + Obsolete and replaced by using normal string-interpolation with in NLog v5. + Initializes a new instance of the class. + + The message. + Parameters for the message + + + + Initializes a new instance of the class. + + The message. + The inner exception. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + + The parameter is null. + + + The class name is null or is zero (0). + + + + + TraceListener which routes all messages through NLog. + + + + + Initializes a new instance of the class. + + + + + Gets or sets the log factory to use when outputting messages (null - use LogManager). + + + + + Gets or sets the default log level. + + + + + Gets or sets the log which should be always used regardless of source level. + + + + + Gets or sets a value indicating whether flush calls from trace sources should be ignored. + + + + + Gets a value indicating whether the trace listener is thread safe. + + + true if the trace listener is thread safe; otherwise, false. The default is false. + + + + Gets or sets a value indicating whether to use auto logger name detected from the stack trace. + + + + + When overridden in a derived class, writes the specified message to the listener you create in the derived class. + + A message to write. + + + + When overridden in a derived class, writes a message to the listener you create in the derived class, followed by a line terminator. + + A message to write. + + + + When overridden in a derived class, closes the output stream so it no longer receives tracing or debugging output. + + + + + Emits an error message. + + A message to emit. + + + + Emits an error message and a detailed error message. + + A message to emit. + A detailed message to emit. + + + + Flushes the output (if is not true) buffer with the default timeout of 15 seconds. + + + + + Writes trace information, a data object and event information to the listener specific output. + + A object that contains the current process ID, thread ID, and stack trace information. + A name used to identify the output, typically the name of the application that generated the trace event. + One of the values specifying the type of event that has caused the trace. + A numeric identifier for the event. + The trace data to emit. + + + + Writes trace information, an array of data objects and event information to the listener specific output. + + A object that contains the current process ID, thread ID, and stack trace information. + A name used to identify the output, typically the name of the application that generated the trace event. + One of the values specifying the type of event that has caused the trace. + A numeric identifier for the event. + An array of objects to emit as data. + + + + Writes trace and event information to the listener specific output. + + A object that contains the current process ID, thread ID, and stack trace information. + A name used to identify the output, typically the name of the application that generated the trace event. + One of the values specifying the type of event that has caused the trace. + A numeric identifier for the event. + + + + Writes trace information, a formatted array of objects and event information to the listener specific output. + + A object that contains the current process ID, thread ID, and stack trace information. + A name used to identify the output, typically the name of the application that generated the trace event. + One of the values specifying the type of event that has caused the trace. + A numeric identifier for the event. + A format string that contains zero or more format items, which correspond to objects in the array. + An object array containing zero or more objects to format. + + + + Writes trace information, a message, and event information to the listener specific output. + + A object that contains the current process ID, thread ID, and stack trace information. + A name used to identify the output, typically the name of the application that generated the trace event. + One of the values specifying the type of event that has caused the trace. + A numeric identifier for the event. + A message to write. + + + + Writes trace information, a message, a related activity identity and event information to the listener specific output. + + A object that contains the current process ID, thread ID, and stack trace information. + A name used to identify the output, typically the name of the application that generated the trace event. + A numeric identifier for the event. + A message to write. + A object identifying a related activity. + + + + Gets the custom attributes supported by the trace listener. + + + A string array naming the custom attributes supported by the trace listener, or null if there are no custom attributes. + + + + + Translates the event type to level from . + + Type of the event. + Translated log level. + + + + Process the log event + The log level. + The name of the logger. + The log message. + The log parameters. + The event id. + The event type. + The related activity id. + + + + + It works as a normal but it discards all messages which an application requests + to be logged. + + It effectively implements the "Null Object" pattern for objects. + + + + + Initializes a new instance of . + + The factory class to be used for the creation of this logger. + + + + Extension methods to setup LogFactory options + + + + + Gets the logger with the full name of the current class, so namespace and class name. + + + + + Gets the specified named logger. + + + + + Configures general options for NLog LogFactory before loading NLog config + + + + + Configures loading of NLog extensions for Targets and LayoutRenderers + + + + + Configures the output of NLog for diagnostics / troubleshooting + + + + + Configures serialization and transformation of LogEvents + + + + + Loads NLog config created by the method + + + + + Loads NLog config provided in + + + + + Loads NLog config from filename if provided, else fallback to scanning for NLog.config + + Fluent interface parameter. + Explicit configuration file to be read (Default NLog.config from candidates paths) + Whether to allow application to run when NLog config is not available + + + + Loads NLog config from file-paths if provided, else fallback to scanning for NLog.config + + Fluent interface parameter. + Candidates file paths (including filename) where to scan for NLog config files + Whether to allow application to run when NLog config is not available + + + + Loads NLog config from XML in + + + + + Loads NLog config located in embedded resource from main application assembly. + + Fluent interface parameter. + Assembly for the main Application project with embedded resource + Name of the manifest resource for NLog config XML + + + + Reloads the current logging configuration and activates it + + Logevents produced during the configuration-reload can become lost, as targets are unavailable while closing and initializing. + + + + Extension methods to setup NLog extensions, so they are known when loading NLog LoggingConfiguration + + + + + Enable/disables autoloading of NLog extensions by scanning and loading available assemblies + + + Disabled by default as it can give a huge performance hit during startup. Recommended to keep it disabled especially when running in the cloud. + + + + + Enable/disables autoloading of NLog extensions by scanning and loading available assemblies + + + Disabled by default as it can give a huge performance hit during startup. Recommended to keep it disabled especially when running in the cloud. + + + + + Registers NLog extensions from the assembly. + + + + + Registers NLog extensions from the assembly type name + + + + + Register a custom NLog Configuration Type. + + Type of the NLog configuration item + Fluent interface parameter. + + + + Register a custom NLog Target. + + Type of the Target. + Fluent interface parameter. + The target type-alias for use in NLog configuration. Will extract from class-attribute when unassigned. + + + + Register a custom NLog Target. + + Type of the Target. + Fluent interface parameter. + The factory method for creating instance of NLog Target + The target type-alias for use in NLog configuration. Will extract from class-attribute when unassigned. + + + + Register a custom NLog Target. + + Fluent interface parameter. + Type name of the Target + The target type-alias for use in NLog configuration + + + + Register a custom NLog Layout. + + Type of the layout renderer. + Fluent interface parameter. + The layout type-alias for use in NLog configuration. Will extract from class-attribute when unassigned. + + + + Register a custom NLog Layout. + + Type of the layout renderer. + Fluent interface parameter. + The factory method for creating instance of NLog Layout + The layout type-alias for use in NLog configuration. Will extract from class-attribute when unassigned. + + + + Register a custom NLog Layout. + + Fluent interface parameter. + Type of the layout. + The layout type-alias for use in NLog configuration + + + + Register a custom NLog LayoutRenderer. + + Type of the layout renderer. + Fluent interface parameter. + The layout-renderer type-alias for use in NLog configuration - without '${ }'. Will extract from class-attribute when unassigned. + + + + Register a custom NLog LayoutRenderer. + + Type of the layout renderer. + Fluent interface parameter. + The factory method for creating instance of NLog LayoutRenderer + The layout-renderer type-alias for use in NLog configuration - without '${ }'. Will extract from class-attribute when unassigned. + + + + Register a custom NLog LayoutRenderer. + + Fluent interface parameter. + Type of the layout renderer. + The layout-renderer type-alias for use in NLog configuration - without '${ }' + + + + Register a custom NLog LayoutRenderer with a callback function . The callback receives the logEvent. + + Fluent interface parameter. + The layout-renderer type-alias for use in NLog configuration - without '${ }' + Callback that returns the value for the layout renderer. + + + + Register a custom NLog LayoutRenderer with a callback function . The callback receives the logEvent and the current configuration. + + Fluent interface parameter. + The layout-renderer type-alias for use in NLog configuration - without '${ }' + Callback that returns the value for the layout renderer. + + + + Register a custom NLog LayoutRenderer with a callback function . The callback receives the logEvent. + + Fluent interface parameter. + The layout-renderer type-alias for use in NLog configuration - without '${ }' + Callback that returns the value for the layout renderer. + Options of the layout renderer. + + + + Register a custom NLog LayoutRenderer with a callback function . The callback receives the logEvent and the current configuration. + + Fluent interface parameter. + The layout-renderer type-alias for use in NLog configuration - without '${ }' + Callback that returns the value for the layout renderer. + Options of the layout renderer. + + + + Register a custom NLog LayoutRenderer with a callback function + + Fluent interface parameter. + LayoutRenderer instance with type-alias and callback-method. + + + + Register a custom condition method, that can use in condition filters + + Fluent interface parameter. + Name of the condition filter method + MethodInfo extracted by reflection - typeof(MyClass).GetMethod("MyFunc", BindingFlags.Static). + + + + Register a custom condition method, that can use in condition filters + + Fluent interface parameter. + Name of the condition filter method + Lambda method. + + + + Register a custom condition method, that can use in condition filters + + Fluent interface parameter. + Name of the condition filter method + Lambda method. + + + + Register (or replaces) singleton-object for the specified service-type + + Service interface type + Fluent interface parameter. + Implementation of interface. + + + + Register (or replaces) singleton-object for the specified service-type + + Fluent interface parameter. + Service interface type. + Implementation of interface. + + + + Register (or replaces) external service-repository for resolving dependency injection + + Fluent interface parameter. + External dependency injection repository + + + + Extension methods to setup NLog options + + + + + Configures + + + + + Configures + + + + + Configures + + + + + Configures + + + + + Configures + + + + + Configures + + + + + Configures + + + + + Configure the InternalLogger properties from Environment-variables and App.config using + + + Recognizes the following environment-variables: + + - NLOG_INTERNAL_LOG_LEVEL + - NLOG_INTERNAL_LOG_FILE + - NLOG_INTERNAL_LOG_TO_CONSOLE + - NLOG_INTERNAL_LOG_TO_CONSOLE_ERROR + - NLOG_INTERNAL_LOG_TO_TRACE + - NLOG_INTERNAL_INCLUDE_TIMESTAMP + + Legacy .NetFramework platform will also recognizes the following app.config settings: + + - nlog.internalLogLevel + - nlog.internalLogFile + - nlog.internalLogToConsole + - nlog.internalLogToConsoleError + - nlog.internalLogToTrace + - nlog.internalLogIncludeTimestamp + + + + + Extension methods to setup NLog + + + + + Configures the global time-source used for all logevents + + + Available by default: , , , + + + + + Updates the dictionary ${gdc:item=} with the name-value-pair + + + + + Defines for redirecting output from matching to wanted targets. + + Fluent interface parameter. + Logger name pattern to check which names matches this rule + Rule identifier to allow rule lookup + + + + Defines for redirecting output from matching to wanted targets. + + Fluent interface parameter. + Restrict minimum LogLevel for names that matches this rule + Logger name pattern to check which names matches this rule + Rule identifier to allow rule lookup + + + + Defines for redirecting output from matching to wanted targets. + + Fluent interface parameter. + Override the name for the target created + + + + Apply fast filtering based on . Include LogEvents with same or worse severity as . + + Fluent interface parameter. + Minimum level that this rule matches + + + + Apply fast filtering based on . Include LogEvents with same or less severity as . + + Fluent interface parameter. + Maximum level that this rule matches + + + + Apply fast filtering based on . Include LogEvents with severity that equals . + + Fluent interface parameter. + Single loglevel that this rule matches + + + + Apply fast filtering based on . Include LogEvents with severity between and . + + Fluent interface parameter. + Minimum level that this rule matches + Maximum level that this rule matches + + + + Apply dynamic filtering logic for advanced control of when to redirect output to target. + + + Slower than using Logger-name or LogLevel-severity, because of allocation. + + Fluent interface parameter. + Filter for controlling whether to write + Default action if none of the filters match + + + + Apply dynamic filtering logic for advanced control of when to redirect output to target. + + + Slower than using Logger-name or LogLevel-severity, because of allocation. + + Fluent interface parameter. + Delegate for controlling whether to write + Default action if none of the filters match + + + + Dynamic filtering of LogEvent, where it will be ignored when matching filter-method-delegate + + + Slower than using Logger-name or LogLevel-severity, because of allocation. + + Fluent interface parameter. + Delegate for controlling whether to write + LogEvent will on match also be ignored by following logging-rules + + + + Dynamic filtering of LogEvent, where it will be logged when matching filter-method-delegate + + + Slower than using Logger-name or LogLevel-severity, because of allocation. + + Fluent interface parameter. + Delegate for controlling whether to write + LogEvent will not be evaluated by following logging-rules + + + + Move the to the top, to match before any of the existing + + + + + Redirect output from matching to the provided + + Fluent interface parameter. + Target that should be written to. + Fluent interface for configuring targets for the new LoggingRule. + + + + Redirect output from matching to the provided + + Fluent interface parameter. + Target-collection that should be written to. + Fluent interface for configuring targets for the new LoggingRule. + + + + Redirect output from matching to the provided + + Fluent interface parameter. + Target-collection that should be written to. + Fluent interface for configuring targets for the new LoggingRule. + + + + Discard output from matching , so it will not reach any following . + + Fluent interface parameter. + Only discard output from matching Logger when below minimum LogLevel + + + + Returns first target registered + + + + + Returns first target registered with the specified type + + Type of target + + + + Write to + + Fluent interface parameter. + Method to call on logevent + Layouts to render object[]-args before calling + + + + Write to + + Fluent interface parameter. + Override the default Layout for output + Override the default Encoding for output (Ex. UTF8) + Write to stderr instead of standard output (stdout) + Skip overhead from writing to console, when not available (Ex. running as Windows Service) + Enable batch writing of logevents, instead of Console.WriteLine for each logevent (Requires ) + + + + Write to and color log-messages based on + + Fluent interface parameter. + Override the default Layout for output + Highlight only the Level-part + Override the default Encoding for output (Ex. UTF8) + Write to stderr instead of standard output (stdout) + Skip overhead from writing to console, when not available (Ex. running as Windows Service) + Enables output using ANSI Color Codes (Windows console does not support this by default) + + + + Write to + + + Override the default Layout for output + Force use independent of + + + + Write to + + + Override the default Layout for output + + + + Write to (when DEBUG-build) + + + Override the default Layout for output + + + + Write to + + Fluent interface parameter. + + Override the default Layout for output + Override the default Encoding for output (Default = UTF8) + Override the default line ending characters (Ex. without CR) + Keep log file open instead of opening and closing it on each logging event + Activate multi-process synchronization using global mutex on the operating system + Size in bytes where log files will be automatically archived. + Maximum number of archive files that should be kept. + Maximum days of archive files that should be kept. + + + + Applies target wrapper for existing + + Fluent interface parameter. + Factory method for creating target-wrapper + + + + Applies for existing for asynchronous background writing + + Fluent interface parameter. + Action to take when queue overflows + Queue size limit for pending logevents + Batch size when writing on the background thread + + + + Applies for existing for throttled writing + + Fluent interface parameter. + Buffer size limit for pending logevents + Timeout for when the buffer will flush automatically using background thread + Restart timeout when logevent is written + Action to take when buffer overflows + + + + Applies for existing for flushing after conditional event + + Fluent interface parameter. + Method delegate that controls whether logevent should force flush. + Only flush when triggers (Ignore config-reload and config-shutdown) + + + + Applies for existing for retrying after failure + + Fluent interface parameter. + Number of retries that should be attempted on the wrapped target in case of a failure. + Time to wait between retries + + + + Applies for existing to fallback on failure. + + Fluent interface parameter. + Target to use for fallback + Whether to return to the first target after any successful write + + + + Extension methods to setup general option before loading NLog LoggingConfiguration + + + + + Configures the global time-source used for all logevents + + + Available by default: , , , + + + + + Configures the global time-source used for all logevents to use + + + + + Configures the global time-source used for all logevents to use + + + + + Updates the dictionary ${gdc:item=} with the name-value-pair + + + + + Sets whether to automatically call on AppDomain.Unload or AppDomain.ProcessExit + + + + + Sets the default culture info to use as . + + + + + Sets the global log level threshold. Log events below this threshold are not logged. + + + + + Gets or sets a value indicating whether should be thrown on configuration errors + + + + + Mark Assembly as hidden, so Assembly methods are excluded when resolving ${callsite} from StackTrace + + + + + Extension methods to setup NLog extensions, so they are known when loading NLog LoggingConfiguration + + + + + Enable/disables the NLog Message Template Parsing: + - True = Always use NLog mesage-template-parser and formatting. + - False = Never use NLog-parser and only use string.Format (Disable support for message-template-syntax). + - Null = Auto detection of message-template-syntax, with fallback to string.Format (Default Behavior). + + + + + Overrides the active with a new custom implementation + + + + + Overrides the active with a new custom implementation + + + + + Registers object Type transformation from dangerous (massive) object to safe (reduced) object + + + + + Registers object Type transformation from dangerous (massive) object to safe (reduced) object + + + + + Specifies the way archive numbering is performed. + + + + + Sequence style numbering. The most recent archive has the highest number. + + + + + Rolling style numbering (the most recent is always #0 then #1, ..., #N. + + + + + Date style numbering. Archives will be stamped with the prior period + (Year, Month, Day, Hour, Minute) datetime. + + + + + Date and sequence style numbering. + Archives will be stamped with the prior period (Year, Month, Day) datetime. + The most recent archive has the highest number (in combination with the date). + + + + + Abstract Target with async Task support + + + See NLog Wiki + + + [Target("MyFirst")] + public sealed class MyFirstTarget : AsyncTaskTarget + { + public MyFirstTarget() + { + this.Host = "localhost"; + } + + [RequiredParameter] + public Layout Host { get; set; } + + protected override Task WriteAsyncTask(LogEventInfo logEvent, CancellationToken token) + { + string logMessage = this.RenderLogEvent(this.Layout, logEvent); + string hostName = this.RenderLogEvent(this.Host, logEvent); + return SendTheMessageToRemoteHost(hostName, logMessage); + } + + private async Task SendTheMessageToRemoteHost(string hostName, string message) + { + // To be implemented + } + } + + Documentation on NLog Wiki + + + + How many milliseconds to delay the actual write operation to optimize for batching + + + + + + How many seconds a Task is allowed to run before it is cancelled. + + + + + + How many attempts to retry the same Task, before it is aborted + + + + + + How many milliseconds to wait before next retry (will double with each retry) + + + + + + Gets or sets whether to use the locking queue, instead of a lock-free concurrent queue + The locking queue is less concurrent when many logger threads, but reduces memory allocation + + + + + + Gets or sets the action to be taken when the lazy writer thread request queue count + exceeds the set limit. + + + + + + Gets or sets the limit on the number of requests in the lazy writer thread request queue. + + + + + + Gets or sets the number of log events that should be processed in a batch + by the lazy writer thread. + + + + + + Task Scheduler used for processing async Tasks + + + + + Constructor + + + + + + + + Override this to provide async task for writing a single logevent. + + Example of how to override this method, and call custom async method + + protected override Task WriteAsyncTask(LogEventInfo logEvent, CancellationToken token) + { + return CustomWriteAsync(logEvent, token); + } + + private async Task CustomWriteAsync(LogEventInfo logEvent, CancellationToken token) + { + await MyLogMethodAsync(logEvent, token).ConfigureAwait(false); + } + + + The log event. + The cancellation token + + + + + Override this to provide async task for writing a batch of logevents. + + A batch of logevents. + The cancellation token + + + + + Handle cleanup after failed write operation + + Exception from previous failed Task + The cancellation token + Number of retries remaining + Time to sleep before retrying + Should attempt retry + + + + Block for override. Instead override + + + + + Block for override. Instead override + + + + + + + + Write to queue without locking + + + + + + Block for override. Instead override + + + + + LogEvent is written to target, but target failed to successfully initialize + + Enqueue logevent for later processing when target failed to initialize because of unresolved service dependency. + + + + + Schedules notification of when all messages has been written + + + + + + Closes Target by updating CancellationToken + + + + + Releases any managed resources + + + + + + Checks the internal queue for the next to create a new task for + + Used for race-condition validation between task-completion and timeout + Signals whether previousTask completed an almost full BatchSize + + + + Generates recursive task-chain to perform retry of writing logevents with increasing retry-delay + + + + + Creates new task to handle the writing of the input + + LogEvents to write + New Task created [true / false] + + + + Handles that scheduled task has completed (successfully or failed), and starts the next pending task + + Task just completed + AsyncContinuation to notify of success or failure + + + + Timer method, that is fired when pending task fails to complete within timeout + + + + + + Sends log messages to the remote instance of Chainsaw application from log4j. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a name. + + Name of the target. + + + + Color formatting for using ANSI Color Codes + + + + + Not using bold to get light colors, as it has to be cleared + + + + + Not using bold to get light colors, as it has to be cleared (And because it only works for text, and not background) + + + + + Resets both foreground and background color. + + + + + ANSI have 8 color-codes (30-37) by default. The "bright" (or "intense") color-codes (90-97) are extended values not supported by all terminals + + + + + Color formatting for using + and + + + + + Writes log messages to the console with customizable coloring. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Should logging being paused/stopped because of the race condition bug in Console.Writeline? + + + Console.Out.Writeline / Console.Error.Writeline could throw 'IndexOutOfRangeException', which is a bug. + See https://stackoverflow.com/questions/33915790/console-out-and-console-error-race-condition-error-in-a-windows-service-written + and https://connect.microsoft.com/VisualStudio/feedback/details/2057284/console-out-probable-i-o-race-condition-issue-in-multi-threaded-windows-service + + Full error: + Error during session close: System.IndexOutOfRangeException: Probable I/ O race condition detected while copying memory. + The I/ O package is not thread safe by default. In multi-threaded applications, + a stream must be accessed in a thread-safe way, such as a thread - safe wrapper returned by TextReader's or + TextWriter's Synchronized methods.This also applies to classes like StreamWriter and StreamReader. + + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + Obsolete and replaced by with NLog v5. + Gets or sets a value indicating whether the error stream (stderr) should be used instead of the output stream (stdout). + + + + + + Gets or sets a value indicating whether to send the log messages to the standard error instead of the standard output. + + + + + + Gets or sets a value indicating whether to use default row highlighting rules. + + + The default rules are: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ConditionForeground ColorBackground Color
level == LogLevel.FatalRedNoChange
level == LogLevel.ErrorYellowNoChange
level == LogLevel.WarnMagentaNoChange
level == LogLevel.InfoWhiteNoChange
level == LogLevel.DebugGrayNoChange
level == LogLevel.TraceDarkGrayNoChange
+
+ +
+ + + The encoding for writing messages to the . + + Has side effect + + + + + Gets or sets a value indicating whether to auto-check if the console is available. + - Disables console writing if Environment.UserInteractive = False (Windows Service) + - Disables console writing if Console Standard Input is not available (Non-Console-App) + + + + + + Gets or sets a value indicating whether to auto-check if the console has been redirected to file + - Disables coloring logic when System.Console.IsOutputRedirected = true + + + + + + Gets or sets a value indicating whether to auto-flush after + + + Normally not required as standard Console.Out will have = true, but not when pipe to file + + + + + + Enables output using ANSI Color Codes + + + + + + Gets the row highlighting rules. + + + + + + Gets the word highlighting rules. + + + + + + + + + + + + + + + + + + Colored console output color. + + + Note that this enumeration is defined to be binary compatible with + .NET 2.0 System.ConsoleColor + some additions + + + + + Black Color (#000000). + + + + + Dark blue Color (#000080). + + + + + Dark green Color (#008000). + + + + + Dark Cyan Color (#008080). + + + + + Dark Red Color (#800000). + + + + + Dark Magenta Color (#800080). + + + + + Dark Yellow Color (#808000). + + + + + Gray Color (#C0C0C0). + + + + + Dark Gray Color (#808080). + + + + + Blue Color (#0000FF). + + + + + Green Color (#00FF00). + + + + + Cyan Color (#00FFFF). + + + + + Red Color (#FF0000). + + + + + Magenta Color (#FF00FF). + + + + + Yellow Color (#FFFF00). + + + + + White Color (#FFFFFF). + + + + + Don't change the color. + + + + + The row-highlighting condition. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The condition. + Color of the foreground. + Color of the background. + + + + Gets the default highlighting rule. Doesn't change the color. + + + + + Gets or sets the condition that must be met in order to set the specified foreground and background color. + + + + + + Gets or sets the foreground color. + + + + + + Gets or sets the background color. + + + + + + Checks whether the specified log event matches the condition (if any). + + + Log event. + + + A value of if the condition is not defined or + if it matches, otherwise. + + + + + Writes log messages to the console. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Should logging being paused/stopped because of the race condition bug in Console.Writeline? + + + Console.Out.Writeline / Console.Error.Writeline could throw 'IndexOutOfRangeException', which is a bug. + See https://stackoverflow.com/questions/33915790/console-out-and-console-error-race-condition-error-in-a-windows-service-written + and https://connect.microsoft.com/VisualStudio/feedback/details/2057284/console-out-probable-i-o-race-condition-issue-in-multi-threaded-windows-service + + Full error: + Error during session close: System.IndexOutOfRangeException: Probable I/ O race condition detected while copying memory. + The I/ O package is not thread safe by default. In multi-threaded applications, + a stream must be accessed in a thread-safe way, such as a thread - safe wrapper returned by TextReader's or + TextWriter's Synchronized methods.This also applies to classes like StreamWriter and StreamReader. + + + + + + Obsolete and replaced by with NLog v5. + Gets or sets a value indicating whether to send the log messages to the standard error instead of the standard output. + + + + + + Gets or sets a value indicating whether to send the log messages to the standard error instead of the standard output. + + + + + + The encoding for writing messages to the . + + Has side effect + + + + + Gets or sets a value indicating whether to auto-check if the console is available + - Disables console writing if Environment.UserInteractive = False (Windows Service) + - Disables console writing if Console Standard Input is not available (Non-Console-App) + + + + + + Gets or sets a value indicating whether to auto-flush after + + + Normally not required as standard Console.Out will have = true, but not when pipe to file + + + + + + Gets or sets whether to activate internal buffering to allow batch writing, instead of using + + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + + + + + + + + + + + + + + + + Highlighting rule for Win32 colorful console. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The text to be matched.. + Color of the foreground. + Color of the background. + + + + Gets or sets the regular expression to be matched. You must specify either text or regex. + + + + + + Gets or sets the condition that must be met before scanning the row for highlight of words + + + + + + Compile the ? This can improve the performance, but at the costs of more memory usage. If false, the Regex Cache is used. + + + + + + Gets or sets the text to be matched. You must specify either text or regex. + + + + + + Gets or sets a value indicating whether to match whole words only. + + + + + + Gets or sets a value indicating whether to ignore case when comparing texts. + + + + + + Gets or sets the foreground color. + + + + + + Gets or sets the background color. + + + + + + Gets the compiled regular expression that matches either Text or Regex property. Only used when is true. + + + + + A descriptor for an archive created with the DateAndSequence numbering mode. + + + + + The full name of the archive file. + + + + + The parsed date contained in the file name. + + + + + The parsed sequence number contained in the file name. + + + + + Determines whether produces the same string as the current instance's date once formatted with the current instance's date format. + + The date to compare the current object's date to. + True if the formatted dates are equal, otherwise False. + + + + Initializes a new instance of the class. + + + + + Writes log messages to the attached managed debugger. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + + + + + + + + + + Outputs log messages through + + + See NLog Wiki + + Documentation on NLog Wiki + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + + + + + + + Outputs the rendered logging event through + + The logging event. + + + + Mock target - useful for testing. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + Gets the number of times this target has been called. + + + + + + Gets the last message rendered by this target. + + + + + + + + + Default class for serialization of values to JSON format. + + + + + Singleton instance of the serializer. + + + + + Private. Use + + + + + Returns a serialization of an object into JSON format. + + The object to serialize to JSON. + Serialized value. + + + + Returns a serialization of an object into JSON format. + + The object to serialize to JSON. + serialization options + Serialized value. + + + + Serialization of the object in JSON format to the destination StringBuilder + + The object to serialize to JSON. + Write the resulting JSON to this destination. + Object serialized successfully (true/false). + + + + Serialization of the object in JSON format to the destination StringBuilder + + The object to serialize to JSON. + Write the resulting JSON to this destination. + serialization options + Object serialized successfully (true/false). + + + + Serialization of the object in JSON format to the destination StringBuilder + + The object to serialize to JSON. + Write the resulting JSON to this destination. + serialization options + The objects in path (Avoid cyclic reference loop). + The current depth (level) of recursion. + Object serialized successfully (true/false). + + + + No quotes needed for this type? + + + + + Checks the object if it is numeric + + TypeCode for the object + Accept fractional types as numeric type. + + + + + Checks input string if it needs JSON escaping, and makes necessary conversion + + Destination Builder + Input string + all options + JSON escaped string + + + + Checks input string if it needs JSON escaping, and makes necessary conversion + + Destination Builder + Input string + Should non-ASCII characters be encoded + + JSON escaped string + + + + Check if cleanup should be performed on initialize new file + + Skip cleanup when initializing new file, just after having performed archive operation + + Base archive file pattern + Maximum number of archive files that should be kept + Maximum days of archive files that should be kept + True, when archive cleanup is needed + + + + Characters determining the start of the . + + + + + Characters determining the end of the . + + + + + File name which is used as template for matching and replacements. + It is expected to contain a pattern to match. + + + + + The beginning position of the + within the . -1 is returned + when no pattern can be found. + + + + + The ending position of the + within the . -1 is returned + when no pattern can be found. + + + + + Replace the pattern with the specified String. + + + + + + + Archives the log-files using a date style numbering. Archives will be stamped with the + prior period (Year, Month, Day, Hour, Minute) datetime. + + When the number of archive files exceed the obsolete archives are deleted. + When the age of archive files exceed the obsolete archives are deleted. + + + + + Archives the log-files using a date and sequence style numbering. Archives will be stamped + with the prior period (Year, Month, Day) datetime. The most recent archive has the highest number (in + combination with the date). + + When the number of archive files exceed the obsolete archives are deleted. + When the age of archive files exceed the obsolete archives are deleted. + + + + + Parse filename with date and sequence pattern + + + dateformat for archive + + the found pattern. When failed, then default + the found pattern. When failed, then default + + + + + Archives the log-files using the provided base-archive-filename. If the base-archive-filename causes + duplicate archive filenames, then sequence-style is automatically enforced. + + Example: + Base Filename trace.log + Next Filename trace.0.log + + The most recent archive has the highest number. + + When the number of archive files exceed the obsolete archives are deleted. + When the age of archive files exceed the obsolete archives are deleted. + + + + + Dynamically converts a non-template archiveFilePath into a correct archiveFilePattern. + Before called the original IFileArchiveMode, that has been wrapped by this + + + + + Determines if the file name as contains a numeric pattern i.e. {#} in it. + + Example: + trace{#}.log Contains the numeric pattern. + trace{###}.log Contains the numeric pattern. + trace{#X#}.log Contains the numeric pattern (See remarks). + trace.log Does not contain the pattern. + + Occasionally, this method can identify the existence of the {#} pattern incorrectly. + File name to be checked. + when the pattern is found; otherwise. + + + + Archives the log-files using a rolling style numbering (the most recent is always #0 then + #1, ..., #N. + + When the number of archive files exceed the obsolete archives + are deleted. + + + + + Replaces the numeric pattern i.e. {#} in a file name with the parameter value. + + File name which contains the numeric pattern. + Value which will replace the numeric pattern. + File name with the value of in the position of the numeric pattern. + + + + Archives the log-files using a sequence style numbering. The most recent archive has the highest number. + + When the number of archive files exceed the obsolete archives are deleted. + When the age of archive files exceed the obsolete archives are deleted. + + + + + Modes of archiving files based on time. + + + + + Don't archive based on time. + + + + + AddToArchive every year. + + + + + AddToArchive every month. + + + + + AddToArchive daily. + + + + + AddToArchive every hour. + + + + + AddToArchive every minute. + + + + + AddToArchive every Sunday. + + + + + AddToArchive every Monday. + + + + + AddToArchive every Tuesday. + + + + + AddToArchive every Wednesday. + + + + + AddToArchive every Thursday. + + + + + AddToArchive every Friday. + + + + + AddToArchive every Saturday. + + + + + Type of filepath + + + + + Detect of relative or absolute + + + + + Relative path + + + + + Absolute path + + Best for performance + + + + Writes log messages to one or more files. + + + See NLog Wiki + + Documentation on NLog Wiki + + + + Default clean up period of the initialized files. When a file exceeds the clean up period is removed from the list. + + Clean up period is defined in days. + + + + This value disables file archiving based on the size. + + + + + Holds the initialized files each given time by the instance. Against each file, the last write time is stored. + + Last write time is store in local time (no UTC). + + + + List of the associated file appenders with the instance. + + + + + The number of initialized files at any one time. + + + + + The maximum number of archive files that should be kept. + + + + + The maximum days of archive files that should be kept. + + + + + The filename as target + + + + + The archive file name as target + + + + + The date of the previous log event. + + + + + The file name of the previous log event. + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + Gets or sets the name of the file to write to. + + + This FileName string is a layout which may include instances of layout renderers. + This lets you use a single target to write to multiple files. + + + The following value makes NLog write logging events to files based on the log level in the directory where + the application runs. + ${basedir}/${level}.log + All Debug messages will go to Debug.log, all Info messages will go to Info.log and so on. + You can combine as many of the layout renderers as you want to produce an arbitrary log file name. + + + + + + Cleanup invalid values in a filename, e.g. slashes in a filename. If set to true, this can impact the performance of massive writes. + If set to false, nothing gets written when the filename is wrong. + + + + + + Is the an absolute or relative path? + + + + + + Gets or sets a value indicating whether to create directories if they do not exist. + + + Setting this to false may improve performance a bit, but you'll receive an error + when attempting to write to a directory that's not present. + + + + + + Gets or sets a value indicating whether to delete old log file on startup. + + + This option works only when the "FileName" parameter denotes a single file. + + + + + + Gets or sets a value indicating whether to replace file contents on each write instead of appending log message at the end. + + + + + + Gets or sets a value indicating whether to keep log file open instead of opening and closing it on each logging event. + + + KeepFileOpen = true gives the best performance, and ensure the file-lock is not lost to other applications.
+ KeepFileOpen = false gives the best compability, but slow performance and lead to file-locking issues with other applications. +
+ +
+ + + Gets or sets a value indicating whether to enable log file(s) to be deleted. + + + + + + Gets or sets the file attributes (Windows only). + + + + + + Gets or sets the line ending mode. + + + + + + Gets or sets a value indicating whether to automatically flush the file buffers after each log message. + + + + + + Gets or sets the number of files to be kept open. Setting this to a higher value may improve performance + in a situation where a single File target is writing to many files + (such as splitting by level or by logger). + + + The files are managed on a LRU (least recently used) basis, which flushes + the files that have not been used for the longest period of time should the + cache become full. As a rule of thumb, you shouldn't set this parameter to + a very high value. A number like 10-15 shouldn't be exceeded, because you'd + be keeping a large number of files open which consumes system resources. + + + + + + Gets or sets the maximum number of seconds that files are kept open. Zero or negative means disabled. + + + + + + Gets or sets the maximum number of seconds before open files are flushed. Zero or negative means disabled. + + + + + + Gets or sets the log file buffer size in bytes. + + + + + + Gets or sets the file encoding. + + + + + + Gets or sets whether or not this target should just discard all data that its asked to write. + Mostly used for when testing NLog Stack except final write + + + + + + Gets or sets a value indicating whether concurrent writes to the log file by multiple processes on the same host. + + + This makes multi-process logging possible. NLog uses a special technique + that lets it keep the files open for writing. + + + + + + Gets or sets a value indicating whether concurrent writes to the log file by multiple processes on different network hosts. + + + This effectively prevents files from being kept open. + + + + + + Gets or sets a value indicating whether to write BOM (byte order mark) in created files. + + Defaults to true for UTF-16 and UTF-32 + + + + + + Gets or sets the number of times the write is appended on the file before NLog + discards the log message. + + + + + + Gets or sets the delay in milliseconds to wait before attempting to write to the file again. + + + The actual delay is a random value between 0 and the value specified + in this parameter. On each failed attempt the delay base is doubled + up to times. + + + Assuming that ConcurrentWriteAttemptDelay is 10 the time to wait will be:

+ a random value between 0 and 10 milliseconds - 1st attempt
+ a random value between 0 and 20 milliseconds - 2nd attempt
+ a random value between 0 and 40 milliseconds - 3rd attempt
+ a random value between 0 and 80 milliseconds - 4th attempt
+ ...

+ and so on. + + + + +

+ Gets or sets a value indicating whether to archive old log file on startup. + + + This option works only when the "FileName" parameter denotes a single file. + After archiving the old file, the current log file will be empty. + + +
+ + + Gets or sets whether to write the Header on initial creation of file appender, even if the file is not empty. + Default value is , which means only write header when initial file is empty (Ex. ensures valid CSV files) + + + Alternative use to ensure each application session gets individual log-file. + + + + + Gets or sets a value of the file size threshold to archive old log file on startup. + + + This option won't work if is set to false + Default value is 0 which means that the file is archived as soon as archival on + startup is enabled. + + + + + + Gets or sets a value specifying the date format to use when archiving files. + + + This option works only when the "ArchiveNumbering" parameter is set either to Date or DateAndSequence. + + + + + + Gets or sets the size in bytes above which log files will be automatically archived. + + + Notice when combined with then it will attempt to append to any existing + archive file if grown above size multiple times. New archive file will be created when using + + + + + + Gets or sets a value indicating whether to automatically archive log files every time the specified time passes. + + + Files are moved to the archive as part of the write operation if the current period of time changes. For example + if the current hour changes from 10 to 11, the first write that will occur + on or after 11:00 will trigger the archiving. + + + + + + Is the an absolute or relative path? + + + + + + Gets or sets the name of the file to be used for an archive. + + + It may contain a special placeholder {#####} + that will be replaced with a sequence of numbers depending on + the archiving strategy. The number of hash characters used determines + the number of numerical digits to be used for numbering files. + + + + + + Gets or sets the maximum number of archive files that should be kept. + + + + + + Gets or sets the maximum days of archive files that should be kept. + + + + + + Gets or sets the way file archives are numbered. + + + + + + Used to compress log files during archiving. + This may be used to provide your own implementation of a zip file compressor, + on platforms other than .Net4.5. + Defaults to ZipArchiveFileCompressor on .Net4.5 and to null otherwise. + + + + + + Gets or sets a value indicating whether to compress archive files into the zip archive format. + + + + + + Gets or set a value indicating whether a managed file stream is forced, instead of using the native implementation. + + + + + + Gets or sets a value indicating whether file creation calls should be synchronized by a system global mutex. + + + + + + Gets or sets a value indicating whether the footer should be written only when the file is archived. + + + + + + Gets the characters that are appended after each line. + + + + + Refresh the ArchiveFilePatternToWatch option of the . + The log file must be watched for archiving when multiple processes are writing to the same + open file. + + + + + Removes records of initialized files that have not been + accessed in the last two days. + + + Files are marked 'initialized' for the purpose of writing footers when the logging finishes. + + + + + Removes records of initialized files that have not been + accessed after the specified date. + + The cleanup threshold. + + Files are marked 'initialized' for the purpose of writing footers when the logging finishes. + + + + + Flushes all pending file operations. + + The asynchronous continuation. + + The timeout parameter is ignored, because file APIs don't provide + the needed functionality. + + + + + Returns the suitable appender factory ( ) to be used to generate the file + appenders associated with the instance. + + The type of the file appender factory returned depends on the values of various properties. + + suitable for this instance. + + + + Initializes file logging by creating data structures that + enable efficient multi-file logging. + + + + + Closes the file(s) opened for writing. + + + + + Writes the specified logging event to a file specified in the FileName + parameter. + + The logging event. + + + + Get full filename (=absolute) and cleaned if needed. + + + + + + + Writes the specified array of logging events to a file specified in the FileName + parameter. + + An array of objects. + + This function makes use of the fact that the events are batched by sorting + the requests by filename. This optimizes the number of open/close calls + and can help improve performance. + + + + + Obsolete and replaced by with NLog v5. + Formats the log event for write. + + The log event to be formatted. + A string representation of the log event. + + + + Obsolete and replaced by with NLog v5. + Gets the bytes to be written to the file. + + Log event. + Array of bytes that are ready to be written. + + + + Obsolete and replaced by with NLog v5. + Modifies the specified byte array before it gets sent to a file. + + The byte array. + The modified byte array. The function can do the modification in-place. + + + + Gets the bytes to be written to the file. + + The log event to be formatted. + to help format log event. + Optional temporary char-array to help format log event. + Destination for the encoded result. + + + + Formats the log event for write. + + The log event to be formatted. + for the result. + + + + Modifies the specified byte array before it gets sent to a file. + + The LogEvent being written + The byte array. + + + + Archives fileName to archiveFileName. + + File name to be archived. + Name of the archive file. + + + + Gets the correct formatting to be used based on the value of for converting values which will be inserting into file + names during archiving. + + This value will be computed only when a empty value or is passed into + + Date format to used irrespectively of value. + Formatting for dates. + + + + Calculate the DateTime of the requested day of the week. + + The DateTime of the previous log event. + The next occurring day of the week to return a DateTime for. + The DateTime of the next occurring dayOfWeek. + For example: if previousLogEventTimestamp is Thursday 2017-03-02 and dayOfWeek is Sunday, this will return + Sunday 2017-03-05. If dayOfWeek is Thursday, this will return *next* Thursday 2017-03-09. + + + + Invokes the archiving process after determining when and which type of archiving is required. + + File name to be checked and archived. + Log event that the instance is currently processing. + The DateTime of the previous log event for this file. + File has just been opened. + + + + Gets the pattern that archive files will match + + Filename of the log file + Log event that the instance is currently processing. + A string with a pattern that will match the archive filenames + + + + Archives the file if it should be archived. + + The file name to check for. + Log event that the instance is currently processing. + The size in bytes of the next chunk of data to be written in the file. + The DateTime of the previous log event for this file. + File has just been opened. + True when archive operation of the file was completed (by this target or a concurrent target) + + + + Closes any active file-appenders that matches the input filenames. + File-appender is requested to invalidate/close its filehandle, but keeping its archive-mutex alive + + + + + Indicates if the automatic archiving process should be executed. + + File name to be written. + Log event that the instance is currently processing. + The size in bytes of the next chunk of data to be written in the file. + The DateTime of the previous log event for this file. + File has just been opened. + Filename to archive. If null, then nothing to archive. + + + + Returns the correct filename to archive + + + + + Gets the file name for archiving, or null if archiving should not occur based on file size. + + File name to be written. + The size in bytes of the next chunk of data to be written in the file. + File has just been opened. + Filename to archive. If null, then nothing to archive. + + + + Check if archive operation should check previous filename, because FileAppenderCache tells us current filename no longer exists + + + + + Returns the file name for archiving, or null if archiving should not occur based on date/time. + + File name to be written. + Log event that the instance is currently processing. + The DateTime of the previous log event for this file. + File has just been opened. + Filename to archive. If null, then nothing to archive. + + + + Truncates the input-time, so comparison of low resolution times (like dates) are not affected by ticks + + High resolution Time + Time Resolution Level + Truncated Low Resolution Time + + + + Evaluates which parts of a file should be written (header, content, footer) based on various properties of + instance and writes them. + + File name to be written. + Raw sequence of to be written into the content part of the file. + File has just been opened. + + + + Initialize a file to be used by the instance. Based on the number of initialized + files and the values of various instance properties clean up and/or archiving processes can be invoked. + + File name to be written. + Log event that the instance is currently processing. + The DateTime of the previous log event for this file (DateTime.MinValue if just initialized). + + + + Writes the file footer and finalizes the file in instance internal structures. + + File name to close. + Indicates if the file is being finalized for archiving. + + + + Writes the footer information to a file. + + The file path to write to. + + + + Decision logic whether to archive logfile on startup. + and properties. + + File name to be written. + Decision whether to archive or not. + + + + Invokes the archiving and clean up of older archive file based on the values of + and + properties respectively. + + File name to be written. + Log event that the instance is currently processing. + + + + Creates the file specified in and writes the file content in each entirety i.e. + Header, Content and Footer. + + The name of the file to be written. + Sequence of to be written in the content section of the file. + First attempt to write? + This method is used when the content of the log file is re-written on every write. + + + + Writes the header information and byte order mark to a file. + + File appender associated with the file. + + + + The sequence of to be written in a file after applying any formatting and any + transformations required from the . + + The layout used to render output message. + Sequence of to be written. + Usually it is used to render the header and hooter of the files. + + + + may be configured to compress archived files in a custom way + by setting before logging your first event. + + + + + Create archiveFileName by compressing fileName. + + Absolute path to the log file to compress. + Absolute path to the compressed archive file to create. + The name of the file inside the archive. + + + + Controls the text and color formatting for + + + + + Creates a TextWriter for the console to start building a colored text message + + Active console stream + Optional StringBuilder to optimize performance + TextWriter for the console + + + + Releases the TextWriter for the console after having built a colored text message (Restores console colors) + + Colored TextWriter + Active console stream + Original foreground color for console (If changed) + Original background color for console (If changed) + Flush TextWriter + + + + Changes foreground color for the Colored TextWriter + + Colored TextWriter + New foreground color for the console + Old previous backgroundColor color for the console + Old foreground color for the console + + + + Changes backgroundColor color for the Colored TextWriter + + Colored TextWriter + New backgroundColor color for the console + Old previous backgroundColor color for the console + Old backgroundColor color for the console + + + + Restores console colors back to their original state + + Colored TextWriter + Original foregroundColor color for the console + Original backgroundColor color for the console + + + + Writes multiple characters to console in one operation (faster) + + Colored TextWriter + Output Text + Start Index + End Index + + + + Writes single character to console + + Colored TextWriter + Output Text + + + + Writes whole string and completes with newline + + Colored TextWriter + Output Text + + + + Default row highlight rules for the console printer + + + + + Check if cleanup should be performed on initialize new file + + Base archive file pattern + Maximum number of archive files that should be kept + Maximum days of archive files that should be kept + True, when archive cleanup is needed + + + + Create a wildcard file-mask that allows one to find all files belonging to the same archive. + + Base archive file pattern + Wildcard file-mask + + + + Search directory for all existing files that are part of the same archive. + + Base archive file pattern + + + + + Generate the next archive filename for the archive. + + Base archive file pattern + File date of archive + Existing files in the same archive + + + + + Return all files that should be removed from the provided archive. + + Base archive file pattern + Existing files in the same archive + Maximum number of archive files that should be kept + Maximum days of archive files that should be kept + + + + may be configured to compress archived files in a custom way + by setting before logging your first event. + + + + + Create archiveFileName by compressing fileName. + + Absolute path to the log file to compress. + Absolute path to the compressed archive file to create. + + + + Options for JSON serialization + + + + + Add quotes around object keys? + + + + + Format provider for value + + + + + Format string for value + + + + + Should non-ascii characters be encoded + + + + + Should forward slashes be escaped? If true, / will be converted to \/ + + + + + Serialize enum as string value + + + + + Should dictionary keys be sanitized. All characters must either be letters, numbers or underscore character (_). + + Any other characters will be converted to underscore character (_) + + + + + How far down the rabbit hole should the Json Serializer go with object-reflection before stopping + + + + + Line ending mode. + + + + + Insert platform-dependent end-of-line sequence after each line. + + + + + Insert CR LF sequence (ASCII 13, ASCII 10) after each line. + + + + + Insert CR character (ASCII 13) after each line. + + + + + Insert LF character (ASCII 10) after each line. + + + + + Insert null terminator (ASCII 0) after each line. + + + + + Do not insert any line ending. + + + + + Gets the name of the LineEndingMode instance. + + + + + Gets the new line characters (value) of the LineEndingMode instance. + + + + + Initializes a new instance of . + + The mode name. + The new line characters to be used. + + + + Returns the that corresponds to the supplied . + + + The textual representation of the line ending mode, such as CRLF, LF, Default etc. + Name is not case sensitive. + + The value, that corresponds to the . + There is no line ending mode with the specified name. + + + + Compares two objects and returns a + value indicating whether the first one is equal to the second one. + + The first level. + The second level. + The value of mode1.NewLineCharacters == mode2.NewLineCharacters. + + + + Compares two objects and returns a + value indicating whether the first one is not equal to the second one. + + The first mode + The second mode + The value of mode1.NewLineCharacters != mode2.NewLineCharacters. + + + + + + + + + + + + Indicates whether the current object is equal to another object of the same type. + true if the current object is equal to the parameter; otherwise, false. + An object to compare with this object. + + + + Provides a type converter to convert objects to and from other representations. + + + + + + + + + + + Sends log messages by email using SMTP protocol. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +

+ Mail target works best when used with BufferingWrapper target + which lets you send multiple log messages in single mail +

+

+ To set up the buffered mail target in the configuration file, + use the following syntax: +

+ +

+ To set up the buffered mail target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + Gets or sets sender's email address (e.g. joe@domain.com). + + + + + + Gets or sets recipients' email addresses separated by semicolons (e.g. john@domain.com;jane@domain.com). + + + + + + Gets or sets CC email addresses separated by semicolons (e.g. john@domain.com;jane@domain.com). + + + + + + Gets or sets BCC email addresses separated by semicolons (e.g. john@domain.com;jane@domain.com). + + + + + + Gets or sets a value indicating whether to add new lines between log entries. + + A value of true if new lines should be added; otherwise, false. + + + + + Gets or sets the mail subject. + + + + + + Gets or sets mail message body (repeated for each log message send in one mail). + + Alias for the Layout property. + + + + + Gets or sets encoding to be used for sending e-mail. + + + + + + Gets or sets a value indicating whether to send message as HTML instead of plain text. + + + + + + Gets or sets SMTP Server to be used for sending. + + + + + + Gets or sets SMTP Authentication mode. + + + + + + Gets or sets the username used to connect to SMTP server (used when SmtpAuthentication is set to "basic"). + + + + + + Gets or sets the password used to authenticate against SMTP server (used when SmtpAuthentication is set to "basic"). + + + + + + Gets or sets a value indicating whether SSL (secure sockets layer) should be used when communicating with SMTP server. + + . + + + + Gets or sets the port number that SMTP Server is listening on. + + + + + + Gets or sets a value indicating whether the default Settings from System.Net.MailSettings should be used. + + + + + + Specifies how outgoing email messages will be handled. + + + + + + Gets or sets the folder where applications save mail messages to be processed by the local SMTP server. + + + + + + Gets or sets the priority used for sending mails. + + + + + + Gets or sets a value indicating whether NewLine characters in the body should be replaced with
tags. +
+ Only happens when is set to true. + +
+ + + Gets or sets a value indicating the SMTP client timeout. + + Warning: zero is not infinite waiting + + + + + Gets the array of email headers that are transmitted with this email message + + + + + + + + + + + + + + + Create mail and send with SMTP + + event printed in the body of the event + + + + Create buffer for body + + all events + first event for header + last event for footer + + + + + Set properties of + + last event for username/password + client to set properties on + Configure not at , as the properties could have layout renderers. + + + + Handle if it is a virtual directory. + + + + + + + Create key for grouping. Needed for multiple events in one mail message + + event for rendering layouts + string to group on + + + + Create the mail message with the addresses, properties and body. + + + + + Render and add the addresses to + + Addresses appended to this list + layout with addresses, ; separated + event for rendering the + added a address? + + + + Writes log messages to in memory for programmatic retrieval. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + Gets the list of logs gathered in the . + + + Be careful when enumerating, as NLog target is blocked from writing during enumeration (blocks application logging) + + + + + Gets or sets the max number of items to have in memory + + + + + + + + + + + + Renders the logging event message and adds to + + The logging event. + + + + A parameter to MethodCall. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The layout to use for parameter value. + + + + Initializes a new instance of the class. + + Name of the parameter. + The layout. + + + + Initializes a new instance of the class. + + The name of the parameter. + The layout. + The type of the parameter. + + + + Gets or sets the name of the parameter. + + + + + + Gets or sets the layout that should be use to calculate the value for the parameter. + + + + + + Obsolete and replaced by with NLog v4.6. + Gets or sets the type of the parameter. Obsolete alias for + + + + + + Gets or sets the type of the parameter. + + + + + + Gets or sets the fallback value when result value is not available + + + + + + Render Result Value + + Log event for rendering + Result value when available, else fallback to defaultValue + + + + Calls the specified static method on each log message and passes contextual parameters to it. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Gets or sets the class name. + + + + + + Gets or sets the method name. The method must be public and static. + + Use the AssemblyQualifiedName , https://msdn.microsoft.com/en-us/library/system.type.assemblyqualifiedname(v=vs.110).aspx + e.g. + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + + + + Initializes a new instance of the class. + + Name of the target. + Method to call on logevent. + + + + + + + Calls the specified Method. + + Method parameters. + The logging event. + + + + Calls the specified Method. + + Method parameters. + + + + The base class for all targets which call methods (local or remote). + Manages parameters and type coercion. + + + + + Initializes a new instance of the class. + + + + + Gets the array of parameters to be passed. + + + + + + Prepares an array of parameters to be passed based on the logging event and calls DoInvoke(). + + The logging event. + + + + Calls the target DoInvoke method, and handles AsyncContinuation callback + + Method call parameters. + The logging event. + + + + Calls the target DoInvoke method, and handles AsyncContinuation callback + + Method call parameters. + The continuation. + + + + Calls the target method. Must be implemented in concrete classes. + + Method call parameters. + + + + Arguments for events. + + + + + + + + + + + + + + + + + Creates new instance of NetworkTargetLogEventDroppedEventArgs + + + + + The reason why log was dropped + + + + + The reason why log event was dropped by + + + + + Discarded LogEvent because message is bigger than + + + + + Discarded LogEvent because message queue was bigger than + + + + + Discarded LogEvent because attempted to open more than connections + + + + + Discarded LogEvent because of network communication error + + + + + Sends log messages over the network. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +

+ To print the results, use any application that's able to receive messages over + TCP or UDP. NetCat is + a simple but very powerful command-line tool that can be used for that. This image + demonstrates the NetCat tool receiving log messages from Network target. +

+ +

+ There are two specialized versions of the Network target: Chainsaw + and NLogViewer which write to instances of Chainsaw log4j viewer + or NLogViewer application respectively. +

+
+
+ + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + Gets or sets the network address. + + + The network address can be: +
    +
  • tcp://host:port - TCP (auto select IPv4/IPv6)
  • +
  • tcp4://host:port - force TCP/IPv4
  • +
  • tcp6://host:port - force TCP/IPv6
  • +
  • udp://host:port - UDP (auto select IPv4/IPv6)
  • +
  • udp4://host:port - force UDP/IPv4
  • +
  • udp6://host:port - force UDP/IPv6
  • +
  • http://host:port/pageName - HTTP using POST verb
  • +
  • https://host:port/pageName - HTTPS using POST verb
  • +
+ For SOAP-based webservice support over HTTP use WebService target. +
+ +
+ + + Gets or sets a value indicating whether to keep connection open whenever possible. + + + + + + Gets or sets a value indicating whether to append newline at the end of log message. + + + + + + Gets or sets the end of line value if a newline is appended at the end of log message . + + + + + + Gets or sets the maximum message size in bytes. On limit breach then action is activated. + + + + + + Gets or sets the maximum simultaneous connections. Requires = false + + + When having reached the maximum limit, then action will apply. + + + + + + Gets or sets the action that should be taken, when more connections than . + + + + + + Gets or sets the maximum queue size for a single connection. Requires = true + + + When having reached the maximum limit, then action will apply. + + + + + + Gets or sets the action that should be taken, when more pending messages than . + + + + + + Occurs when LogEvent has been dropped. + + + - When internal queue is full and set to
+ - When connection-list is full and set to
+ - When message is too big and set to
+
+
+ + + Gets or sets the size of the connection cache (number of connections which are kept alive). Requires = true + + + + + + Gets or sets the action that should be taken if the message is larger than + + + For TCP sockets then means no-limit, as TCP sockets + performs splitting automatically. + + For UDP Network sender then means splitting the message + into smaller chunks. This can be useful on networks using DontFragment, which drops network packages + larger than MTU-size (1472 bytes). + + + + + + Gets or sets the encoding to be used. + + + + + + Gets or sets the SSL/TLS protocols. Default no SSL/TLS is used. Currently only implemented for TCP. + + + + + + The number of seconds a connection will remain idle before the first keep-alive probe is sent + + + + + + Type of compression for protocol payload. Useful for UDP where datagram max-size is 8192 bytes. + + + + + Skip compression when protocol payload is below limit to reduce overhead in cpu-usage and additional headers + + + + + Flush any pending log messages asynchronously (in case of asynchronous targets). + + The asynchronous continuation. + + + + + + + Sends the + rendered logging event over the network optionally concatenating it with a newline character. + + The logging event. + + + + Try to remove. + + + + + removed something? + + + + Gets the bytes to be written. + + Log event. + Byte array. + + + + Type of compression for protocol payload + + + + + No compression + + + + + GZip optimal compression + + + + + GZip fastest compression + + + + + The action to be taken when there are more connections then the max. + + + + + Allow new connections when reaching max connection limit + + + + + Obsolete and replaced by with NLog v5. + Just allow it. + + + + + Discard new messages when reaching max connection limit + + + + + Obsolete and replaced by with NLog v5. + Discard the connection item. + + + + + Block until there's more room in the queue. + + + + + Action that should be taken if the message overflows. + + + + + Report an error. + + + + + Split the message into smaller pieces. Only relevant for UDP sockets, as TCP sockets does it automatically. + + + Udp-Network-Sender will split the message into smaller chunks that matches . + This can avoid network-package-drop when network uses DontFragment and message is larger than MTU-size (1472 bytes). + + + + + Discard the entire message. + + + + + The action to be taken when the queue overflows. + + + + + Grow the queue. + + + + + Discard the overflowing item. + + + + + Block until there's more room in the queue. + + + + + Represents a parameter to a NLogViewer target. + + + + + Initializes a new instance of the class. + + + + + Gets or sets viewer parameter name. + + + + + + Gets or sets the layout that should be use to calculate the value for the parameter. + + + + + + Gets or sets whether an attribute with empty value should be included in the output + + + + + + Sends log messages to the remote instance of NLog Viewer. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + Gets or sets a value indicating whether to include NLog-specific extensions to log4j schema. + + + + + + Gets or sets the AppInfo field. By default it's the friendly name of the current AppDomain. + + + + + + Gets or sets a value indicating whether to include call site (class and method name) in the information sent over the network. + + + + + + Gets or sets a value indicating whether to include source info (file name and line number) in the information sent over the network. + + + + + + Obsolete and replaced by with NLog v5. + Gets or sets a value indicating whether to include dictionary contents. + + + + + + Gets or sets whether to include log4j:NDC in output from nested context. + + + + + + Gets or sets the option to include all properties from the log events + + + + + + Gets or sets whether to include the contents of the properties-dictionary. + + + + + + Gets or sets whether to include log4j:NDC in output from nested context. + + + + + + Gets or sets the separator for operation-states-stack. + + + + + + Obsolete and replaced by with NLog v5. + Gets or sets the option to include all properties from the log events + + + + + + Obsolete and replaced by with NLog v5. + Gets or sets a value indicating whether to include dictionary contents. + + + + + + Obsolete and replaced by with NLog v5. + Gets or sets a value indicating whether to include contents of the stack. + + + + + + Obsolete and replaced by with NLog v5. + Gets or sets the stack separator for log4j:NDC in output from nested context. + + + + + + Gets or sets the stack separator for log4j:NDC in output from nested context. + + + + + + Gets or sets the renderer for log4j:event logger-xml-attribute (Default ${logger}) + + + + + + Gets the collection of parameters. Each parameter contains a mapping + between NLog layout and a named parameter. + + + + + + Gets the layout renderer which produces Log4j-compatible XML events. + + + + + Gets or sets the instance of that is used to format log messages. + + + + + + Discards log messages. Used mainly for debugging and benchmarking. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Gets or sets a value indicating whether to perform layout calculation. + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + + + + Does nothing. Optionally it calculates the layout text but + discards the results. + + The logging event. + + + + SMTP authentication modes. + + + + + No authentication. + + + + + Basic - username and password. + + + + + NTLM Authentication. + + + + + Represents logging target. + + + + Are all layouts in this target thread-agnostic, if so we don't precalculate the layouts + + + + The Max StackTraceUsage of all the in this Target + + + + + Gets or sets the name of the target. + + + + + + Target supports reuse of internal buffers, and doesn't have to constantly allocate new buffers + Required for legacy NLog-targets, that expects buffers to remain stable after Write-method exit + + + + + + NLog Layout are by default threadsafe, so multiple threads can be rendering logevents at the same time. + This ensure high concurrency with no lock-congestion for the application-threads, especially when using + or AsyncTaskTarget. + + But if using custom or that are not + threadsafe, then this option can enabled to protect against thread-concurrency-issues. Allowing one + to update to NLog 5.0 without having to fix custom/external layout-dependencies. + + + + + + Gets the object which can be used to synchronize asynchronous operations that must rely on the . + + + + + Gets the logging configuration this target is part of. + + + + + Gets a value indicating whether the target has been initialized. + + + + + Initializes this instance. + + The configuration. + + + + Closes this instance. + + + + + Closes the target. + + + + + Flush any pending log messages (in case of asynchronous targets). + + The asynchronous continuation. + + + + Calls the on each volatile layout + used by this target. + This method won't prerender if all layouts in this target are thread-agnostic. + + + The log event. + + + + + + + + Writes the log to the target. + + Log event to write. + + + + Writes the array of log events. + + The log events. + + + + Writes the array of log events. + + The log events. + + + + LogEvent is written to target, but target failed to successfully initialize + + + + + Initializes this instance. + + The configuration. + + + + Closes this instance. + + + + + Releases unmanaged and - optionally - managed resources. + + True to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Initializes the target before writing starts + + + + + Closes the target to release any initialized resources + + + + + Flush any pending log messages + + The asynchronous continuation parameter must be called on flush completed + The asynchronous continuation to be called on flush completed. + + + + Writes logging event to the target destination + + Logging event to be written out. + + + + Writes async log event to the log target. + + Async Log event to be written out. + + + + Writes a log event to the log target, in a thread safe manner. + Any override of this method has to provide their own synchronization mechanism. + + !WARNING! Custom targets should only override this method if able to provide their + own synchronization mechanism. -objects are not guaranteed to be + thread-safe, so using them without a SyncRoot-object can be dangerous. + + Log event to be written out. + + + + Writes an array of logging events to the log target. By default it iterates on all + events and passes them to "Write" method. Inheriting classes can use this method to + optimize batch writes. + + Logging events to be written out. + + + + Writes an array of logging events to the log target, in a thread safe manner. + Any override of this method has to provide their own synchronization mechanism. + + !WARNING! Custom targets should only override this method if able to provide their + own synchronization mechanism. -objects are not guaranteed to be + thread-safe, so using them without a SyncRoot-object can be dangerous. + + Logging events to be written out. + + + + Merges (copies) the event context properties from any event info object stored in + parameters of the given event info object. + + The event info object to perform the merge to. + + + + Renders the logevent into a string-result using the provided layout + + The layout. + The logevent info. + String representing log event. + + + + Renders the logevent into a result-value by using the provided layout + + + The layout. + The logevent info. + Fallback value when no value available + Result value when available, else fallback to defaultValue + + + + Resolve from DI + + Avoid calling this while handling a LogEvent, since random deadlocks can occur. + + + + Should the exception be rethrown? + + Upgrade to private protected when using C# 7.2 + + + + + Obsolete and replaced by with NLog v5.2. + + Register a custom Target. + + Short-cut for registering to default + Type of the Target. + The target type-alias for use in NLog configuration + + + + Obsolete and replaced by with NLog v5.2. + + Register a custom Target. + + Short-cut for registering to default + Type of the Target. + The target type-alias for use in NLog configuration + + + + Marks class as logging target and attaches a type-alias name for use in NLog configuration. + + + + + Initializes a new instance of the class. + + The target type-alias for use in NLog configuration. + + + + Gets or sets a value indicating whether to the target is a wrapper target (used to generate the target summary documentation page). + + + + + Gets or sets a value indicating whether to the target is a compound target (used to generate the target summary documentation page). + + + + + Attribute details for + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The name of the attribute. + The layout of the attribute's value. + + + + Gets or sets the name of the attribute. + + + + + + Gets or sets the layout that will be rendered as the attribute's value. + + + + + + Gets or sets the type of the property. + + + + + + Gets or sets the fallback value when result value is not available + + + + + + Gets or sets when an empty value should cause the property to be included + + + + + + Render Result Value + + Log event for rendering + Result value when available, else fallback to defaultValue + + + + Represents target that supports context capture of Properties + Nested-states + + + See NLog Wiki + + + [Target("MyFirst")] + public sealed class MyFirstTarget : TargetWithContext + { + public MyFirstTarget() + { + this.Host = "localhost"; + } + + [RequiredParameter] + public Layout Host { get; set; } + + protected override void Write(LogEventInfo logEvent) + { + string logMessage = this.RenderLogEvent(this.Layout, logEvent); + string hostName = this.RenderLogEvent(this.Host, logEvent); + return SendTheMessageToRemoteHost(hostName, logMessage); + } + + private void SendTheMessageToRemoteHost(string hostName, string message) + { + // To be implemented + } + } + + Documentation on NLog Wiki + + + + + + + + Gets or sets the option to include all properties from the log events + + + + + + Gets or sets whether to include the contents of the properties-dictionary. + + + + + + Gets or sets whether to include the contents of the nested-state-stack. + + + + + + Obsolete and replaced by with NLog v5. + Gets or sets whether to include the contents of the -dictionary. + + + + + + Obsolete and replaced by with NLog v5. + Gets or sets whether to include the contents of the -stack. + + + + + + Obsolete and replaced by with NLog v5. + Gets or sets whether to include the contents of the -properties. + + + + + + Obsolete and replaced by with NLog v5. + Gets or sets whether to include the contents of the -stack. + + + + + + Gets or sets a value indicating whether to include contents of the dictionary + + + + + + Gets or sets a value indicating whether to include call site (class and method name) in the + + + + + + Gets or sets a value indicating whether to include source info (file name and line number) in the + + + + + + Gets the array of custom attributes to be passed into the logevent context + + + + + + List of property names to exclude when is true + + + + + + Constructor + + + + + Check if logevent has properties (or context properties) + + + True if properties should be included + + + + Checks if any context properties, and if any returns them as a single dictionary + + + Dictionary with any context properties for the logEvent (Null if none found) + + + + Checks if any context properties, and if any returns them as a single dictionary + + + Optional prefilled dictionary + Dictionary with any context properties for the logEvent (Null if none found) + + + + Creates combined dictionary of all configured properties for logEvent + + + Dictionary with all collected properties for logEvent + + + + Creates combined dictionary of all configured properties for logEvent + + + Optional prefilled dictionary + Dictionary with all collected properties for logEvent + + + + Generates a new unique name, when duplicate names are detected + + LogEvent that triggered the duplicate name + Duplicate item name + Item Value + Dictionary of context values + New (unique) value (or null to skip value). If the same value is used then the item will be overwritten + + + + Obsolete and replaced by with NLog v5. + Returns the captured snapshot of for the + + + Dictionary with MDC context if any, else null + + + + Returns the captured snapshot of dictionary for the + + + Dictionary with ScopeContext properties if any, else null + + + + Obsolete and replaced by with NLog v5. + Returns the captured snapshot of for the + + + Dictionary with MDLC context if any, else null + + + + Obsolete and replaced by with NLog v5. + Returns the captured snapshot of for the + + + Collection with NDC context if any, else null + + + + Returns the captured snapshot of nested states from for the + + + Collection of nested state objects if any, else null + + + + Obsolete and replaced by with NLog v5. + Returns the captured snapshot of for the + + + Collection with NDLC context if any, else null + + + + Takes snapshot of for the + + + Optional pre-allocated dictionary for the snapshot + Dictionary with GDC context if any, else null + + + + Obsolete and replaced by with NLog v5. + Takes snapshot of for the + + + Optional pre-allocated dictionary for the snapshot + Dictionary with MDC context if any, else null + + + + Obsolete and replaced by with NLog v5. + Take snapshot of a single object value from + + Log event + MDC key + MDC value + Snapshot of MDC value + Include object value in snapshot + + + + Obsolete and replaced by with NLog v5. + Takes snapshot of for the + + + Optional pre-allocated dictionary for the snapshot + Dictionary with MDLC context if any, else null + + + + Takes snapshot of dictionary for the + + + Optional pre-allocated dictionary for the snapshot + Dictionary with ScopeContext properties if any, else null + + + + Obsolete and replaced by with NLog v5. + Take snapshot of a single object value from + + Log event + MDLC key + MDLC value + Snapshot of MDLC value + Include object value in snapshot + + + + Take snapshot of a single object value from dictionary + + Log event + ScopeContext Dictionary key + ScopeContext Dictionary value + Snapshot of ScopeContext property-value + Include object value in snapshot + + + + Obsolete and replaced by with NLog v5. + Takes snapshot of for the + + + Collection with NDC context if any, else null + + + + Obsolete and replaced by with NLog v5. + Take snapshot of a single object value from + + Log event + NDC value + Snapshot of NDC value + Include object value in snapshot + + + + Obsolete and replaced by with NLog v5. + Takes snapshot of for the + + + Collection with NDLC context if any, else null + + + + Takes snapshot of nested states from for the + + + Collection with stack items if any, else null + + + + Obsolete and replaced by with NLog v5. + Take snapshot of a single object value from + + Log event + NDLC value + Snapshot of NDLC value + Include object value in snapshot + + + + Take snapshot of a single object value from nested states + + Log event + nested state value + Snapshot of stack item value + Include object value in snapshot + + + + Take snapshot of a single object value + + Log event + Key Name (null when NDC / NDLC) + Object Value + Snapshot of value + Include object value in snapshot + + + Internal Layout that allows capture of properties-dictionary + + + Internal Layout that allows capture of nested-states-stack + + + + Represents target that supports string formatting using layouts. + + + See NLog Wiki + + Documentation on NLog Wiki + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Gets or sets the layout used to format log messages. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + + Represents target that supports string formatting using layouts. + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Gets or sets the text to be rendered. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + + Gets or sets the footer. + + + + + + Gets or sets the header. + + + + + + Gets or sets the layout with header and footer. + + The layout with header and footer. + + + + Sends log messages through System.Diagnostics.Trace. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Force use independent of + + + + + + Forward to (Instead of ) + + + Trace.Fail can have special side-effects, and give fatal exceptions, message dialogs or Environment.FailFast + + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + + + + Initializes a new instance of the class. + + + The default value of the layout is: ${longdate}|${level:uppercase=true}|${logger}|${message:withexception=true} + + Name of the target. + + + + + + + + + + Writes the specified logging event to the facility. + + Redirects the log message depending on and . + When is false: + - writes to + - writes to + - writes to + - writes to + - writes to + - writes to + + The logging event. + + + + Web service protocol. + + + + + Use SOAP 1.1 Protocol. + + + + + Use SOAP 1.2 Protocol. + + + + + Use HTTP POST Protocol. + + + + + Use HTTP GET Protocol. + + + + + Do an HTTP POST of a JSON document. + + + + + Do an HTTP POST of an XML document. + + + + + Web Service Proxy Configuration Type + + + + + Default proxy configuration from app.config (System.Net.WebRequest.DefaultWebProxy) + + + Example of how to configure default proxy using app.config + + <system.net> + <defaultProxy enabled = "true" useDefaultCredentials = "true" > + <proxy usesystemdefault = "True" /> + </defaultProxy> + </system.net> + + + + + + Automatic use of proxy with authentication (cached) + + + + + Disables use of proxy (fast) + + + + + Custom proxy address (cached) + + + + + Calls the specified web service on each log message. + + + See NLog Wiki + + Documentation on NLog Wiki + + The web service must implement a method that accepts a number of string parameters. + + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +

The example web service that works with this example is shown below

+ +
+
+ + + dictionary that maps a concrete implementation + to a specific -value. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target + + + + Gets or sets the web service URL. + + + + + + Gets or sets the value of the User-agent HTTP header. + + + + + + Gets or sets the Web service method name. Only used with Soap. + + + + + + Gets or sets the Web service namespace. Only used with Soap. + + + + + + Gets or sets the protocol to be used when calling web service. + + + + + + Gets or sets the proxy configuration when calling web service + + + Changing ProxyType on Net5 (or newer) will turn off Http-connection-pooling + + + + + + Gets or sets the custom proxy address, include port separated by a colon + + + + + + Should we include the BOM (Byte-order-mark) for UTF? Influences the property. + + This will only work for UTF-8. + + + + + + Gets or sets the encoding. + + + + + + Gets or sets a value whether escaping be done according to Rfc3986 (Supports Internationalized Resource Identifiers - IRIs) + + A value of true if Rfc3986; otherwise, false for legacy Rfc2396. + + + + + Gets or sets a value whether escaping be done according to the old NLog style (Very non-standard) + + A value of true if legacy encoding; otherwise, false for standard UTF8 encoding. + + + + + Gets or sets the name of the root XML element, + if POST of XML document chosen. + If so, this property must not be null. + (see and ). + + + + + + Gets or sets the (optional) root namespace of the XML document, + if POST of XML document chosen. + (see and ). + + + + + + Gets the array of parameters to be passed. + + + + + + Indicates whether to pre-authenticate the HttpWebRequest (Requires 'Authorization' in parameters) + + + + + + Calls the target method. Must be implemented in concrete classes. + + Method call parameters. + + + + Calls the target DoInvoke method, and handles AsyncContinuation callback + + Method call parameters. + The continuation. + + + + Invokes the web service method. + + Parameters to be passed. + The logging event. + + + + + + + + + + Builds the URL to use when calling the web service for a message, depending on the WebServiceProtocol. + + + + + Write from input to output. Fix the UTF-8 bom + + + + + base class for POST formatters, that + implement former PrepareRequest() method, + that creates the content for + the requested kind of HTTP request + + + + + Win32 file attributes. + + + For more information see https://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/fs/createfile.asp. + + + + + Read-only file. + + + + + Hidden file. + + + + + System file. + + + + + File should be archived. + + + + + Device file. + + + + + Normal file. + + + + + File is temporary (should be kept in cache and not + written to disk if possible). + + + + + Sparse file. + + + + + Reparse point. + + + + + Compress file contents. + + + + + File should not be indexed by the content indexing service. + + + + + Encrypted file. + + + + + The system writes through any intermediate cache and goes directly to disk. + + + + + The system opens a file with no system caching. + + + + + Delete file after it is closed. + + + + + A file is accessed according to POSIX rules. + + + + + Asynchronous request queue. + + + + + Initializes a new instance of the AsyncRequestQueue class. + + Request limit. + The overflow action. + + + + Gets the number of requests currently in the queue. + + + + + Enqueues another item. If the queue is overflown the appropriate + action is taken as specified by . + + The log event info. + Queue was empty before enqueue + + + + Dequeues a maximum of count items from the queue + and adds returns the list containing them. + + Maximum number of items to be dequeued + The array of log events. + + + + Dequeues into a preallocated array, instead of allocating a new one + + Maximum number of items to be dequeued + Preallocated list + + + + Clears the queue. + + + + + Gets or sets the request limit. + + + + + Gets or sets the action to be taken when there's no more room in + the queue and another request is enqueued. + + + + + Occurs when LogEvent has been dropped, because internal queue is full and set to + + + + + Occurs when internal queue size is growing, because internal queue is full and set to + + + + + Raise event when queued element was dropped because of queue overflow + + Dropped queue item + + + + Raise event when RequestCount overflow + + current requests count + + + + Provides asynchronous, buffered execution of target writes. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ Asynchronous target wrapper allows the logger code to execute more quickly, by queuing + messages and processing them in a separate thread. You should wrap targets + that spend a non-trivial amount of time in their Write() method with asynchronous + target to speed up logging. +

+

+ Because asynchronous logging is quite a common scenario, NLog supports a + shorthand notation for wrapping all targets with AsyncWrapper. Just add async="true" to + the <targets/> element in the configuration file. +

+ + + ... your targets go here ... + + ]]> +
+ +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + The wrapped target. + + + + Initializes a new instance of the class. + + The wrapped target. + + + + Initializes a new instance of the class. + + The wrapped target. + Maximum number of requests in the queue. + The action to be taken when the queue overflows. + + + + Gets or sets the number of log events that should be processed in a batch + by the lazy writer thread. + + + + + + Gets or sets the time in milliseconds to sleep between batches. (1 or less means trigger on new activity) + + + + + + Occurs when LogEvent has been dropped, because internal queue is full and set to + + + + + Occurs when internal queue size is growing, because internal queue is full and set to + + + + + Gets or sets the action to be taken when the lazy writer thread request queue count + exceeds the set limit. + + + + + + Gets or sets the limit on the number of requests in the lazy writer thread request queue. + + + + + + Gets or sets the number of batches of to write before yielding into + + + Performance is better when writing many small batches, than writing a single large batch + + + + + + Gets or sets whether to use the locking queue, instead of a lock-free concurrent queue + + + The locking queue is less concurrent when many logger threads, but reduces memory allocation + + + + + + Gets the queue of lazy writer thread requests. + + + + + Schedules a flush of pending events in the queue (if any), followed by flushing the WrappedTarget. + + The asynchronous continuation. + + + + Initializes the target by starting the lazy writer timer. + + + + + Shuts down the lazy writer timer. + + + + + Starts the lazy writer thread which periodically writes + queued log messages. + + + + + Attempts to start an instant timer-worker-thread which can write + queued log messages. + + Returns true when scheduled a timer-worker-thread + + + + Stops the lazy writer thread. + + + + + Adds the log event to asynchronous queue to be processed by + the lazy writer thread. + + The log event. + + The is called + to ensure that the log event can be processed in another thread. + + + + + Write to queue without locking + + + + + + The action to be taken when the queue overflows. + + + + + Grow the queue. + + + + + Discard the overflowing item. + + + + + Block until there's more room in the queue. + + + + + Causes a flush on a wrapped target if LogEvent satisfies the . + If condition isn't set, flushes on each write. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Gets or sets the condition expression. Log events who meet this condition will cause + a flush on the wrapped target. + + + + + + Delay the flush until the LogEvent has been confirmed as written + + If not explicitly set, then disabled by default for and AsyncTaskTarget + + + + + + Only flush when LogEvent matches condition. Ignore explicit-flush, config-reload-flush and shutdown-flush + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The wrapped target. + Name of the target + + + + Initializes a new instance of the class. + + The wrapped target. + + + + + + + Forwards the call to the .Write() + and calls on it if LogEvent satisfies + the flush condition or condition is null. + + Logging event to be written out. + + + + Schedules a flush operation, that triggers when all pending flush operations are completed (in case of asynchronous targets). + + The asynchronous continuation. + + + + + + + A target that buffers log events and sends them in batches to the wrapped target. + + + See NLog Wiki + + Documentation on NLog Wiki + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + The wrapped target. + + + + Initializes a new instance of the class. + + The wrapped target. + + + + Initializes a new instance of the class. + + The wrapped target. + Size of the buffer. + + + + Initializes a new instance of the class. + + The wrapped target. + Size of the buffer. + The flush timeout. + + + + Initializes a new instance of the class. + + The wrapped target. + Size of the buffer. + The flush timeout. + The action to take when the buffer overflows. + + + + Gets or sets the number of log events to be buffered. + + + + + + Gets or sets the timeout (in milliseconds) after which the contents of buffer will be flushed + if there's no write in the specified period of time. Use -1 to disable timed flushes. + + + + + + Gets or sets a value indicating whether to use sliding timeout. + + + This value determines how the inactivity period is determined. If sliding timeout is enabled, + the inactivity timer is reset after each write, if it is disabled - inactivity timer will + count from the first event written to the buffer. + + + + + + Gets or sets the action to take if the buffer overflows. + + + Setting to will replace the + oldest event with new events without sending events down to the wrapped target, and + setting to will flush the + entire buffer to the wrapped target. + + + + + + Flushes pending events in the buffer (if any), followed by flushing the WrappedTarget. + + The asynchronous continuation. + + + + + + + Closes the target by flushing pending events in the buffer (if any). + + + + + Adds the specified log event to the buffer and flushes + the buffer in case the buffer gets full. + + The log event. + + + + The action to be taken when the buffer overflows. + + + + + Flush the content of the buffer. + + + + + Discard the oldest item. + + + + + A base class for targets which wrap other (multiple) targets + and provide various forms of target routing. + + + + + Initializes a new instance of the class. + + The targets. + + + + Gets the collection of targets managed by this compound target. + + + + + + + + + + + Flush any pending log messages for all wrapped targets. + + The asynchronous continuation. + + + + Concurrent Asynchronous request queue based on + + + + + Initializes a new instance of the AsyncRequestQueue class. + + Request limit. + The overflow action. + + + + Gets the number of requests currently in the queue. + + + Only for debugging purposes + + + + + Enqueues another item. If the queue is overflown the appropriate + action is taken as specified by . + + The log event info. + Queue was empty before enqueue + + + + Dequeues a maximum of count items from the queue + and adds returns the list containing them. + + Maximum number of items to be dequeued + The array of log events. + + + + Dequeues into a preallocated array, instead of allocating a new one + + Maximum number of items to be dequeued + Preallocated list + + + + Clears the queue. + + + + + Provides fallback-on-error. + + + See NLog Wiki + + Documentation on NLog Wiki + +

This example causes the messages to be written to server1, + and if it fails, messages go to server2.

+

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + The targets. + + + + Initializes a new instance of the class. + + The targets. + + + + Gets or sets a value indicating whether to return to the first target after any successful write. + + + + + + Gets or sets whether to enable batching, but fallback will be handled individually + + + + + + Forwards the log event to the sub-targets until one of them succeeds. + + The log event. + + + + + + + Forwards the log event to the sub-targets until one of them succeeds. + + + + + Filtering rule for . + + + + + Initializes a new instance of the FilteringRule class. + + + + + Initializes a new instance of the FilteringRule class. + + Condition to be tested against all events. + Filter to apply to all log events when the first condition matches any of them. + + + + Gets or sets the condition to be tested. + + + + + + Gets or sets the resulting filter to be applied when the condition matches. + + + + + + Filters log entries based on a condition. + + + See NLog Wiki + + Documentation on NLog Wiki + +

This example causes the messages not contains the string '1' to be ignored.

+

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + The wrapped target. + The condition. + + + + Initializes a new instance of the class. + + The wrapped target. + The condition. + + + + Gets or sets the condition expression. Log events who meet this condition will be forwarded + to the wrapped target. + + + + + + Gets or sets the filter. Log events who evaluates to will be discarded + + + + + + Checks the condition against the passed log event. + If the condition is met, the log event is forwarded to + the wrapped target. + + Log event. + + + + + + + A target that buffers log events and sends them in batches to the wrapped target. + + + See NLog Wiki + + Documentation on NLog Wiki + + + + Identifier to perform group-by + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The wrapped target. + + + + Initializes a new instance of the class. + + The name of the target. + The wrapped target. + + + + Initializes a new instance of the class. + + The name of the target. + The wrapped target. + Group by identifier. + + + + + + + + + + Limits the number of messages written per timespan to the wrapped target. + + + See NLog Wiki + + Documentation on NLog Wiki + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + The name of the target. + The wrapped target. + + + + Initializes a new instance of the class. + + The wrapped target. + + + + Initializes a new instance of the class. + + The wrapped target. + Maximum number of messages written per interval. + Interval in which the maximum number of messages can be written. + + + + Gets or sets the maximum allowed number of messages written per . + + + Messages received after has been reached in the current will be discarded. + + + + + + Gets or sets the interval in which messages will be written up to the number of messages. + + + Messages received after has been reached in the current will be discarded. + + + + + + Gets the number of written in the current . + + + + + + Initializes the target and resets the current Interval and . + + + + + Writes log event to the wrapped target if the current is lower than . + If the is already reached, no log event will be written to the wrapped target. + resets when the current is expired. + + Log event to be written out. + + + + Arguments for events. + + + + + Initializes a new instance of the class. + + LogEvent that have been dropped + + + + Instance of that was dropped by + + + + + Raises by when + queue is full + and set to + By default queue doubles it size. + + + + + Initializes a new instance of the class. + + Required queue size + Current queue size + + + + New queue size + + + + + Current requests count + + + + + Filters buffered log entries based on a set of conditions that are evaluated on a group of events. + + + See NLog Wiki + + Documentation on NLog Wiki + +

+ This example works like this. If there are no Warn,Error or Fatal messages in the buffer + only Info messages are written to the file, but if there are any warnings or errors, + the output includes detailed trace (levels >= Debug). +

+

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + The wrapped target. + + + + Gets or sets the default filter to be applied when no specific rule matches. + + + + + + Gets the collection of filtering rules. The rules are processed top-down + and the first rule that matches determines the filtering condition to + be applied to log events. + + + + + + + + + Evaluates all filtering rules to find the first one that matches. + The matching rule determines the filtering condition to be applied + to all items in a buffer. If no condition matches, default filter + is applied to the array of log events. + + Array of log events to be post-filtered. + + + + Evaluate all the rules to get the filtering condition + + + + + + + Sends log messages to a randomly selected target. + + + See NLog Wiki + + Documentation on NLog Wiki + +

This example causes the messages to be written to either file1.txt or file2.txt + chosen randomly on a per-message basis. +

+

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + The targets. + + + + Initializes a new instance of the class. + + The targets. + + + + Forwards the log event to one of the sub-targets. + The sub-target is randomly chosen. + + The log event. + + + + Repeats each log event the specified number of times. + + + See NLog Wiki + + Documentation on NLog Wiki + +

This example causes each log message to be repeated 3 times.

+

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + The wrapped target. + The repeat count. + + + + Initializes a new instance of the class. + + The wrapped target. + The repeat count. + + + + Gets or sets the number of times to repeat each log message. + + + + + + Forwards the log message to the by calling the method times. + + The log event. + + + + Retries in case of write error. + + + See NLog Wiki + + Documentation on NLog Wiki + +

This example causes each write attempt to be repeated 3 times, + sleeping 1 second between attempts if first one fails.

+

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + The wrapped target. + The retry count. + The retry delay milliseconds. + + + + Initializes a new instance of the class. + + The wrapped target. + The retry count. + The retry delay milliseconds. + + + + Gets or sets the number of retries that should be attempted on the wrapped target in case of a failure. + + + + + + Gets or sets the time to wait between retries in milliseconds. + + + + + + Gets or sets whether to enable batching, and only apply single delay when a whole batch fails + + + + + + Special SyncObject to allow closing down Target while busy retrying + + + + + Writes the specified log event to the wrapped target, retrying and pausing in case of an error. + + The log event. + + + + Writes the specified log event to the wrapped target in a thread-safe manner. + + The log event. + + + + Writes the specified log event to the wrapped target, retrying and pausing in case of an error. + + The log event. + + + + Distributes log events to targets in a round-robin fashion. + + + See NLog Wiki + + Documentation on NLog Wiki + +

This example causes the messages to be written to either file1.txt or file2.txt. + Each odd message is written to file2.txt, each even message goes to file1.txt. +

+

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + The targets. + + + + Initializes a new instance of the class. + + The targets. + + + + Ensures forwarding happens without holding lock + + + + + + Forwards the write to one of the targets from + the collection. + + The log event. + + The writes are routed in a round-robin fashion. + The first log event goes to the first target, the second + one goes to the second target and so on looping to the + first target when there are no more targets available. + In general request N goes to Targets[N % Targets.Count]. + + + + + Writes log events to all targets. + + + See NLog Wiki + + Documentation on NLog Wiki + +

This example causes the messages to be written to both file1.txt or file2.txt +

+

+ To set up the target in the configuration file, + use the following syntax: +

+ +

+ To set up the log target programmatically use code like this: +

+ +
+
+ + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + Name of the target. + The targets. + + + + Initializes a new instance of the class. + + The targets. + + + + Forwards the specified log event to all sub-targets. + + The log event. + + + + Writes an array of logging events to the log target. By default it iterates on all + events and passes them to "Write" method. Inheriting classes can use this method to + optimize batch writes. + + Logging events to be written out. + + + + Base class for targets wrap other (single) targets. + + + + + Gets or sets the target that is wrapped by this target. + + + + + + + + + + + + Writes logging event to the log target. Must be overridden in inheriting + classes. + + Logging event to be written out. + + + + Builtin IFileCompressor implementation utilizing the .Net4.5 specific + and is used as the default value for on .Net4.5. + So log files created via can be zipped when archived + w/o 3rd party zip library when run on .Net4.5 or higher. + + + + + Implements using the .Net4.5 specific + + + + + Current local time retrieved directly from DateTime.Now. + + + + + Gets current local time directly from DateTime.Now. + + + + + Converts the specified system time to the same form as the time value originated from this time source. + + The system originated time value to convert. + + The value of converted to local time. + + + + + Current UTC time retrieved directly from DateTime.UtcNow. + + + + + Gets current UTC time directly from DateTime.UtcNow. + + + + + Converts the specified system time to the same form as the time value originated from this time source. + + The system originated time value to convert. + + The value of converted to UTC time. + + + + + Fast time source that updates current time only once per tick (15.6 milliseconds). + + + + + Gets raw uncached time from derived time source. + + + + + Gets current time cached for one system tick (15.6 milliseconds). + + + + + Fast local time source that is updated once per tick (15.6 milliseconds). + + + + + Gets uncached local time directly from DateTime.Now. + + + + + Converts the specified system time to the same form as the time value originated from this time source. + + The system originated time value to convert. + + The value of converted to local time. + + + + + Fast UTC time source that is updated once per tick (15.6 milliseconds). + + + + + Gets uncached UTC time directly from DateTime.UtcNow. + + + + + Converts the specified system time to the same form as the time value originated from this time source. + + The system originated time value to convert. + + The value of converted to UTC time. + + + + + Defines source of current time. + + + + + Gets current time. + + + + + Gets or sets current global time source used in all log events. + + + Default time source is . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Converts the specified system time to the same form as the time value originated from this time source. + + The system originated time value to convert. + + The value of converted to the same form + as time values originated from this source. + + + + There are situations when NLog have to compare the time originated from TimeSource + to the time originated externally in the system. + To be able to provide meaningful result of such comparisons the system time must be expressed in + the same form as TimeSource time. + + + Examples: + - If the TimeSource provides time values of local time, it should also convert the provided + to the local time. + - If the TimeSource shifts or skews its time values, it should also apply + the same transform to the given . + + + + + + Marks class as a time source and assigns a name to it. + + + + + Initializes a new instance of the class. + + The Time type-alias for use in NLog configuration. + + + + Indicates that the value of the marked element could be null sometimes, + so checking for null is required before its usage. + + + [CanBeNull] object Test() => null; + + void UseTest() { + var p = Test(); + var s = p.ToString(); // Warning: Possible 'System.NullReferenceException' + } + + + + + Indicates that the value of the marked element can never be null. + + + [NotNull] object Foo() { + return null; // Warning: Possible 'null' assignment + } + + + + + Can be applied to symbols of types derived from IEnumerable as well as to symbols of Task + and Lazy classes to indicate that the value of a collection item, of the Task.Result property + or of the Lazy.Value property can never be null. + + + public void Foo([ItemNotNull]List<string> books) + { + foreach (var book in books) { + if (book != null) // Warning: Expression is always true + Console.WriteLine(book.ToUpper()); + } + } + + + + + Can be applied to symbols of types derived from IEnumerable as well as to symbols of Task + and Lazy classes to indicate that the value of a collection item, of the Task.Result property + or of the Lazy.Value property can be null. + + + public void Foo([ItemCanBeNull]List<string> books) + { + foreach (var book in books) + { + // Warning: Possible 'System.NullReferenceException' + Console.WriteLine(book.ToUpper()); + } + } + + + + + Indicates that the marked method builds string by the format pattern and (optional) arguments. + The parameter, which contains the format string, should be given in the constructor. The format string + should be in -like form. + + + [StringFormatMethod("message")] + void ShowError(string message, params object[] args) { /* do something */ } + + void Foo() { + ShowError("Failed: {0}"); // Warning: Non-existing argument in format string + } + + + + + Specifies which parameter of an annotated method should be treated as the format string + + + + + Indicates that the marked parameter is a message template where placeholders are to be replaced by the following arguments + in the order in which they appear + + + void LogInfo([StructuredMessageTemplate]string message, params object[] args) { /* do something */ } + + void Foo() { + LogInfo("User created: {username}"); // Warning: Non-existing argument in format string + } + + + + + Use this annotation to specify a type that contains static or const fields + with values for the annotated property/field/parameter. + The specified type will be used to improve completion suggestions. + + + namespace TestNamespace + { + public class Constants + { + public static int INT_CONST = 1; + public const string STRING_CONST = "1"; + } + + public class Class1 + { + [ValueProvider("TestNamespace.Constants")] public int myField; + public void Foo([ValueProvider("TestNamespace.Constants")] string str) { } + + public void Test() + { + Foo(/*try completion here*/);// + myField = /*try completion here*/ + } + } + } + + + + + Indicates that the integral value falls into the specified interval. + It's allowed to specify multiple non-intersecting intervals. + Values of interval boundaries are inclusive. + + + void Foo([ValueRange(0, 100)] int value) { + if (value == -1) { // Warning: Expression is always 'false' + ... + } + } + + + + + Indicates that the integral value never falls below zero. + + + void Foo([NonNegativeValue] int value) { + if (value == -1) { // Warning: Expression is always 'false' + ... + } + } + + + + + Indicates that the function argument should be a string literal and match + one of the parameters of the caller function. This annotation is used for parameters + like 'string paramName' parameter of the constructor. + + + void Foo(string param) { + if (param == null) + throw new ArgumentNullException("par"); // Warning: Cannot resolve symbol + } + + + + + Indicates that the method is contained in a type that implements + System.ComponentModel.INotifyPropertyChanged interface and this method + is used to notify that some property value changed. + + + The method should be non-static and conform to one of the supported signatures: + + NotifyChanged(string) + NotifyChanged(params string[]) + NotifyChanged{T}(Expression{Func{T}}) + NotifyChanged{T,U}(Expression{Func{T,U}}) + SetProperty{T}(ref T, T, string) + + + + public class Foo : INotifyPropertyChanged { + public event PropertyChangedEventHandler PropertyChanged; + + [NotifyPropertyChangedInvocator] + protected virtual void NotifyChanged(string propertyName) { ... } + + string _name; + + public string Name { + get { return _name; } + set { _name = value; NotifyChanged("LastName"); /* Warning */ } + } + } + + Examples of generated notifications: + + NotifyChanged("Property") + NotifyChanged(() => Property) + NotifyChanged((VM x) => x.Property) + SetProperty(ref myField, value, "Property") + + + + + + Describes dependency between method input and output. + + +

Function Definition Table syntax:

+ + FDT ::= FDTRow [;FDTRow]* + FDTRow ::= Input => Output | Output <= Input + Input ::= ParameterName: Value [, Input]* + Output ::= [ParameterName: Value]* {halt|stop|void|nothing|Value} + Value ::= true | false | null | notnull | canbenull + + If the method has a single input parameter, its name could be omitted.
+ Using halt (or void/nothing, which is the same) for the method output + means that the method doesn't return normally (throws or terminates the process).
+ Value canbenull is only applicable for output parameters.
+ You can use multiple [ContractAnnotation] for each FDT row, or use single attribute + with rows separated by the semicolon. There is no notion of order rows, all rows are checked + for applicability and applied per each program state tracked by the analysis engine.
+
+ + + [ContractAnnotation("=> halt")] + public void TerminationMethod() + + + [ContractAnnotation("null <= param:null")] // reverse condition syntax + public string GetName(string surname) + + + [ContractAnnotation("s:null => true")] + public bool IsNullOrEmpty(string s) // string.IsNullOrEmpty() + + + // A method that returns null if the parameter is null, + // and not null if the parameter is not null + [ContractAnnotation("null => null; notnull => notnull")] + public object Transform(object data) + + + [ContractAnnotation("=> true, result: notnull; => false, result: null")] + public bool TryParse(string s, out Person result) + + +
+ + + Indicates whether the marked element should be localized. + + + [LocalizationRequiredAttribute(true)] + class Foo { + string str = "my string"; // Warning: Localizable string + } + + + + + Indicates that the value of the marked type (or its derivatives) + cannot be compared using '==' or '!=' operators and Equals() + should be used instead. However, using '==' or '!=' for comparison + with null is always permitted. + + + [CannotApplyEqualityOperator] + class NoEquality { } + + class UsesNoEquality { + void Test() { + var ca1 = new NoEquality(); + var ca2 = new NoEquality(); + if (ca1 != null) { // OK + bool condition = ca1 == ca2; // Warning + } + } + } + + + + + When applied to a target attribute, specifies a requirement for any type marked + with the target attribute to implement or inherit specific type or types. + + + [BaseTypeRequired(typeof(IComponent)] // Specify requirement + class ComponentAttribute : Attribute { } + + [Component] // ComponentAttribute requires implementing IComponent interface + class MyComponent : IComponent { } + + + + + Indicates that the marked symbol is used implicitly (e.g. via reflection, in external library), + so this symbol will be ignored by usage-checking inspections.
+ You can use and + to configure how this attribute is applied. +
+ + [UsedImplicitly] + public class TypeConverter {} + + public class SummaryData + { + [UsedImplicitly(ImplicitUseKindFlags.InstantiatedWithFixedConstructorSignature)] + public SummaryData() {} + } + + [UsedImplicitly(ImplicitUseTargetFlags.WithInheritors | ImplicitUseTargetFlags.Default)] + public interface IService {} + +
+ + + Can be applied to attributes, type parameters, and parameters of a type assignable from . + When applied to an attribute, the decorated attribute behaves the same as . + When applied to a type parameter or to a parameter of type , + indicates that the corresponding type is used implicitly. + + + + + Specifies the details of implicitly used symbol when it is marked + with or . + + + + Only entity marked with attribute considered used. + + + Indicates implicit assignment to a member. + + + + Indicates implicit instantiation of a type with fixed constructor signature. + That means any unused constructor parameters won't be reported as such. + + + + Indicates implicit instantiation of a type. + + + + Specifies what is considered to be used implicitly when marked + with or . + + + + Members of the type marked with the attribute are considered used. + + + Inherited entities are considered used. + + + Entity marked with the attribute and all its members considered used. + + + + This attribute is intended to mark publicly available API, + which should not be removed and so is treated as used. + + + + + Tells the code analysis engine if the parameter is completely handled when the invoked method is on stack. + If the parameter is a delegate, indicates that delegate can only be invoked during method execution + (the delegate can be invoked zero or multiple times, but not stored to some field and invoked later, + when the containing method is no longer on the execution stack). + If the parameter is an enumerable, indicates that it is enumerated while the method is executed. + If is true, the attribute will only takes effect if the method invocation is located under the 'await' expression. + + + + + Require the method invocation to be used under the 'await' expression for this attribute to take effect on code analysis engine. + Can be used for delegate/enumerable parameters of 'async' methods. + + + + + Indicates that a method does not make any observable state changes. + The same as System.Diagnostics.Contracts.PureAttribute. + + + [Pure] int Multiply(int x, int y) => x * y; + + void M() { + Multiply(123, 42); // Warning: Return value of pure method is not used + } + + + + + Indicates that the return value of the method invocation must be used. + + + Methods decorated with this attribute (in contrast to pure methods) might change state, + but make no sense without using their return value.
+ Similarly to , this attribute + will help to detect usages of the method when the return value is not used. + Optionally, you can specify a message to use when showing warnings, e.g. + [MustUseReturnValue("Use the return value to...")]. +
+
+ + + This annotation allows to enforce allocation-less usage patterns of delegates for performance-critical APIs. + When this annotation is applied to the parameter of delegate type, IDE checks the input argument of this parameter: + * When lambda expression or anonymous method is passed as an argument, IDE verifies that the passed closure + has no captures of the containing local variables and the compiler is able to cache the delegate instance + to avoid heap allocations. Otherwise the warning is produced. + * IDE warns when method name or local function name is passed as an argument as this always results + in heap allocation of the delegate instance. + + + In C# 9.0 code IDE would also suggest to annotate the anonymous function with 'static' modifier + to make use of the similar analysis provided by the language/compiler. + + + + + Indicates the type member or parameter of some type, that should be used instead of all other ways + to get the value of that type. This annotation is useful when you have some "context" value evaluated + and stored somewhere, meaning that all other ways to get this value must be consolidated with existing one. + + + class Foo { + [ProvidesContext] IBarService _barService = ...; + + void ProcessNode(INode node) { + DoSomething(node, node.GetGlobalServices().Bar); + // ^ Warning: use value of '_barService' field + } + } + + + + + Indicates that a parameter is a path to a file or a folder within a web project. + Path can be relative or absolute, starting from web root (~). + + + + + An extension method marked with this attribute is processed by code completion + as a 'Source Template'. When the extension method is completed over some expression, its source code + is automatically expanded like a template at call site. + + + Template method body can contain valid source code and/or special comments starting with '$'. + Text inside these comments is added as source code when the template is applied. Template parameters + can be used either as additional method parameters or as identifiers wrapped in two '$' signs. + Use the attribute to specify macros for parameters. + + + In this example, the 'forEach' method is a source template available over all values + of enumerable types, producing ordinary C# 'foreach' statement and placing caret inside block: + + [SourceTemplate] + public static void forEach<T>(this IEnumerable<T> xs) { + foreach (var x in xs) { + //$ $END$ + } + } + + + + + + Allows specifying a macro for a parameter of a source template. + + + You can apply the attribute on the whole method or on any of its additional parameters. The macro expression + is defined in the property. When applied on a method, the target + template parameter is defined in the property. To apply the macro silently + for the parameter, set the property value = -1. + + + Applying the attribute on a source template method: + + [SourceTemplate, Macro(Target = "item", Expression = "suggestVariableName()")] + public static void forEach<T>(this IEnumerable<T> collection) { + foreach (var item in collection) { + //$ $END$ + } + } + + Applying the attribute on a template method parameter: + + [SourceTemplate] + public static void something(this Entity x, [Macro(Expression = "guid()", Editable = -1)] string newguid) { + /*$ var $x$Id = "$newguid$" + x.ToString(); + x.DoSomething($x$Id); */ + } + + + + + + Allows specifying a macro that will be executed for a source template + parameter when the template is expanded. + + + + + Allows specifying which occurrence of the target parameter becomes editable when the template is deployed. + + + If the target parameter is used several times in the template, only one occurrence becomes editable; + other occurrences are changed synchronously. To specify the zero-based index of the editable occurrence, + use values >= 0. To make the parameter non-editable when the template is expanded, use -1. + + + + + Identifies the target parameter of a source template if the + is applied on a template method. + + + + + Indicates how method, constructor invocation, or property access + over collection type affects the contents of the collection. + When applied to a return value of a method indicates if the returned collection + is created exclusively for the caller (CollectionAccessType.UpdatedContent) or + can be read/updated from outside (CollectionAccessType.Read | CollectionAccessType.UpdatedContent) + Use to specify the access type. + + + Using this attribute only makes sense if all collection methods are marked with this attribute. + + + public class MyStringCollection : List<string> + { + [CollectionAccess(CollectionAccessType.Read)] + public string GetFirstString() + { + return this.ElementAt(0); + } + } + class Test + { + public void Foo() + { + // Warning: Contents of the collection is never updated + var col = new MyStringCollection(); + string x = col.GetFirstString(); + } + } + + + + + Provides a value for the to define + how the collection method invocation affects the contents of the collection. + + + + Method does not use or modify content of the collection. + + + Method only reads content of the collection but does not modify it. + + + Method can change content of the collection but does not add new elements. + + + Method can add new elements to the collection. + + + + Indicates that the marked method is assertion method, i.e. it halts the control flow if + one of the conditions is satisfied. To set the condition, mark one of the parameters with + attribute. + + + + + Indicates the condition parameter of the assertion method. The method itself should be + marked by attribute. The mandatory argument of + the attribute is the assertion type. + + + + + Specifies assertion type. If the assertion method argument satisfies the condition, + then the execution continues. Otherwise, execution is assumed to be halted. + + + + Marked parameter should be evaluated to true. + + + Marked parameter should be evaluated to false. + + + Marked parameter should be evaluated to null value. + + + Marked parameter should be evaluated to not null value. + + + + Indicates that the marked method unconditionally terminates control flow execution. + For example, it could unconditionally throw exception. + + + + + Indicates that the method is a pure LINQ method, with postponed enumeration (like Enumerable.Select, + .Where). This annotation allows inference of [InstantHandle] annotation for parameters + of delegate type by analyzing LINQ method chains. + + + + + Indicates that IEnumerable passed as a parameter is not enumerated. + Use this annotation to suppress the 'Possible multiple enumeration of IEnumerable' inspection. + + + static void ThrowIfNull<T>([NoEnumeration] T v, string n) where T : class + { + // custom check for null but no enumeration + } + + void Foo(IEnumerable<string> values) + { + ThrowIfNull(values, nameof(values)); + var x = values.ToList(); // No warnings about multiple enumeration + } + + + + + Indicates that the marked parameter, field, or property is a regular expression pattern. + + + + + Language of injected code fragment inside marked by string literal. + + + + + Indicates that the marked parameter, field, or property is accepting a string literal + containing code fragment in a language specified by the . + + + void Foo([LanguageInjection(InjectedLanguage.CSS, Prefix = "body{", Suffix = "}")] string cssProps) + { + // cssProps should only contains a list of CSS properties + } + + + + Specify a language of injected code fragment. + + + Specify a string that "precedes" injected string literal. + + + Specify a string that "follows" injected string literal. + + + + Prevents the Member Reordering feature from tossing members of the marked class. + + + The attribute must be mentioned in your member reordering patterns. + + + + + Initializes a new instance of the class + with the specified member types. + + The types of members dynamically accessed. + + + + Gets the which specifies the type + of members dynamically accessed. + + + + + Specifies the types of members that are dynamically accessed. + + This enumeration has a attribute that allows a + bitwise combination of its member values. + + + + + Specifies no members. + + + + + Specifies the default, parameterless public constructor. + + + + + Specifies all public constructors. + + + + + Specifies all non-public constructors. + + + + + Specifies all public methods. + + + + + Specifies all non-public methods. + + + + + Specifies all public fields. + + + + + Specifies all non-public fields. + + + + + Specifies all public nested types. + + + + + Specifies all non-public nested types. + + + + + Specifies all public properties. + + + + + Specifies all non-public properties. + + + + + Specifies all public events. + + + + + Specifies all non-public events. + + + + + Specifies all interfaces implemented by the type. + + + + + Specifies all members. + + + + + Suppresses reporting of a specific rule violation, allowing multiple suppressions on a + single code artifact. + + + is different than + in that it doesn't have a + . So it is always preserved in the compiled assembly. + + + + + Initializes a new instance of the + class, specifying the category of the tool and the identifier for an analysis rule. + + The category for the attribute. + The identifier of the analysis rule the attribute applies to. + + + + Gets the category identifying the classification of the attribute. + + + The property describes the tool or tool analysis category + for which a message suppression attribute applies. + + + + + Gets the identifier of the analysis tool rule to be suppressed. + + + Concatenated together, the and + properties form a unique check identifier. + + + + + Gets or sets the scope of the code that is relevant for the attribute. + + + The Scope property is an optional argument that specifies the metadata scope for which + the attribute is relevant. + + + + + Gets or sets a fully qualified path that represents the target of the attribute. + + + The property is an optional argument identifying the analysis target + of the attribute. An example value is "System.IO.Stream.ctor():System.Void". + Because it is fully qualified, it can be long, particularly for targets such as parameters. + The analysis tool user interface should be capable of automatically formatting the parameter. + + + + + Gets or sets an optional argument expanding on exclusion criteria. + + + The property is an optional argument that specifies additional + exclusion where the literal metadata target is not sufficiently precise. For example, + the cannot be applied within a method, + and it may be desirable to suppress a violation against a statement in the method that will + give a rule violation, but not against all statements in the method. + + + + + Gets or sets the justification for suppressing the code analysis message. + + +
+
diff --git a/dev/libs/ControlzEx.dll b/dev/libs/netfx/ControlzEx.dll similarity index 100% rename from dev/libs/ControlzEx.dll rename to dev/libs/netfx/ControlzEx.dll diff --git a/dev/libs/FileFormatWavefront.XML b/dev/libs/netfx/FileFormatWavefront.XML similarity index 100% rename from dev/libs/FileFormatWavefront.XML rename to dev/libs/netfx/FileFormatWavefront.XML diff --git a/dev/libs/FileFormatWavefront.dll b/dev/libs/netfx/FileFormatWavefront.dll similarity index 100% rename from dev/libs/FileFormatWavefront.dll rename to dev/libs/netfx/FileFormatWavefront.dll diff --git a/dev/libs/Ifc.NET.XmlSerializers.dll b/dev/libs/netfx/Ifc.NET.XmlSerializers.dll similarity index 100% rename from dev/libs/Ifc.NET.XmlSerializers.dll rename to dev/libs/netfx/Ifc.NET.XmlSerializers.dll diff --git a/dev/libs/Ifc.NET.dll b/dev/libs/netfx/Ifc.NET.dll similarity index 100% rename from dev/libs/Ifc.NET.dll rename to dev/libs/netfx/Ifc.NET.dll diff --git a/dev/libs/Ifc.NET.resources.dll b/dev/libs/netfx/Ifc.NET.resources.dll similarity index 100% rename from dev/libs/Ifc.NET.resources.dll rename to dev/libs/netfx/Ifc.NET.resources.dll diff --git a/dev/libs/IxMilia.Dxf.dll b/dev/libs/netfx/IxMilia.Dxf.dll similarity index 100% rename from dev/libs/IxMilia.Dxf.dll rename to dev/libs/netfx/IxMilia.Dxf.dll diff --git a/dev/libs/IxMilia.Dxf.xml b/dev/libs/netfx/IxMilia.Dxf.xml similarity index 100% rename from dev/libs/IxMilia.Dxf.xml rename to dev/libs/netfx/IxMilia.Dxf.xml diff --git a/dev/libs/Microsoft.WindowsAPICodePack.Shell.dll b/dev/libs/netfx/Microsoft.WindowsAPICodePack.Shell.dll similarity index 100% rename from dev/libs/Microsoft.WindowsAPICodePack.Shell.dll rename to dev/libs/netfx/Microsoft.WindowsAPICodePack.Shell.dll diff --git a/dev/libs/Microsoft.WindowsAPICodePack.Shell.xml b/dev/libs/netfx/Microsoft.WindowsAPICodePack.Shell.xml similarity index 100% rename from dev/libs/Microsoft.WindowsAPICodePack.Shell.xml rename to dev/libs/netfx/Microsoft.WindowsAPICodePack.Shell.xml diff --git a/dev/libs/Microsoft.WindowsAPICodePack.dll b/dev/libs/netfx/Microsoft.WindowsAPICodePack.dll similarity index 100% rename from dev/libs/Microsoft.WindowsAPICodePack.dll rename to dev/libs/netfx/Microsoft.WindowsAPICodePack.dll diff --git a/dev/libs/Microsoft.WindowsAPICodePack.xml b/dev/libs/netfx/Microsoft.WindowsAPICodePack.xml similarity index 100% rename from dev/libs/Microsoft.WindowsAPICodePack.xml rename to dev/libs/netfx/Microsoft.WindowsAPICodePack.xml diff --git a/dev/libs/Microsoft.Xaml.Behaviors.dll b/dev/libs/netfx/Microsoft.Xaml.Behaviors.dll similarity index 100% rename from dev/libs/Microsoft.Xaml.Behaviors.dll rename to dev/libs/netfx/Microsoft.Xaml.Behaviors.dll diff --git a/dev/libs/netfx/PythonStubsBuilder.dll b/dev/libs/netfx/PythonStubsBuilder.dll new file mode 100644 index 000000000..11c898660 Binary files /dev/null and b/dev/libs/netfx/PythonStubsBuilder.dll differ diff --git a/dev/libs/Rhino3dmIO.dll b/dev/libs/netfx/Rhino3dmIO.dll similarity index 100% rename from dev/libs/Rhino3dmIO.dll rename to dev/libs/netfx/Rhino3dmIO.dll diff --git a/dev/libs/pyRevitLabs.Json.dll b/dev/libs/netfx/pyRevitLabs.Json.dll similarity index 100% rename from dev/libs/pyRevitLabs.Json.dll rename to dev/libs/netfx/pyRevitLabs.Json.dll diff --git a/dev/libs/pyRevitLabs.Json.xml b/dev/libs/netfx/pyRevitLabs.Json.xml similarity index 100% rename from dev/libs/pyRevitLabs.Json.xml rename to dev/libs/netfx/pyRevitLabs.Json.xml diff --git a/dev/libs/pyRevitLabs.MahAppsMetro.dll b/dev/libs/netfx/pyRevitLabs.MahAppsMetro.dll similarity index 91% rename from dev/libs/pyRevitLabs.MahAppsMetro.dll rename to dev/libs/netfx/pyRevitLabs.MahAppsMetro.dll index 23b9dfbe4..3cfa6ebbd 100644 Binary files a/dev/libs/pyRevitLabs.MahAppsMetro.dll and b/dev/libs/netfx/pyRevitLabs.MahAppsMetro.dll differ diff --git a/dev/libs/netfx/pyRevitLabs.MahAppsMetro.xml b/dev/libs/netfx/pyRevitLabs.MahAppsMetro.xml new file mode 100644 index 000000000..363f66bc5 --- /dev/null +++ b/dev/libs/netfx/pyRevitLabs.MahAppsMetro.xml @@ -0,0 +1,9707 @@ + + + + pyRevitLabs.MahAppsMetro + + + + + Switch to force accessibility to only use features compatible with .NET 472 + When true, all accessibility features are compatible with .NET 472 + When false, accessibility features added in .NET versions greater than 472 can be enabled. + + + + + This CommandTriggerAction can be used to bind any event on any FrameworkElement to an . + This trigger can only be attached to a FrameworkElement or a class deriving from FrameworkElement. + + This class is inspired from Laurent Bugnion and his EventToCommand. + http://www.mvvmlight.net + See license.txt in this solution or http://www.galasoft.ch/license_MIT.txt + + + + + Identifies the dependency property + + + + + Gets or sets the command that this trigger is bound to. + + + + + Identifies the dependency property + + + + + Gets or sets an object that will be passed to the attached to this trigger. + + + + + The MetroHeaderAutomationPeer class exposes the type to UI Automation. + + + + + The MetroThumbContentControlAutomationPeer class exposes the type to UI Automation. + + + + Initializes a new instance of the class. + The associated with this . + + + + + + + + + + + + + + + + + + + + + + + + + Gets or sets the bindable Password property on the PasswordBox control. This is a dependency property. + + + + + Handles changes to the 'Password' attached property. + + + + + Handle the 'PasswordChanged'-event on the PasswordBox + + + + + Called after the behavior is attached to an AssociatedObject. + + + Override this to hook up functionality to the AssociatedObject. + + + + + Called when the behavior is being detached from its AssociatedObject, but before it has actually occurred. + + + Override this to unhook functionality from the AssociatedObject. + + + + + The DependencyProperty for the ' OnDataContextChanged property. + + With the OnDataContextChanged property the Reload behavior of the MetroContentControl can be switched on or off. + If the property is set to true, the transition of the is triggered again when the DataContext is changed. + + + + + Helper for getting from . + + If the property is set to true, the transition of the is triggered again when the DataContext is changed. + + to read from. + OnDataContextChanged property value. + + + + Helper for setting on . + + If the property is set to true, the transition of the is triggered again when the DataContext is changed. + + to set on. + OnDataContextChanged property value. + + + + The DependencyProperty for the ' and ' OnSelectedTabChanged property. + + With the OnSelectedTabChanged property the Reload behavior of the control can be switched on or off. + If the property is set to true, the transition is triggered again when the SelectionChanged event of a TabControl was raised. + + + + + Helper for getting from . + + If the property is set to true, the transition is triggered again when the SelectionChanged event of a TabControl was raised. + + to read from. + OnSelectedTabChanged property value. + + + + Helper for setting on . + + If the property is set to true, the transition is triggered again when the SelectionChanged event of a TabControl was raised. + + to set on. + OnSelectedTabChanged property value. + + + + + Sets the first TabItem with Visibility="" as + the SelectedItem of the TabControl. + + + If there is no visible TabItem, null is set as the SelectedItem + + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + + + + + + Identifies the dependency property. + + + + Represents a border whose contents are clipped within the bounds + of the border. The border may have rounded corners. + + + + + BorderThickness Dependency Property + + + + + Gets or sets the BorderThickness property. This dependency property + indicates the BorderThickness. + + + + + Checks if the given Thickness is valid or not + + Thickness + + + + + Padding Dependency Property + + + + + Gets or sets the Padding property. This dependency property + indicates the Padding. + + + + + CornerRadius Dependency Property + + + + + Gets or sets the CornerRadius property. This dependency property + indicates the CornerRadius of the border. + + + + + Checks if the given CornerRadius is valid or not + + CornerRadius + + + + + BorderBrush Dependency Property + + + + + Gets or sets the BorderBrush property. This dependency property + indicates the BorderBrush with which the Border is drawn. + + + + + Background Dependency Property + + + + + Gets or sets the Background property. This dependency property + indicates the Background with which the Background is drawn. + + + + + OptimizeClipRendering Dependency Property + + + + + Gets or sets the OptimizeClipRendering property. This dependency property + indicates whether the rendering of the clip should be optimized. When set to true, + In order to optimize the rendering of the clipped Child, + the background is rendered with the same brush as the border. Any other brush set for + the background will be ignored. The Child will be rendered on top of it. + This is done to prevent any gaps between the border the the clipped Child (this is + evidently visible if both the Border and the Child are of same color). + This works best when the Child does not have any level of transparency and is opaque. + + + + + Updates DesiredSize of the ClipBorder. Called by parent UIElement. This is the first pass of layout. + + + Border determines its desired size it needs from the specified border the child: its sizing + properties, margin, and requested size. + + Constraint size is an "upper limit" that the return value should not exceed. + The Decorator's desired size. + + + + ClipBorder computes the position of its single child and applies its child's alignments to the child. + + + The size reserved for this element by the parent + The actual ink area of the element, typically the same as finalSize + + + + Here the ClipBorder's Child, Border and Background are rendered. + + Drawing Context + + + + Generates a StreamGeometry. + + An already opened StreamGeometryContext. + Rectangle for geomentry conversion. + The core points of the border which needs to be used to create + the geometry + Result geometry. + + + + Encapsulates the details of each of the core points of the border which is calculated + based on the given CornerRadius, BorderThickness, Padding and a flag to indicate whether + the inner or outer border is to be calculated. + + CornerRadius + BorderThickness + Padding + Flag to indicate whether outer or inner border needs + to be calculated + + + + A few very useful extension methods + + + + + Returns whether or not two doubles are "close". + + The first double to compare. + The second double to compare. + + bool - the result of the AreClose comparision. + + + + + Returns whether or not the first double is less than the second double. + + The first double to compare. + The second double to compare. + + bool - the result of the LessThan comparision. + + + + + Returns whether or not the first double is greater than the second double. + + The first double to compare. + The second double to compare. + + bool - the result of the GreaterThan comparision. + + + + + Returns whether or not the double is "close" to 1. Same as AreClose(double, 1), + but this is faster. + + The double to compare to 1. + + bool - the result of the AreClose comparision. + + + + + IsZero - Returns whether or not the double is "close" to 0. Same as AreClose(double, 0), + but this is faster. + + The double to compare to 0. + + bool - the result of the AreClose comparision. + + + + + Compares two points for fuzzy equality. This function + helps compensate for the fact that double values can + acquire error when operated upon + + The first point to compare + The second point to compare + Whether or not the two points are equal + + + + Compares two Size instances for fuzzy equality. This function + helps compensate for the fact that double values can + acquire error when operated upon + + The first size to compare + The second size to compare + Whether or not the two Size instances are equal + + + + Compares two Vector instances for fuzzy equality. This function + helps compensate for the fact that double values can + acquire error when operated upon + + The first Vector to compare + The second Vector to compare + Whether or not the two Vector instances are equal + + + + Compares two rectangles for fuzzy equality. This function + helps compensate for the fact that double values can + acquire error when operated upon + + The first rectangle to compare + The second rectangle to compare + Whether or not the two rectangles are equal + + + + Faster check for NaN ( faster than double.IsNaN() ) + IEEE 754 : If the argument is any value in the range 0x7ff0000000000001L through 0x7fffffffffffffffL + or in the range 0xfff0000000000001L through 0xffffffffffffffffL, the result will be NaN. + + Value to check + + + + + Rounds the given value based on the DPI scale + + Value to round + DPI Scale + + + + + Verifies if this Thickness contains only valid values + The set of validity checks is passed as parameters. + + Thickness value + allows negative values + allows Double.NaN + allows Double.PositiveInfinity + allows Double.NegativeInfinity + Whether or not the thickness complies to the range specified + + + + Method to add up the left and right size as width, as well as the top and bottom size as height + + Thickness + Size + + + + Verifies if the Thickness contains only zero values + + Thickness + Size + + + + Verifies if all the values in Thickness are same + + Thickness + true if yes, otherwise false + + + + Verifies if this CornerRadius contains only valid values + The set of validity checks is passed as parameters. + + CornerRadius value + allows negative values + allows Double.NaN + allows Double.PositiveInfinity + allows Double.NegativeInfinity + Whether or not the CornerRadius complies to the range specified + + + + Verifies if the CornerRadius contains only zero values + + CornerRadius + Size + + + + Verifies if the CornerRadius contains same values + + CornerRadius + true if yes, otherwise false + + + + Deflates rectangle by given thickness + + Rectangle + Thickness + Deflated Rectangle + + + + Inflates rectangle by given thickness + + Rectangle + Thickness + Inflated Rectangle + + + + Verifies if the given brush is a SolidColorBrush and + its color does not include transparency. + + Brush + true if yes, otherwise false + + + + Verifies if the given brush is the same as the otherBrush. + + Brush + Brush + true if yes, otherwise false + + + Helper for getting from . + to read from. + MaximumRecentColorsCount property value. + + + Helper for setting on . + to set on. + MaximumRecentColorsCount property value. + + + Identifies the dependency property. + + + + Gets or sets the selected . + + + + Identifies the dependency property. + + + + Gets or sets the number of additional pixel in the preview image. + + + + Identifies the dependency property. + + + + Gets or sets the Cursor for Selecting Color Mode + + + + Identifies the dependency property. + + + + Gets or sets the ContentControl.ContentTemplate for the preview. + + + + Identifies the routed event. + + + + Occurs when the property is changed. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets the preview image while the cursor is moving + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets the preview brush while the cursor is moving + + + + + A Helper class for the Color-Struct + + + + + This function tries to convert a given string into a Color in the following order: + 1. If the string starts with '#' the function tries to get the color from the hex-code + 2. else the function tries to find the color in the color names Dictionary + 3. If 1. + 2. were not successful the function adds a '#' sign and tries 1. + 2. again + + The localized name of the color, the hex-code of the color or the internal color name + Optional: The dictionary where the ColorName should be looked up + the Color if successful, else null + + + + This function tries to convert a given string into a Color in the following order: + 1. If the string starts with '#' the function tries to get the color from the hex-code + 2. else the function tries to find the color in the default + 3. If 1. + 2. were not successful the function adds a '#' sign and tries 1. + 2. again + + The localized name of the color, the hex-code of the color or the internal color name + the Color if successful, else null + + + + A Dictionary with localized Color Names + + + + + Searches for the localized name of a given + + color + Optional: The dictionary where the ColorName should be looked up + the local color name or null if the given color doesn't have a name + + + + Searches for the localized name of a given by using the default + + color + the local color name or null if the given color doesn't have a name + + + Identifies the dependency property. + + + + Gets or sets the Header of this Control + + + + Identifies the dependency property. + + + + Gets or sets the HeaderTemplate of this Control + + + + Identifies the dependency property. + + + + Gets or sets a custom dictionary for color to name. If null, the default dictionary will be used. + + + + Identifies the routed event. + + + + Occurs when the DropDown is closed. + + + + Identifies the routed event. + + + + Occurs when the DropDown is opened. + + + + Identifies the dependency property. + + + + Gets or sets the height of the DropDown. + + + + Identifies the dependency property. + + + + Gets or sets the width of the DropDown. + + + + Identifies the dependency property. + + + + Whether or not the "popup" for this control is currently open + + + + Identifies the dependency property. + + + + Gets or sets the for the + + + + Identifies the dependency property. + + + + Gets or sets when to add the to the + + + + Identifies the dependency property. + + + + Gets or sets the visibility of the available . + + + + Identifies the dependency property. + + + + Gets or sets the of the available . + + + + Identifies the dependency property. + + + + Gets or sets the of the available . + + + + Identifies the dependency property. + + + + Gets or sets the of the available . + + + + Identifies the dependency property. + + + + Gets or sets the of the available . + + + + Identifies the dependency property. + + + + Gets or sets the visibility of the custom (1/2). + + + + Identifies the dependency property. + + + + Gets or sets the of the custom (1/2). + + + + Identifies the dependency property. + + + + Gets or sets the of the custom (1/2). + + + + Identifies the dependency property. + + + + Gets or sets the of the custom (1/2). + + + + Identifies the dependency property. + + + + Gets or sets the of the custom (1/2). + + + + Identifies the dependency property. + + + + Gets or sets the visibility of the custom (2/2). + + + + Identifies the dependency property. + + + + Gets or sets the of the custom (2/2). + + + + Identifies the dependency property. + + + + Gets or sets the of the custom (2/2). + + + + Identifies the dependency property. + + + + Gets or sets the of the custom (2/2). + + + + Identifies the dependency property. + + + + Gets or sets the of the custom (2/2). + + + + Identifies the dependency property. + + + + Gets or sets the visibility of the recent . + + + + Identifies the dependency property. + + + + Gets or sets the of the recent . + + + + Identifies the dependency property. + + + + Gets or sets the of the recent . + + + + Identifies the dependency property. + + + + Gets or sets the of the recent . + + + + Identifies the dependency property. + + + + Gets or sets the of the recent . + + + + Identifies the dependency property. + + + + Gets or sets the visibility of the standard . + + + + Identifies the dependency property. + + + + Gets or sets the of the standard . + + + + Identifies the dependency property. + + + + Gets or sets the of the standard . + + + + Identifies the dependency property. + + + + Gets or sets the of the standard . + + + + Identifies the dependency property. + + + + Gets or sets the of the standard . + + + + Identifies the dependency property. + + + + Gets or sets the for the . + + + + Identifies the dependency property. + + + + Gets or sets the for the + + + + Identifies the dependency property. + + + + Gets or sets the for the . + + + + Identifies the dependency property. + + + + Gets or sets the for the . + + + + Identifies the dependency property. + + + + Gets or sets the visibility of the . + + + + Identifies the dependency property. + + + + Gets or sets the for the . + + + + Identifies the dependency property. + + + + Gets or sets the for the . + + + + Identifies the dependency property. + + + + Gets or sets the visibility of the . + + + + Identifies the dependency property. + + + + Gets or sets the selected . + + + + Identifies the dependency property. + + + + Gets or sets a default selected + + + + Identifies the dependency property. + + + + Gets the as . This property is read only. + + + + Identifies the dependency property. + + + + Gets or sets the name of the . + + + + Identifies the dependency property. + + + + Gets or sets a for looking up the + + + + Identifies the dependency property. + + + + Gets or sets the Alpha-Channel + + + + Identifies the dependency property. + + + + Gets or sets the Red-Channel + + + + Identifies the dependency property. + + + + Gets or sets the Green-Channel + + + + Identifies the dependency property. + + + + Gets or sets the Blue-Channel + + + + Identifies the dependency property. + + + + Gets or sets the Hue-Channel + + + + Identifies the dependency property. + + + + Gets or sets the Saturation-Channel + + + + Identifies the dependency property. + + + + Gets or sets the Value-Channel + + + + Identifies the dependency property. + + + + Gets or sets the label for the Alpha-Channel in the UI + + + + Identifies the dependency property. + + + + Gets or sets the label for the Red-Channel in the UI + + + + Identifies the dependency property. + + + + Gets or sets the label for the Green-Channel in the UI + + + + Identifies the dependency property. + + + + Gets or sets the label for the Blue-Channel in the UI + + + + Identifies the dependency property. + + + + Gets or sets the label for the Preview in the UI + + + + Identifies the dependency property. + + + + Gets or sets the label for the Hue-Channel in the UI + + + + Identifies the dependency property. + + + + Gets or sets the label for the Saturation-Channel in the UI + + + + Identifies the dependency property. + + + + Gets or sets the label for the Value-Channel in the UI + + + + Identifies the dependency property. + + + + Gets or sets the label for the in the UI + + + + Identifies the routed event. + + + + Occurs when the property is changed. + + + + + This struct represent a Color in HSV (Hue, Saturation, Value) + + For more information visit: https://en.wikipedia.org/wiki/HSL_and_HSV + + + + + Gets the Alpha channel. + + + + + Gets the Hue channel. + + + + + Gets the Saturation channel + + + + + Gets the Value channel + + + + + Creates a new HSV Color from a given + + The to convert + + + + Creates a new HSV Color + + channel [0;360] + channel [0;1] + channel [0;1] + + + + Creates a new HSV Color + + (Alpha) channel [0;1] + channel [0;360] + channel [0;1] + channel [0;1] + + + + Gets the for this HSV Color struct + + + + + Identifies the dependency property. + + + + Gets or sets the character casing of the Content. + + + + Identifies the dependency property. + + + + Determine if the inner ContentPresenter should use AccessText in its style + + + + + This custom popup is used by the validation error template. + It provides some additional nice features: + - repositioning if host-window size or location changed + - repositioning if host-window gets maximized and vice versa + - it's only topmost if the host-window is activated + + + + Identifies the dependency property. + + + + Gets or sets whether if the popup can be closed by left mouse button down. + + + + Identifies the dependency property. + + + + Gets or sets whether the validation error text will be shown when hovering the validation triangle. + + + + Identifies the dependency property. + + + + Gets or sets the that this object is reserving space for. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets whether the popup can be shown (useful for transitions). + + + + + Called when a cell has just switched to edit mode. + + A reference to element returned by GenerateEditingElement. + The event args of the input event that caused the cell to go into edit mode. May be null. + The unedited value of the cell. + + + + Synchronizes the column property. Taken from Helper code for DataGrid. + + + + + Taken from Helper code for DataGrid. + + + + Identifies the dependency property. + + + + Gets or sets the formatting for the displaying value. + + + + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets or sets the decimal-point correction mode. The default is + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + The font family of the desired font. + + + + Identifies the dependency property. + + + + The size of the desired font. + + + + Identifies the dependency property. + + + + The style of the desired font. + + + + Identifies the dependency property. + + + + The weight or thickness of the desired font. + + + + Identifies the dependency property. + + + + An brush that describes the foreground color. This overrides the cell foreground inherited color. + + + + + Method used as property changed callback for properties which need RefreshCellContent to be called + + + + + Rebuilds the contents of a cell in the column in response to a binding change. + + The cell to update. + The name of the column property that has changed. + + + + (Default) No correction is applied, and any style + inherited setting may influence the correction behavior. + + + + + Enable the decimal-point correction for generic numbers. + + + + + Enable the decimal-point correction for currency numbers. + + + + + Enable the decimal-point correction for percent-numbers. + + + + + The base class for dialogs. + + You probably don't want to use this class, if you want to add arbitrary content to your dialog, + use the class. + + + + Identifies the dependency property. + + + + Gets or sets the left and right margin for the dialog content. + + + + Identifies the dependency property. + + + + Gets or sets the width for the dialog content. + + + + Identifies the dependency property. + + + + Gets or sets the title of the dialog. + + + + Identifies the dependency property. + + + + Gets or sets the content above the dialog. + + + + Identifies the dependency property. + + + + Gets or sets the content below the dialog. + + + + Identifies the dependency property. + + + + Gets or sets the font size of the dialog title. + + + + Identifies the dependency property. + + + + Gets or sets the font size of the dialog message text. + + + + Identifies the dependency property. + + + + Gets or sets the font size of any dialog buttons. + + + + + Initializes a new . + + The window that is the parent of the dialog. + The settings for the message dialog. + + + + Initializes a new . + + + + + + + + With this method it's possible to return your own settings in a custom dialog. + + + + + + + This is called in the loaded event. + + + + + Waits for the dialog to become ready for interaction. + + A task that represents the operation and it's status. + + + + Requests an externally shown Dialog to close. Will throw an exception if the Dialog is inside of a MetroWindow. + + + + + A last chance virtual method for stopping an external dialog from closing. + + + + + + Gets the window that owns the current Dialog IF AND ONLY IF the dialog is shown externally. + + + + + Gets the window that owns the current Dialog IF AND ONLY IF the dialog is shown inside of a window. + + + + + Waits until this dialog gets unloaded. + + + + + + An implementation of BaseMetroDialog allowing arbitrary content. + + + + + Gets the default instance if the dialog coordinator, which can be injected into a view model. + + + + + Creates a LoginDialog inside of the current window. + + The window that is the parent of the dialog. + The title of the LoginDialog. + The message contained within the LoginDialog. + Optional settings that override the global metro dialog settings. + The text that was entered or null (Nothing in Visual Basic) if the user cancelled the operation. + + + + Creates a InputDialog inside of the current window. + + The MetroWindow + The title of the MessageDialog. + The message contained within the MessageDialog. + Optional settings that override the global metro dialog settings. + The text that was entered or null (Nothing in Visual Basic) if the user cancelled the operation. + + + + Creates a MessageDialog inside of the current window. + + The MetroWindow + The title of the MessageDialog. + The message contained within the MessageDialog. + The type of buttons to use. + Optional settings that override the global metro dialog settings. + A task promising the result of which button was pressed. + + + + Creates a ProgressDialog inside of the current window. + + The MetroWindow + The title of the ProgressDialog. + The message within the ProgressDialog. + Determines if the cancel button is visible. + Optional Settings that override the global metro dialog settings. + A task promising the instance of ProgressDialogController for this operation. + + + + Adds a Metro Dialog instance to the specified window and makes it visible asynchronously. + If you want to wait until the user has closed the dialog, use + You have to close the resulting dialog yourself with . + + The owning window of the dialog. + The dialog instance itself. + An optional pre-defined settings instance. + A task representing the operation. + The is already visible in the window. + + + + Adds a Metro Dialog instance of the given type to the specified window and makes it visible asynchronously. + If you want to wait until the user has closed the dialog, use + You have to close the resulting dialog yourself with . + + The owning window of the dialog. + An optional pre-defined settings instance. + A task with the dialog representing the operation. + + + + Hides a visible Metro Dialog instance. + + The window with the dialog that is visible. + The dialog instance to hide. + An optional pre-defined settings instance. + A task representing the operation. + + The is not visible in the window. + This happens if hasn't been called before. + + + + + Gets the current shown dialog in async way. + + The dialog owner. + + + + Create and show an external dialog. + + The dialog which will be shown externally. + The owner for the external window. If it's null the main window will be use. + The delegate for customizing dialog window. It can be null. + The given dialog. + + + + Create and show an external modal dialog. + + The dialog which will be shown externally. + The owner for the external window. If it's null the main window will be use. + The delegate for customizing dialog window. It can be null. + The given dialog. + + + + Creates a LoginDialog outside of the current window. + + The window that is the parent of the dialog. + The title of the LoginDialog. + The message contained within the LoginDialog. + Optional settings that override the global metro dialog settings. + The text that was entered or null (Nothing in Visual Basic) if the user cancelled the operation. + + + + Creates a InputDialog outside of the current window. + + The MetroWindow + The title of the MessageDialog. + The message contained within the MessageDialog. + Optional settings that override the global metro dialog settings. + The text that was entered or null (Nothing in Visual Basic) if the user cancelled the operation. + + + + Creates a MessageDialog ouside of the current window. + + The MetroWindow + The title of the MessageDialog. + The message contained within the MessageDialog. + The type of buttons to use. + Optional settings that override the global metro dialog settings. + A task promising the result of which button was pressed. + + + + Use the dialog coordinator to help you interfact with dialogs from a view model. + + + + + Shows the input dialog. + + Typically this should be the view model, which you register in XAML using . + The title of the MessageDialog. + The message contained within the MessageDialog. + Optional settings that override the global metro dialog settings. + The text that was entered or null (Nothing in Visual Basic) if the user cancelled the operation. + + + + Shows the input dialog. + + Typically this should be the view model, which you register in XAML using . + The title of the MessageDialog. + The message contained within the MessageDialog. + Optional settings that override the global metro dialog settings. + The text that was entered or null (Nothing in Visual Basic) if the user cancelled the operation. + + + + Creates a LoginDialog inside of the current window. + + Typically this should be the view model, which you register in XAML using . + The title of the LoginDialog. + The message contained within the LoginDialog. + Optional settings that override the global metro dialog settings. + The text that was entered or null (Nothing in Visual Basic) if the user cancelled the operation. + + + + Creates a LoginDialog outside of the current window. + + Typically this should be the view model, which you register in XAML using . + The title of the LoginDialog. + The message contained within the LoginDialog. + Optional settings that override the global metro dialog settings. + The text that was entered or null (Nothing in Visual Basic) if the user cancelled the operation. + + + + Creates a MessageDialog inside of the current window. + + Typically this should be the view model, which you register in XAML using . + The title of the MessageDialog. + The message contained within the MessageDialog. + The type of buttons to use. + Optional settings that override the global metro dialog settings. + A task promising the result of which button was pressed. + + + + Creates a MessageDialog outside of the current window. + + Typically this should be the view model, which you register in XAML using . + The title of the MessageDialog. + The message contained within the MessageDialog. + The type of buttons to use. + Optional settings that override the global metro dialog settings. + A task promising the result of which button was pressed. + + + + Creates a ProgressDialog inside of the current window. + + Typically this should be the view model, which you register in XAML using . + The title of the ProgressDialog. + The message within the ProgressDialog. + Determines if the cancel button is visible. + Optional Settings that override the global metro dialog settings. + A task promising the instance of ProgressDialogController for this operation. + + + + Adds a Metro Dialog instance to the specified window and makes it visible asynchronously. + You have to close the resulting dialog yourself with . + + Typically this should be the view model, which you register in XAML using . + The dialog instance itself. + An optional pre-defined settings instance. + A task representing the operation. + The is already visible in the window. + + + + Hides a visible Metro Dialog instance. + + Typically this should be the view model, which you register in XAML using . + The dialog instance to hide. + An optional pre-defined settings instance. + A task representing the operation. + + The is not visible in the window. + This happens if hasn't been called before. + + + + + Gets the current shown dialog. + + Typically this should be the view model, which you register in XAML using . + + + + InputDialog + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + InitializeComponent + + + + + LoginDialog + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + InitializeComponent + + + + + An internal control that represents a message dialog. Please use MetroWindow.ShowMessage instead! + + + MessageDialog + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + InitializeComponent + + + + + An enum representing the result of a Message Dialog. + + + + + An enum representing the different button states for a Message Dialog. + + + + + Just "OK" + + + + + "OK" and "Cancel" + + + + + An enum representing the different choices for a color scheme in a Metro Dialog. + + + + + A class that represents the settings used by Metro Dialogs. + + + + + Gets or sets wheater the owner of the dialog can be closed. + + + + + Gets or sets the text used for the Affirmative button. For example: "OK" or "Yes". + + + + + Enable or disable dialog hiding animation + "True" - play hiding animation. + "False" - skip hiding animation. + + + + + Enable or disable dialog showing animation. + "True" - play showing animation. + "False" - skip showing animation. + + + + + Gets or sets a token to cancel the dialog. + + + + + Gets or sets whether the metro dialog should use the default black/white appearance (theme) or try to use the current accent. + + + + + Gets or sets a custom resource dictionary which can contains custom styles, brushes or something else. + + + + + Gets or sets which button should be focused by default + + + + + Gets or sets the default text (just the inputdialog needed) + + + + + Gets or sets the size of the dialog message font. + + + The size of the dialog message font. + + + + + Gets or sets the size of the dialog button font. + + + The size of the dialog button font. + + + + + Gets or sets the dialog result when the user cancelled the dialog with 'ESC' key + + If the value is the default behavior is determined + by the . + + + + +
+ + + + +
+
+ + + Gets or sets the size of the dialog title font. + + + The size of the dialog title font. + + + + + Gets or sets the text used for the first auxiliary button. + + + + + Gets or sets the maximum height. (Default is unlimited height, Double.NaN) + + + + + Gets or sets the text used for the Negative button. For example: "Cancel" or "No". + + + + + Gets or sets the text used for the second auxiliary button. + + + + + An internal control that represents a message dialog. Please use MetroWindow.ShowMessage instead! + + + ProgressDialog + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + InitializeComponent + + + + + A class for manipulating an open ProgressDialog. + + + + + This event is raised when the associated was closed programmatically. + + + + + This event is raised when the associated was cancelled by the user. + + + + + Gets if the Cancel button has been pressed. + + + + + Gets if the wrapped ProgressDialog is open. + + + + + Sets the ProgressBar's IsIndeterminate to true. To set it to false, call SetProgress. + + + + + Sets if the Cancel button is visible. + + + + + + Sets the dialog's progress bar value and sets IsIndeterminate to false. + + The percentage to set as the value. + + + + Gets/Sets the minimum restriction of the progress Value property. + + + + + Gets/Sets the maximum restriction of the progress Value property. + + + + + Sets the dialog's message content. + + The message to be set. + + + + Sets the dialog's title. + + The title to be set. + + + + Sets the dialog's progress bar brush. + + The brush to use for the progress bar's foreground. + + + + Begins an operation to close the ProgressDialog. + + A task representing the operation. + + + Identifies the dependency property. + + + + Whether or not the "popup" menu for this control is currently open + + + + Identifies the dependency property. + + + + Gets or sets an extra tag. + + + + Identifies the dependency property. + + + + Gets or sets the orientation of children stacking. + + + + Identifies the dependency property. + + + + Gets or sets the content for the icon part. + + + + Identifies the dependency property. + + + + Gets or sets the DataTemplate for the icon part. + + + + Identifies the dependency property. + + + + Gets or sets the command to invoke when the content button is pressed. + + + + Identifies the dependency property. + + + + Gets or sets the element on which to raise the specified command. + + + + Identifies the dependency property. + + + + Gets or sets the parameter to pass to the command property. + + + + Identifies the dependency property. + + + + Gets or sets the content of this control. + + + + Identifies the dependency property. + + + + Gets or sets the data template used to display the content of the DropDownButton. + + + + Identifies the dependency property. + + + + Gets or sets a template selector that enables an application writer to provide custom template-selection logic. + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the content property if it is displayed as a string. + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + + Gets or sets the button content style. + + + + Identifies the dependency property. + + + + Gets or sets the "popup" menu style. + + + + Identifies the dependency property. + + + + Gets or sets the foreground brush for the button arrow icon. + + + + Identifies the dependency property. + + + + Gets or sets the foreground brush of the button arrow icon if the mouse is over the drop down button. + + + + Identifies the dependency property. + + + + Gets or sets the foreground brush of the button arrow icon if the arrow button is pressed. + + + + Identifies the dependency property. + + + + Gets or sets the visibility of the button arrow icon. + + + + + + + + + + Invoked when the property changes. + Information about the change. + + + + Executes the specified action asynchronously with the DispatcherPriority.Background on the thread that the Dispatcher was created on. + + The dispatcher object where the action runs. + An action that takes no parameters. + The dispatcher priority. + + + + Executes the specified action if the element is loaded or at the loaded event if it's not loaded. + + The element where the action should be run. + An action that takes no parameters. + + + + A control that imitate a slide show with back/forward buttons. + + + + Identifies the dependency property. + + + + Gets or sets the border brush of the mouse hover effect. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the border for mouse over effect is enabled or not. + + + + Identifies the dependency property. + + + + Gets or sets the border thickness for the border of the mouse hover effect. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the navigation index should be visible. + + + + Identifies the dependency property. + + + + Gets or sets a style for the navigation index items. + + + + Identifies the dependency property. + + + + Gets or sets a value specifying where the navigation index should be rendered. + + + + + Gets or sets the horizontal alignment characteristics applied to the navigation index. + + + + + Gets or sets the vertical alignment characteristics applied to the navigation index. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the navigation is circular, so you get the first after last and the last before first. + + + + Identifies the dependency property. + + + + Gets or sets the position of the navigation buttons. + + + + Identifies the dependency property. + + + + Gets or sets the orientation of the navigation. + + + + Identifies the dependency property. + + + + Gets or sets the transition of the left navigation. + + + + Identifies the dependency property. + + + + Gets or sets the transition of the right navigation. + + + + Identifies the dependency property. + + + + Gets or sets the transition of the up navigation. + + + + Identifies the dependency property. + + + + Gets or sets the transition of the down navigation. + + + + Identifies the dependency property. + + + + Gets or sets whether the banner is visible or not. + + + + Identifies the dependency property. + + + + Gets or sets whether the navigation button are visible or not. + + + + Identifies the dependency property. + + + + Gets or sets the banner text. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets or sets the DataTemplate used to display the banner's content. + + + + Identifies the dependency property. + + + + Gets or sets a template selector for BannerText property that enables an application writer to provide custom template-selection logic . + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the BannerText property if it is displayed as a string. + + + This property is ignored if is set. + + + + + Gets or sets a that is used to fill the banner. + + + + Identifies the dependency property. + + + + Gets or sets a that describes the foreground color of the banner label. + + + + Identifies the dependency property. + + + + Gets or sets the opacity factor applied to the entire banner when it is rendered in the user interface (UI). + + + + Identifies the dependency property. + + + + Gets or sets the for the navigation buttons. + + + + Identifies the dependency property. + + + + Provides the object content that should be displayed on the Back Button. + + + + Identifies the dependency property. + + + + Gets or sets the DataTemplate used to display the Back button's content. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the ButtonBackContent property if it is displayed as a string. + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + + Provides the object content that should be displayed on the Forward Button. + + + + Identifies the dependency property. + + + + Gets or sets the DataTemplate used to display the Forward button's content. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the ButtonForwardContent property if it is displayed as a string. + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + + Provides the object content that should be displayed on the Up Button. + + + + Identifies the dependency property. + + + + Gets or sets the DataTemplate used to display the Up button's content. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the ButtonUpContent property if it is displayed as a string. + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + + Provides the object content that should be displayed on the Down Button. + + + + Identifies the dependency property. + + + + Gets or sets the DataTemplate used to display the Down button's content. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the ButtonDownContent property if it is displayed as a string. + + + This property is ignored if is set. + + + + + To counteract the double Loaded event issue. + + + + + Coerce SelectedIndexProperty's value. + + The object that the property exists on. + The new value of the property, prior to any coercion attempt. + The coerced value (with appropriate type). + + + + Changes the current slide to the previous item. + + + + + Changes the current to the next item. + + + + + Brings the control buttons (next/previous) into view. + + + + + Removes the control buttons (next/previous) from view. + + + + + Applies actions to navigation buttons. + + Action applied to the previous button. + Action applied to the next button. + Action applied to the inactive buttons. + Any action is null. + + + + Computes the transition when changing selected index. + + Previous selected index. + New selected index. + + + + Sets the visibility of navigation buttons. + + Visibility of active buttons. + + + + Gets the navigation buttons. + + Previous button. + Next button. + Inactive buttons. + + + Identifies the dependency property. + + + + Gets or sets the banner text. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + + + + A sliding panel control that is hosted in a via a . + + + + + An event that is raised when property changes. + + + + + An event that is raised when the opening animation has finished. + + + + + An event that is raised when the closing animation has finished. + + + + + Gets or sets the position of this inside the . + + + + + Gets or sets whether this stays open when the user clicks somewhere outside of it. + + + + + Gets or sets whether this should be visible or not. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets whether the is completely shown (after was set to true). + + + + + Gets or sets whether this uses the open/close animation when changing the property (default is true). + + + + + Gets or sets whether this animates the opacity when opening/closing the . + + + + + Gets or sets whether this is modal. + + + + + Gets or sets a which will be executed if the close button was clicked. + + + The won't be executed when property will be set to false/true. + + + + + Gets or sets the parameter for the . + + + + + Gets or sets the theme for the . + + + + + Gets or sets the mouse button that closes the when the user clicks somewhere outside of it. + + + + + Gets or sets the visibility of the close button for this . + + + + + Gets or sets a value that indicates whether the close button is a Cancel button. A user can activate the Cancel button by pressing the ESC key. + + + + + Gets or sets the visibility of the title. + + + + + Gets or sets a value that indicates whether the uses animations for open/close. + + + + + Gets or sets the focused element. + + + + + Gets or sets a value indicating whether the should try focus an element. + + + + + Gets or sets a value indicating whether the should auto close after the has passed. + + + + + Gets or sets the time in milliseconds when the should auto close. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + property changed notifier used in . + + + + + property changed notifier used in . + + + + + A FlyoutsControl is for displaying flyouts in a . + + + + Identifies the dependency property. + + + + Gets or sets whether is ignored and all flyouts behave as if it was set to the value of this property. + + + + Identifies the dependency property. + + + + Gets or sets whether is ignored and all flyouts behave as if it was set false. + + + + + Adapts the theme to the theme of the host window or application. + + + + + Adapts the theme to the theme of the host window or application, but inverted. + + + This theme can only be applied if the host window's theme abides the "Dark" and "Light" affix convention. + (see for more infos. + + + + + Use the dark theme for the . This is the default theme. + + + + + Use the light theme for the . + + + + + The theme will match the host window's accent color. + + + + + Represents an icon that uses a glyph from the specified font. + + + + Identifies the dependency property. + + + + Gets or sets the character code that identifies the icon glyph. + + The hexadecimal character code for the icon glyph. + + + + The HamburgerMenu is based on a control. By default it contains a HamburgerButton and a ListView to display menu items. + + + + + Initializes a new instance of the class. + + + + + Override default OnApplyTemplate to capture children controls + + + + Identifies the routed event. + + + + Event raised when an item is clicked + + + + Identifies the routed event. + + + + Event raised when an options' item is clicked + + + + Identifies the routed event. + + + + Event raised when an item is invoked + + + + Identifies the routed event. + + + + Event raised when the hamburger button is clicked + + + + Identifies the dependency property. + + + + Gets or sets HamburgerMenu button's . + + + + Identifies the dependency property. + + + + Gets or sets the for the HamburgerMenu button. + + + + Identifies the dependency property. + + + + Gets or sets the margin for the HamburgerMenu button. + + + + Identifies the dependency property. + + + + Gets or sets the for the HamburgerMenu button. + + + + Identifies the dependency property. + + + + Gets or sets the for the HamburgerMenu button. + + + + Identifies the dependency property. + + + + Gets or sets the for the HamburgerMenu button. + + + + Identifies the dependency property. + + + + Gets or sets the for the HamburgerMenu button. + + + + Identifies the dependency property. + + + + Gets or sets the for the HamburgerMenu button. + + + + Identifies the dependency property. + + + + Gets or sets the for the HamburgerMenu pane header. + + + + Identifies the dependency property. + + + + Gets or sets an object source used to generate the content of the options. + + + + Identifies the dependency property. + + + + Gets or sets the used for each item in the options. + + + + Identifies the dependency property. + + + + Gets or sets the used to display each item in the options. + + + + Identifies the dependency property. + + + + Gets or sets the used to display each item in the options. + + + + Identifies the dependency property. + + + + Gets or sets the of the options menu. + + + + Identifies the dependency property. + + + + Gets or sets the selected options menu item. + + + + Identifies the dependency property. + + + + Gets or sets the selected options menu index. + + + + Identifies the dependency property. + + + + Gets or sets a which will be executed if an options item was clicked by the user. + + + + Identifies the dependency property. + + + + Gets or sets the parameter which will be passed by the . + + + + + Gets the collection used to generate the content of the option list. + + + Exception thrown if OptionsListView is not yet defined. + + + + + Executes the . + + + + Identifies the dependency property. + + + + Gets or sets the width of the pane when it's fully expanded. + + + + Identifies the dependency property. + + + + Gets or sets the width of the pane when in its compact display mode. + + + + Identifies the dependency property. + + + + Gets or sets the minimum width of the pane when it's fully expanded. + + + + Identifies the dependency property. + + + + Gets or sets the maximum width of the pane when it's fully expanded. + + + + Identifies the dependency property. + + + + Gets or Sets whether the open pane can be resized by the user. The default value is false. + + + + Identifies the dependency property. + + + + Gets or Sets the for the resizing Thumb (type of ) + + + + Identifies the dependency property. + + + + Gets or sets a value that specifies whether the pane is shown on the right or on left side of the HamburgerMenu. + + + + Identifies the dependency property. + + + + Gets or sets a value that specifies how the pane and content areas are shown. + + + + Identifies the dependency property. + + + + Gets or sets the margin for the pane. + + + + Identifies the dependency property. + + + + Gets or sets the margin for the pane header. + + + + Identifies the dependency property. + + + + Gets or sets the Brush to apply to the background of the pane area of the HamburgerMenu. + + + + Identifies the dependency property. + + + + Gets or sets the Brush to apply to the foreground of the pane area of the HamburgerMenu. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the pane is expanded to its full width. + + + + Identifies the dependency property. + + + + Gets or sets an object source used to generate the content of the menu. + + + + Identifies the dependency property. + + + + Gets or sets the used for each item. + + + + Identifies the dependency property. + + + + Gets or sets the used for each header item. + + + + Identifies the dependency property. + + + + Gets or sets the used for each separator item. + + + + Identifies the dependency property. + + + + Gets or sets the used to display each item. + + + + Identifies the dependency property. + + + + Gets or sets the used to display each item. + + + + Identifies the dependency property. + + + + Gets or sets the selected menu item. + + + + Identifies the dependency property. + + + + Gets or sets the selected menu index. + + + + Identifies the dependency property. + + + + Gets or sets the for the which shows the selected menu item content. + + + + Identifies the dependency property. + + + + Gets or sets a which will be executed if an item was clicked by the user. + + + + Identifies the dependency property. + + + + Gets or sets the parameter which will be passed by the . + + + + Identifies the dependency property. + + + + Gets or sets whether the ScrollBar of the HamburgerMenu is on the left side or on the right side of the menu items. + + + + Identifies the dependency property. + + + + Gets or sets whether a selection indicator will be shown on the HamburgerMenuItem. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets or sets the default FocusVisualStyle for a HamburgerMenuItem. + This style can be override at the HamburgerMenuItem style by setting the FocusVisualStyle property. + + + + + Gets the collection used to generate the content of the items list. + + + Exception thrown if ButtonsListView is not yet defined. + + + + + Executes the . + + + + + EventArgs used for the and events. + + + + + + + + + + + + + + Gets the clicked item (options item). + + + + + RoutedEventHandler used for the and events. + + + + + EventArgs used for the event. + + + + + + + + + + + + + + Gets the invoked item. + + + + + Gets a value indicating whether the invoked item is an options item + + + + + RoutedEventHandler used for the event. + + + + + The HamburgerMenuGlyphItem provides a glyph based implementation for HamburgerMenu entries. + + + + + Identifies the dependency property. + + + + + Gets or sets a value that specifies the glyph to use from Segoe MDL2 Assets font. + + + + + Identifies the dependency property. + + + + + Gets or sets a value that specifies label to display. + + + + + The HamburgerMenuIconItem provides an icon based implementation for HamburgerMenu entries. + + + + + Identifies the dependency property. + + + + + Gets or sets a value that specifies an user specific object which can be used as icon. + + + + + The HamburgerMenuImageItem provides an image based implementation for HamburgerMenu entries. + + + + + Identifies the dependency property. + + + + + Gets or sets a value that specifies a bitmap to display with an Image control. + + + + + The HamburgerMenuItem provides an implementation for HamburgerMenu entries. + + + + + Identifies the dependency property. + + + + + Identifies the dependency property. + + + + + Identifies the dependency property. + + + + + Identifies the dependency property. + + + + + Identifies the dependency property. + + + + + Identifies the dependency property. + + + + + Identifies the dependency property. + + + + + Gets or sets a value that specifies label to display. + + + + + Gets or sets a value that specifies the page to navigate to (if you use the HamburgerMenu with a Frame content) + + + + + Gets or sets a command which will be executed if an item is clicked by the user. + + + + + Gets or sets the command parameter which will be passed by the Command. + + + + + Gets or sets the element on which to raise the specified command. + + + Element on which to raise a command. + + + + + Gets or sets a value indicating whether this item is enabled in the user interface (UI). This is a dependency property. + + + true if the item is enabled; otherwise, false. The default value is true. + + + + + Gets or sets a value that specifies ToolTip to display. + + + + + Executes the command which can be set by the user. + + + + + Identifies the dependency property. + + + + + Identifies the dependency property. + + + + + Gets or sets a value that specifies an user specific value. + + + + + Gets or sets the value indicating whether this element is visible in the user interface (UI). This is a dependency property. + + + true if the item is visible, otherwise false. The default value is true. + + + + + The HamburgerMenuItemCollection provides typed collection of HamburgerMenuItemBase. + + + + + Gets or sets a value indicating whether which item container style will be used for the HamburgerMenuItem. + + + + + + + + The HamburgerMenuSeparatorItem provides an separator based implementation for HamburgerMenu entries. + + + + + Gets or sets a value that specifies label to display. + + + + + Gets or sets a value that specifies label to display. + + + + + Gets or sets a value that specifies ToolTip to display. + + + + + Gets or sets a value indicating whether this item is enabled in the user interface (UI). + + + true if the item is enabled; otherwise, false. The default value is true. + + + + + Gets or sets the value indicating whether this element is visible in the user interface (UI). This is a dependency property. + + + true if the item is visible, otherwise false. The default value is true. + + + + + Represents an hour comparison operation that ensures that 12 is smaller than 1. + This ensures that in the control the first hour that is selectable is 12 (AM/PM). + + + This ensures that the first hour that is selectable is 12 (AM/PM).

+ This comparer is used only if in the corresponding the value for is false. +
+
+ + + Gets the size of the CheckBox itself. + + + + + Sets the size of the CheckBox itself. + + + + + Gets the CornerRadius of the CheckBox itself. + The CheckCornerRadius property allows users to control the roundness of the CheckBox corners independently by setting a radius value for each corner. + + + + + Sets the CornerRadius of the CheckBox itself. + + + + + Gets the stroke thickness of the CheckBox itself. + + + + + Sets the stroke thickness of the CheckBox itself. + + + + + Gets the Glyph for IsChecked = false. + + + + + Sets the Glyph for IsChecked = false. + + + + + Gets the GlyphTemplate for IsChecked = false. + + + + + Sets the GlyphTemplate for IsChecked = false. + + + + + Gets the Foreground for IsChecked = false. + + + + + Sets the Foreground for IsChecked = false. + + + + + Gets the Background for IsChecked = false. + + + + + Sets the Background for IsChecked = false. + + + + + Gets the BorderBrush for IsChecked = false. + + + + + Sets the BorderBrush for IsChecked = false. + + + + + Gets the check BackgroundBrush for IsChecked = false. + + + + + Sets the BackgroundBrush for IsChecked = false. + + + + + Gets the check BorderBrush for IsChecked = false. + + + + + Sets the check BorderBrush for IsChecked = false. + + + + + Gets the check Foreground for IsChecked = false. + + + + + Sets the check Foreground for IsChecked = false. + + + + + Gets the Foreground for IsChecked = false, IsMouseOver = true. + + + + + Sets the Foreground for IsChecked = false, IsMouseOver = true. + + + + + Gets the Background for IsChecked = false, IsMouseOver = true. + + + + + Sets the Background for IsChecked = false, IsMouseOver = true. + + + + + Gets the BorderBrush for IsChecked = false, IsMouseOver = true. + + + + + Sets the BorderBrush for IsChecked = false, IsMouseOver = true. + + + + + Gets the check BackgroundBrush for IsChecked = false, IsMouseOver = true. + + + + + Sets the BackgroundBrush for IsChecked = false, IsMouseOver = true. + + + + + Gets the check BorderBrush for IsChecked = false, IsMouseOver = true. + + + + + Sets the check BorderBrush for IsChecked = false, IsMouseOver = true. + + + + + Gets the check Foreground for IsChecked = false, IsMouseOver = true. + + + + + Sets the check Foreground for IsChecked = false, IsMouseOver = true. + + + + + Gets the Foreground for IsChecked = false, IsPressed = true. + + + + + Sets the Foreground for IsChecked = false, IsPressed = true. + + + + + Gets the Background for IsChecked = false, IsPressed = true. + + + + + Sets the Background for IsChecked = false, IsPressed = true. + + + + + Gets the BorderBrush for IsChecked = false, IsPressed = true. + + + + + Sets the BorderBrush for IsChecked = false, IsPressed = true. + + + + + Gets the check BackgroundBrush for IsChecked = false, IsPressed = true. + + + + + Sets the BackgroundBrush for IsChecked = false, IsPressed = true. + + + + + Gets the check BorderBrush for IsChecked = false, IsPressed = true. + + + + + Sets the check BorderBrush for IsChecked = false, IsPressed = true. + + + + + Gets the check Foreground for IsChecked = false, IsPressed = true. + + + + + Sets the check Foreground for IsChecked = false, IsPressed = true. + + + + + Gets the Foreground for IsChecked = false, IsEnabled = false. + + + + + Sets the Foreground for IsChecked = false, IsEnabled = false. + + + + + Gets the Background for IsChecked = false, IsEnabled = false. + + + + + Sets the Background for IsChecked = false, IsEnabled = false. + + + + + Gets the BorderBrush for IsChecked = false, IsEnabled = false. + + + + + Sets the BorderBrush for IsChecked = false, IsEnabled = false. + + + + + Gets the check BackgroundBrush for IsChecked = false, IsEnabled = false. + + + + + Sets the BackgroundBrush for IsChecked = false, IsEnabled = false. + + + + + Gets the check BorderBrush for IsChecked = false, IsEnabled = false. + + + + + Sets the check BorderBrush for IsChecked = false, IsEnabled = false. + + + + + Gets the check Foreground for IsChecked = false, IsEnabled = false. + + + + + Sets the check Foreground for IsChecked = false, IsEnabled = false. + + + + + Gets the Glyph for IsChecked = true. + + + + + Sets the Glyph for IsChecked = true. + + + + + Gets the GlyphTemplate for IsChecked = true. + + + + + Sets the GlyphTemplate for IsChecked = true. + + + + + Gets the Foreground for IsChecked = true. + + + + + Sets the Foreground for IsChecked = true. + + + + + Gets the Background for IsChecked = true. + + + + + Sets the Background for IsChecked = true. + + + + + Gets the BorderBrush for IsChecked = true. + + + + + Sets the BorderBrush for IsChecked = true. + + + + + Gets the check Background for IsChecked = true. + + + + + Sets the check Background for IsChecked = true. + + + + + Gets the check BorderBrush for IsChecked = true. + + + + + Sets the check BorderBrush for IsChecked = true. + + + + + Gets the check glyph Foreground for IsChecked = true. + + + + + Sets the check glyph Foreground for IsChecked = true. + + + + + Gets the Foreground for IsChecked = true, IsMouseOver = true. + + + + + Sets the Foreground for IsChecked = true, IsMouseOver = true. + + + + + Gets the Background for IsChecked = true, IsMouseOver = true. + + + + + Sets the Background for IsChecked = true, IsMouseOver = true. + + + + + Gets the BorderBrush for IsChecked = true, IsMouseOver = true. + + + + + Sets the BorderBrush for IsChecked = true, IsMouseOver = true. + + + + + Gets the check Background for IsChecked = true, IsMouseOver = true. + + + + + Sets the check Background for IsChecked = true, IsMouseOver = true. + + + + + Gets the check BorderBrush for IsChecked = true, IsMouseOver = true. + + + + + Sets the check BorderBrush for IsChecked = true, IsMouseOver = true. + + + + + Gets the check glyph Foreground for IsChecked = true, IsMouseOver = true. + + + + + Sets the check glyph Foreground for IsChecked = true, IsMouseOver = true. + + + + + Gets the Foreground for IsChecked = true, IsPressed = true. + + + + + Sets the Foreground for IsChecked = true, IsPressed = true. + + + + + Gets the Background for IsChecked = true, IsPressed = true. + + + + + Sets the Background for IsChecked = true, IsPressed = true. + + + + + Gets the BorderBrush for IsChecked = true, IsPressed = true. + + + + + Sets the BorderBrush for IsChecked = true, IsPressed = true. + + + + + Gets the check Background for IsChecked = true, IsPressed = true. + + + + + Sets the check Background for IsChecked = true, IsPressed = true. + + + + + Gets the check BorderBrush for IsChecked = true, IsPressed = true. + + + + + Sets the check BorderBrush for IsChecked = true, IsPressed = true. + + + + + Gets the check glyph Foreground for IsChecked = true, IsPressed = true. + + + + + Sets the check glyph Foreground for IsChecked = true, IsPressed = true. + + + + + Gets the Foreground for IsChecked = true, IsEnabled = false. + + + + + Sets the Foreground for IsChecked = true, IsEnabled = false. + + + + + Gets the Background for IsChecked = true, IsEnabled = false. + + + + + Sets the Background for IsChecked = true, IsEnabled = false. + + + + + Gets the BorderBrush for IsChecked = true, IsEnabled = false. + + + + + Sets the BorderBrush for IsChecked = true, IsEnabled = false. + + + + + Gets the check Background for IsChecked = true, IsEnabled = false. + + + + + Sets the check Background for IsChecked = true, IsEnabled = false. + + + + + Gets the check BorderBrush for IsChecked = true, IsEnabled = false. + + + + + Sets the check BorderBrush for IsChecked = true, IsEnabled = false. + + + + + Gets the check glyph Foreground for IsChecked = true, IsEnabled = false. + + + + + Sets the check glyph Foreground for IsChecked = true, IsEnabled = false. + + + + + Gets the Glyph for IsChecked = null. + + + + + Sets the Glyph for IsChecked = null. + + + + + Gets the GlyphTemplate for IsChecked = null. + + + + + Sets the GlyphTemplate for IsChecked = null. + + + + + Gets the Foreground for IsChecked = null. + + + + + Sets the Foreground for IsChecked = null. + + + + + Gets the Background for IsChecked = null. + + + + + Sets the Background for IsChecked = null. + + + + + Gets the BorderBrush for IsChecked = null. + + + + + Sets the BorderBrush for IsChecked = null. + + + + + Gets the glyph BackgroundBrush for IsChecked = null. + + + + + Sets the glyph BackgroundBrush for IsChecked = null. + + + + + Gets the glyph BorderBrush for IsChecked = null. + + + + + Sets the glyph BorderBrush for IsChecked = null. + + + + + Gets the glyph Foreground for IsChecked = null. + + + + + Sets the glyph Foregorund for IsChecked = null. + + + + + Gets the Foreground for IsChecked = null, IsMouseOver = true. + + + + + Sets the Foreground for IsChecked = null, IsMouseOver = true. + + + + + Gets the Background for IsChecked = null, IsMouseOver = true. + + + + + Sets the Background for IsChecked = null, IsMouseOver = true. + + + + + Gets the BorderBrush for IsChecked = null, IsMouseOver = true. + + + + + Sets the BorderBrush for IsChecked = null, IsMouseOver = true. + + + + + Gets the glyph BackgroundBrush for IsChecked = null, IsMouseOver = true. + + + + + Sets the glyph BackgroundBrush for IsChecked = null, IsMouseOver = true. + + + + + Gets the glyph BorderBrush for IsChecked = null, IsMouseOver = true. + + + + + Sets the glyph BorderBrush for IsChecked = null, IsMouseOver = true. + + + + + Gets the glyph Foreground for IsChecked = null, IsMouseOver = true. + + + + + Sets the glyph Foregorund for IsChecked = null, IsMouseOver = true. + + + + + Gets the Foreground for IsChecked = null, IsPressed = true. + + + + + Sets the Foreground for IsChecked = null, IsPressed = true. + + + + + Gets the Background for IsChecked = null, IsPressed = true. + + + + + Sets the Background for IsChecked = null, IsPressed = true. + + + + + Gets the BorderBrush for IsChecked = null, IsPressed = true. + + + + + Sets the BorderBrush for IsChecked = null, IsPressed = true. + + + + + Gets the glyph BackgroundBrush for IsChecked = null, IsPressed = true. + + + + + Sets the glyph BackgroundBrush for IsChecked = null, IsPressed = true. + + + + + Gets the glyph BorderBrush for IsChecked = null, IsPressed = true. + + + + + Sets the glyph BorderBrush for IsChecked = null, IsPressed = true. + + + + + Gets the glyph Foreground for IsChecked = null, IsPressed = true. + + + + + Sets the glyph Foregorund for IsChecked = null, IsPressed = true. + + + + + Gets the Foreground for IsChecked = null, IsEnabled = false. + + + + + Sets the Foreground for IsChecked = null, IsEnabled = false. + + + + + Gets the Background for IsChecked = null, IsEnabled = false. + + + + + Sets the Background for IsChecked = null, IsEnabled = false. + + + + + Gets the BorderBrush for IsChecked = null, IsEnabled = false. + + + + + Sets the BorderBrush for IsChecked = null, IsEnabled = false. + + + + + Gets the glyph BackgroundBrush for IsChecked = null, IsEnabled = false. + + + + + Sets the glyph BackgroundBrush for IsChecked = null, IsEnabled = false. + + + + + Gets the glyph BorderBrush for IsChecked = null, IsEnabled = false. + + + + + Sets the glyph BorderBrush for IsChecked = null, IsEnabled = false. + + + + + Gets the glyph Foreground for IsChecked = null, IsEnabled = false. + + + + + Sets the glyph Foregorund for IsChecked = null, IsEnabled = false. + + + + + A helper class that provides various attached properties for the control. + + + + + Gets the Maximum number of characters the TextBox can accept. + + + + + Sets the Maximum number of characters the TextBox can accept. + + + + + Gets the Character casing of the TextBox. + + + + + Sets the Character casing of the TextBox. + + + + + A helper class that provides various controls. + + + + + Gets the value to handle the visibility of the DisabledVisualElement in the template. + + + + + Sets the value to handle the visibility of the DisabledVisualElement in the template. + + + + + The DependencyProperty for the CharacterCasing property. + Controls whether or not content is converted to upper or lower case + + + + + Gets the character casing of the control + + + + + Sets the character casing of the control + + + + + Gets the value if the inner ContentPresenter use AccessText in its style. + + + + + Sets the value if the inner ContentPresenter should use AccessText in its style. + + + + + Gets the brush used to draw the focus border. + + + + + Sets the brush used to draw the focus border. + + + + + Gets the brush used to draw the focus border. + + + + + Sets the brush used to draw the focus border. + + + + + Gets the brush used to draw the mouse over brush. + + + + + Sets the brush used to draw the mouse over brush. + + + + + DependencyProperty for property. + + + + + The CornerRadius property allows users to control the roundness of the button corners independently by + setting a radius value for each corner. Radius values that are too large are scaled so that they + smoothly blend from corner to corner. (Can be used e.g. at MetroButton style) + Description taken from original Microsoft description :-D + + + + + Gets or sets a value indicating whether the child contents of the control are not editable. + + + + + Gets a value indicating whether the child contents of the control are not editable. + + + + + Sets a value indicating whether the child contents of the control are not editable. + + + + + Attach this helper to the DataGrid. + + + + + + Detach the helper from the attached DataGrid + + + + + + + + + + + Sets binding from the source dependency property to the dependency property of the given target. + + The target object. + The target's dependency property. + The source object. + The dependency property of the source. + + + + Clears the binding from the source dependency property to the dependency property of the given target. + + The target object. + The target's dependency property. + The source object. + The dependency property of the source. + + + + Overriding classes should avoid returning 'this' as this would like result in in the method + + + + The DependencyProperty for the ' AutoGeneratedCheckBoxColumnStyle property. + + If a style is set, the DataGridCheckBoxColumn of the DataGrid will use this style for normal cells. + + + + + Helper for getting from . + + If a style is set, the DataGridCheckBoxColumn of the DataGrid will use this style for normal cells. + + to read from. + AutoGeneratedCheckBoxColumnStyle property value. + + + + Helper for setting on . + + If a style is set, the DataGridCheckBoxColumn of the DataGrid will use this style for normal cells. + + to set on. + AutoGeneratedCheckBoxColumnStyle property value. + + + + The DependencyProperty for the ' AutoGeneratedCheckBoxColumnEditingStyle property. + + If a style is set, the DataGridCheckBoxColumn of the DataGrid will use this style for cells in edit mode. + + + + + Helper for getting from . + + If a style is set, the DataGridCheckBoxColumn of the DataGrid will use this style for cells in edit mode. + + to read from. + AutoGeneratedCheckBoxColumnEditingStyle property value. + + + + Helper for setting on . + + If a style is set, the DataGridCheckBoxColumn of the DataGrid will use this style for cells in edit mode. + + to set on. + AutoGeneratedCheckBoxColumnEditingStyle property value. + + + + The DependencyProperty for the ' AutoGeneratedTextColumnStyle property. + + If a style is set, the DataGridTextColumn columns of the DataGrid will use this style for normal cells. + + + + + Helper for getting from . + + If a style is set, the DataGridTextColumn columns of the DataGrid will use this style for normal cells. + + to read from. + AutoGeneratedTextColumnStyle property value. + + + + Helper for setting on . + + If a style is set, the DataGridTextColumn columns of the DataGrid will use this style for normal cells. + + to set on. + AutoGeneratedTextColumnStyle property value. + + + + The DependencyProperty for the ' AutoGeneratedTextColumnEditingStyle property. + + If a style is set, the DataGridTextColumn of the DataGrid will use this style for cells in edit mode. + + + + + Helper for getting from . + + If a style is set, the DataGridTextColumn of the DataGrid will use this style for cells in edit mode. + + to read from. + AutoGeneratedTextColumnEditingStyle property value. + + + + Helper for setting on . + + If a style is set, the DataGridTextColumn of the DataGrid will use this style for cells in edit mode. + + to set on. + AutoGeneratedTextColumnEditingStyle property value. + + + + The DependencyProperty for the ' AutoGeneratedComboBoxColumnStyle property. + + If a style is set, the DataGridComboBoxColumn columns of the DataGrid will use this style for normal cells. + + + + + Helper for getting from . + + If a style is set, the DataGridComboBoxColumn columns of the DataGrid will use this style for normal cells. + + to read from. + AutoGeneratedComboBoxColumnStyle property value. + + + + Helper for setting on . + + If a style is set, the DataGridComboBoxColumn columns of the DataGrid will use this style for normal cells. + + to set on. + AutoGeneratedComboBoxColumnStyle property value. + + + + The DependencyProperty for the ' AutoGeneratedComboBoxColumnEditingStyle property. + + If a style is set, the DataGridComboBoxColumn of the DataGrid will use this style for cells in edit mode. + + + + + Helper for getting from . + + If a style is set, the DataGridComboBoxColumn of the DataGrid will use this style for cells in edit mode. + + to read from. + AutoGeneratedComboBoxColumnEditingStyle property value. + + + + Helper for setting on . + + If a style is set, the DataGridComboBoxColumn of the DataGrid will use this style for cells in edit mode. + + to set on. + AutoGeneratedComboBoxColumnEditingStyle property value. + + + + The DependencyProperty for the ' AutoGeneratedNumericUpDownColumnStyle property. + + If a style is set, the DataGridNumericUpDownColumn columns of the DataGrid will use this style for normal cells. + + + + + Helper for getting from . + + If a style is set, the DataGridNumericUpDownColumn columns of the DataGrid will use this style for normal cells. + + to read from. + AutoGeneratedNumericUpDownColumnStyle property value. + + + + Helper for setting on . + + If a style is set, the DataGridNumericUpDownColumn columns of the DataGrid will use this style for normal cells. + + to set on. + AutoGeneratedNumericUpDownColumnStyle property value. + + + + The DependencyProperty for the ' AutoGeneratedNumericUpDownColumnEditingStyle property. + + If a style is set, the DataGridNumericUpDownColumn of the DataGrid will use this style for cells in edit mode. + + + + + Helper for getting from . + + If a style is set, the DataGridNumericUpDownColumn of the DataGrid will use this style for cells in edit mode. + + to read from. + AutoGeneratedNumericUpDownColumnEditingStyle property value. + + + + Helper for setting on . + + If a style is set, the DataGridNumericUpDownColumn of the DataGrid will use this style for cells in edit mode. + + to set on. + AutoGeneratedNumericUpDownColumnEditingStyle property value. + + + + The DependencyProperty for the ' AutoGeneratedHyperlinkColumnStyle property. + + If a style is set, the DataGridHyperlinkColumn columns of the DataGrid will use this style for normal cells. + + + + + Helper for getting from . + + If a style is set, the DataGridHyperlinkColumn columns of the DataGrid will use this style for normal cells. + + to read from. + AutoGeneratedHyperlinkColumnStyle property value. + + + + Helper for setting on . + + If a style is set, the DataGridHyperlinkColumn columns of the DataGrid will use this style for normal cells. + + to set on. + AutoGeneratedHyperlinkColumnStyle property value. + + + + The DependencyProperty for the ' AutoGeneratedHyperlinkColumnEditingStyle property. + + If a style is set, the DataGridHyperlinkColumn of the DataGrid will use this style for cells in edit mode. + + + + + Helper for getting from . + + If a style is set, the DataGridHyperlinkColumn of the DataGrid will use this style for cells in edit mode. + + to read from. + AutoGeneratedHyperlinkColumnEditingStyle property value. + + + + Helper for setting on . + + If a style is set, the DataGridHyperlinkColumn of the DataGrid will use this style for cells in edit mode. + + to set on. + AutoGeneratedHyperlinkColumnEditingStyle property value. + + + + Gets the padding inside the cell. + + + + + Sets the padding inside the cell. + + + + + Gets the padding inside the column. + + + + + Sets the padding inside the column. + + + + + Gets a value which indicates the preview cell editing is enabled or not. + + + + + Sets a value which indicates the preview cell editing is enabled or not. + + + + + Gets the value to define the selection behavior. + + + + + Sets the value to define the selection behavior. + + + + + The DependencyProperty for the ' ColumnStylesHelper property. + + If the helper is set, the columns of the DataGrid will use the styles for the columns from the ' attached properties. + + + + + Helper for getting from . + + If the helper is set, the columns of the DataGrid will use the styles for the columns from the ' attached properties. + + to read from. + ColumnStylesHelper property value. + + + + Helper for setting from . + + If the helper is set, the columns of the DataGrid will use the styles for the columns from the ' attached properties. + + to set on. + ColumnStylesHelper property value. + + + + Gets the content of the DropDown Button. + + + + + Sets the content of the DropDown Button. + + + + + Gets the data template used to display the content of the DropDown Button. + + + + + Sets the data template used to display the content of the DropDown Button. + + + + + Gets the font family of the desired font. + + + + + Sets the font family of the desired font. + + + + + Gets the size of the desired font. + + + + + Sets the size of the desired font. + + + + + A helper class that provides various attached properties for the Expander control. + + + + + + Gets the toggle button style used for the ExpandDirection Up. + + + + + Sets the toggle button style used for the ExpandDirection Up. + + + + + Gets the toggle button style used for the ExpandDirection Down. + + + + + Sets the toggle button style used for the ExpandDirection Down. + + + + + Gets the toggle button style used for the ExpandDirection Left. + + + + + Sets the toggle button style used for the ExpandDirection Left. + + + + + Gets the toggle button style used for the ExpandDirection Right. + + + + + Sets the toggle button style used for the ExpandDirection Right. + + + + + The DependencyProperty for the ' ExpandStoryboard property. + + If the Storyboard is set, the expanded event applies this to the inner grid. + + + + + Helper for getting from . + + If the Storyboard is set, the expanded event applies this to the inner grid. + + to read from. + ExpandStoryboard property value. + + + + Helper for setting on . + + If the Storyboard is set, the expanded event applies this to the inner grid. + + to set on. + ExpandStoryboard property value. + + + + The DependencyProperty for the ' CollapseStoryboard property. + + If the Storyboard is set, the collapsed event applies this to the inner grid. + + + + + Helper for getting from . + + If the Storyboard is set, the collapsed event applies this to the inner grid. + + to read from. + CollapseStoryboard property value. + + + + Helper for setting on . + + If the Storyboard is set, the collapsed event applies this to the inner grid. + + to set on. + CollapseStoryboard property value. + + + + Gets the value of the Foreground for the header. + + + + + Sets the value of the Foreground for the header. + + + + + Gets the value of the Background for the header. + + + + + Sets the value of the Background for the header. + + + + + Gets the value of the FontFamily for the header. + + + + + Sets the value of the FontFamily for the header. + + + + + Gets the value of the FontSize for the header. + + + + + Sets the value of the FontSize for the header. + + + + + Gets the value of the FontStretch for the header. + + + + + Sets the value of the FontStretch for the header. + + + + + Gets the value of the FontWeight for the header. + + + + + Sets the value of the FontWeight for the header. + + + + + Gets or sets the outer margin for the header. + + + + + Sets or sets the outer margin for the header. + + + + + Gets the horizontal alignment of the header. + + + + + Sets the horizontal alignment of the header. + + + + + Gets the vertical alignment of the header. + + + + + Sets the vertical alignment of the header. + + + + + Gets or sets the background brush which will be used for the active selected item (if the keyboard focus is within). + + + + + Gets the brush the background brush which will be used for the active selected item (if the keyboard focus is within). + + + + + Sets the brush the background brush which will be used for the active selected item (if the keyboard focus is within). + + + + + Gets or sets the foreground brush which will be used for the active selected item (if the keyboard focus is within). + + + + + Gets the brush the foreground brush which will be used for the active selected item (if the keyboard focus is within). + + + + + Sets the brush the foreground brush which will be used for the active selected item (if the keyboard focus is within). + + + + + Gets or sets the background brush which will be used for a selected item. + + + + + Gets the background brush which will be used for a selected item. + + + + + Sets the background brush which will be used for a selected item. + + + + + Gets or sets the foreground brush which will be used for a selected item. + + + + + Gets the foreground brush which will be used for a selected item. + + + + + Sets the foreground brush which will be used for a selected item. + + + + + Gets or sets the background brush which will be used for an mouse hovered item. + + + + + Gets the background brush which will be used for an mouse hovered item. + + + + + Sets the background brush which will be used for an mouse hovered item. + + + + + Gets or sets the foreground brush which will be used for an mouse hovered item. + + + + + Gets the foreground brush which will be used for an mouse hovered item. + + + + + Sets the foreground brush which will be used for an mouse hovered item. + + + + + Gets or sets the background brush which will be used for an mouse hovered and selected item. + + + + + Gets the background brush which will be used for an mouse hovered and selected item. + + + + + Sets the background brush which will be used for an mouse hovered and selected item. + + + + + Gets or sets the foreground brush which will be used for an mouse hovered and selected item. + + + + + Gets the foreground brush which will be used for an mouse hovered and selected item. + + + + + Sets the foreground brush which will be used for an mouse hovered and selected item. + + + + + Gets or sets the background brush which will be used for selected disabled items. + + + + + Gets the background brush which will be used for selected disabled items. + + + + + Sets the background brush which will be used for selected disabled items. + + + + + Gets or sets the foreground brush which will be used for selected disabled items. + + + + + Gets the foreground brush which will be used for selected disabled items. + + + + + Sets the foreground brush which will be used for selected disabled items. + + + + + Gets or sets the background brush which will be used for disabled items. + + + + + Gets the background brush which will be used for disabled items. + + + + + Sets the background brush which will be used for disabled items. + + + + + Gets or sets the foreground brush which will be used for disabled items. + + + + + Gets the foreground brush which will be used for disabled items. + + + + + Sets the foreground brush which will be used for disabled items. + + + + + Gets or sets the background brush which will be used when an item is pressed by the left mouse button. + + + + + Gets the background brush which will be used when an item is pressed by the left mouse button. + + + + + Sets the background brush which will be used when an item is pressed by the left mouse button. + + + + + Gets or sets the foreground brush which will be used when an item is pressed by the left mouse button. + + + + + Gets the foreground brush which will be used when an item is pressed by the left mouse button. + + + + + Sets the foreground brush which will be used when an item is pressed by the left mouse button. + + + + + Gets or sets the background brush which will be used when an item is pressed by the right mouse button. + + + + + Gets the background brush which will be used when an item is pressed by the right mouse button. + + + + + Sets the background brush which will be used when an item is pressed by the right mouse button. + + + + + Gets or sets the foreground brush which will be used when an item is pressed by the right mouse button. + + + + + Gets the foreground brush which will be used when an item is pressed by the right mouse button. + + + + + Sets the foreground brush which will be used when an item is pressed by the right mouse button. + + + + + Change the value of the slider if the user rotates the mouse wheel by the value defined for + + + + + Change the value of the slider if the user rotates the mouse wheel by the value defined for + + + + + Do not change the value of the slider if the user rotates the mouse wheel. + + + + + Change the value of the slider only if the control is focused. + + + + + Changes the value of the slider if the mouse pointer is over this element. + + + + + Defines a helper class for selected items binding on collections with multiselector elements + + + + + Handles disposal and creation of old and new bindings + + + + + Gets the selected items property binding + + + + + Sets the selected items property binding + + + + + Gets the for a binding + + + + + Sets the for a bining + + + + + Defines a binding between multi selector and property + + + + + Creates an instance of + + The selector of this binding + The bound collection + + + + Registers the event handlers for selector and collection changes + + + + + Unregisters the event handlers for selector and collection changes + + + + + Updates the collection with changes made in the selector + + + + + Updates the selector with changes made in the collection + + + + + Gets the content of the RevealButton. + + + + + Sets the content of the RevealButton. + + + + + Gets the data template used to display the content of the RevealButton. + + + + + Sets the data template used to display the content of the RevealButton. + + + + Helper for getting from . + to read from. + RadioSize property value. + + + Helper for setting on . + to set on. + RadioSize property value. + + + Helper for getting from . + to read from. + RadioCheckSize property value. + + + Helper for setting on . + to set on. + RadioCheckSize property value. + + + Helper for getting from . + to read from. + RadioStrokeThickness property value. + + + Helper for setting on . + to set on. + RadioStrokeThickness property value. + + + Helper for getting from . + to read from. + ForegroundPointerOver property value. + + + Helper for setting on . + to set on. + ForegroundPointerOver property value. + + + Helper for getting from . + to read from. + ForegroundPressed property value. + + + Helper for setting on . + to set on. + ForegroundPressed property value. + + + Helper for getting from . + to read from. + ForegroundDisabled property value. + + + Helper for setting on . + to set on. + ForegroundDisabled property value. + + + Helper for getting from . + to read from. + BackgroundPointerOver property value. + + + Helper for setting on . + to set on. + BackgroundPointerOver property value. + + + Helper for getting from . + to read from. + BackgroundPressed property value. + + + Helper for setting on . + to set on. + BackgroundPressed property value. + + + Helper for getting from . + to read from. + BackgroundDisabled property value. + + + Helper for setting on . + to set on. + BackgroundDisabled property value. + + + Helper for getting from . + to read from. + BorderBrushPointerOver property value. + + + Helper for setting on . + to set on. + BorderBrushPointerOver property value. + + + Helper for getting from . + to read from. + BorderBrushPressed property value. + + + Helper for setting on . + to set on. + BorderBrushPressed property value. + + + Helper for getting from . + to read from. + BorderBrushDisabled property value. + + + Helper for setting on . + to set on. + BorderBrushDisabled property value. + + + Helper for getting from . + to read from. + OuterEllipseFill property value. + + + Helper for setting on . + to set on. + OuterEllipseFill property value. + + + Helper for getting from . + to read from. + OuterEllipseFillPointerOver property value. + + + Helper for setting on . + to set on. + OuterEllipseFillPointerOver property value. + + + Helper for getting from . + to read from. + OuterEllipseFillPressed property value. + + + Helper for setting on . + to set on. + OuterEllipseFillPressed property value. + + + Helper for getting from . + to read from. + OuterEllipseFillDisabled property value. + + + Helper for setting on . + to set on. + OuterEllipseFillDisabled property value. + + + Helper for getting from . + to read from. + OuterEllipseStroke property value. + + + Helper for setting on . + to set on. + OuterEllipseStroke property value. + + + Helper for getting from . + to read from. + OuterEllipseStrokePointerOver property value. + + + Helper for setting on . + to set on. + OuterEllipseStrokePointerOver property value. + + + Helper for getting from . + to read from. + OuterEllipseStrokePressed property value. + + + Helper for setting on . + to set on. + OuterEllipseStrokePressed property value. + + + Helper for getting from . + to read from. + OuterEllipseStrokeDisabled property value. + + + Helper for setting on . + to set on. + OuterEllipseStrokeDisabled property value. + + + Helper for getting from . + to read from. + OuterEllipseCheckedFill property value. + + + Helper for setting on . + to set on. + OuterEllipseCheckedFill property value. + + + Helper for getting from . + to read from. + OuterEllipseCheckedFillPointerOver property value. + + + Helper for setting on . + to set on. + OuterEllipseCheckedFillPointerOver property value. + + + Helper for getting from . + to read from. + OuterEllipseCheckedFillPressed property value. + + + Helper for setting on . + to set on. + OuterEllipseCheckedFillPressed property value. + + + Helper for getting from . + to read from. + OuterEllipseCheckedFillDisabled property value. + + + Helper for setting on . + to set on. + OuterEllipseCheckedFillDisabled property value. + + + Helper for getting from . + to read from. + OuterEllipseCheckedStroke property value. + + + Helper for setting on . + to set on. + OuterEllipseCheckedStroke property value. + + + Helper for getting from . + to read from. + OuterEllipseCheckedStrokePointerOver property value. + + + Helper for setting on . + to set on. + OuterEllipseCheckedStrokePointerOver property value. + + + Helper for getting from . + to read from. + OuterEllipseCheckedStrokePressed property value. + + + Helper for setting on . + to set on. + OuterEllipseCheckedStrokePressed property value. + + + Helper for getting from . + to read from. + OuterEllipseCheckedStrokeDisabled property value. + + + Helper for setting on . + to set on. + OuterEllipseCheckedStrokeDisabled property value. + + + Helper for getting from . + to read from. + CheckGlyphFill property value. + + + Helper for setting on . + to set on. + CheckGlyphFill property value. + + + Helper for getting from . + to read from. + CheckGlyphFillPointerOver property value. + + + Helper for setting on . + to set on. + CheckGlyphFillPointerOver property value. + + + Helper for getting from . + to read from. + CheckGlyphFillPressed property value. + + + Helper for setting on . + to set on. + CheckGlyphFillPressed property value. + + + Helper for getting from . + to read from. + CheckGlyphFillDisabled property value. + + + Helper for setting on . + to set on. + CheckGlyphFillDisabled property value. + + + Helper for getting from . + to read from. + CheckGlyphStroke property value. + + + Helper for setting on . + to set on. + CheckGlyphStroke property value. + + + Helper for getting from . + to read from. + CheckGlyphStrokePointerOver property value. + + + Helper for setting on . + to set on. + CheckGlyphStrokePointerOver property value. + + + Helper for getting from . + to read from. + CheckGlyphStrokePressed property value. + + + Helper for setting on . + to set on. + CheckGlyphStrokePressed property value. + + + Helper for getting from . + to read from. + CheckGlyphStrokeDisabled property value. + + + Helper for setting on . + to set on. + CheckGlyphStrokeDisabled property value. + + + + Identifies the VerticalScrollBarOnLeftSide attached property. + This property can be used to set vertical scrollbar left side from the tabpanel (look at MetroAnimatedSingleRowTabControl) + + + + Helper for getting from . + to read from. + VerticalScrollBarOnLeftSide property value. + + + Helper for setting on . + to set on. + VerticalScrollBarOnLeftSide property value. + + + + Identifies the IsHorizontalScrollWheelEnabled attached property. + + + + Helper for getting from . + to read from. + IsHorizontalScrollWheelEnabled property value. + + + Helper for setting on . + to set on. + IsHorizontalScrollWheelEnabled property value. + + + + This property can be used to trigger the call to a command when the user reach the end of the vertical scrollable area. + + + + Helper for getting from . + to read from. + EndOfVerticalScrollReachedCommand property value. + + + Helper for setting on . + to set on. + EndOfVerticalScrollReachedCommand property value. + + + + This property can be used to trigger the call to a command when the user reach the end of the horizontal scrollable area. + + + + Helper for getting from . + to read from. + EndOfHorizontalScrollReachedCommand property value. + + + Helper for setting on . + to set on. + EndOfHorizontalScrollReachedCommand property value. + + + + This property can be used to provide a command parameter to the command called when reaching the end of the vertical or horizontal scrollable area. + + + + Helper for getting from . + to read from. + EndOfScrollReachedCommandParameter property value. + + + Helper for setting on . + to set on. + EndOfScrollReachedCommandParameter property value. + + + Helper for getting on . + to get on. + + + Helper for setting on . + to set on. + BubbleUpScrollEventToParentScrollviewerProperty property value. + + + + Gets or sets the brush of the thumb. + + + + + Gets the brush of the thumb. + + + + + Sets the brush of the thumb. + + + + + Gets or sets the brush of the thumb if the mouse is over the slider. + + + + + Gets the brush of the thumb if the mouse is over the slider. + + + + + Sets the brush of the thumb if the mouse is over the slider. + + + + + Gets or sets the brush of the thumb if the mouse button is pressed. + + + + + Gets the brush of the thumb if the mouse button is pressed. + + + + + Sets the brush of the thumb if the mouse button is pressed. + + + + + Gets or sets the brush of the thumb if the slider is disabled. + + + + + Gets the brush of the thumb if the slider is disabled. + + + + + Sets the brush of the thumb if the slider is disabled. + + + + + Gets or sets the brush of the track. + + + + + Gets the brush of the track. + + + + + Sets the brush of the track. + + + + + Gets or sets the brush of the track if the mouse is over the slider. + + + + + Gets the brush of the track if the mouse is over the slider. + + + + + Sets the brush of the track if the mouse is over the slider. + + + + + Gets or sets the brush of the track if the mouse button is pressed. + + + + + Gets the brush of the track if the mouse button is pressed. + + + + + Sets the brush of the track if the mouse button is pressed. + + + + + Gets or sets the brush of the track if the slider is disabled. + + + + + Gets the brush of the track if the slider is disabled. + + + + + Sets the brush of the track if the slider is disabled. + + + + + Gets or sets the brush of the track value. + + + + + Gets the brush of the track value. + + + + + Sets the brush of the track value. + + + + + Gets or sets the brush of the track value if the mouse is over the slider. + + + + + Gets the brush of the track value if the mouse is over the slider. + + + + + Sets the brush of the track value if the mouse is over the slider. + + + + + Gets or sets the brush of the track value if the mouse button is pressed. + + + + + Gets the brush of the track value if the mouse button is pressed. + + + + + Sets the brush of the track value if the mouse button is pressed. + + + + + Gets or sets the brush of the track value if the slider is disabled. + + + + + Gets the brush of the track value if the slider is disabled. + + + + + Sets the brush of the track value if the slider is disabled. + + + + + Gets/Sets the type how the value will be changed if the user rotates the mouse wheel. + + + + + Gets/Sets the type how the value will be changed if the user rotates the mouse wheel. + + + + + Gets/Sets the value when the slider will be changed. Possible values are if the slider is focused or if the mouse is over the slider. + + + + + Gets/Sets the value when the slider will be changed. Possible values are if the slider is focused or if the mouse is over the slider. + + + + + Specifies the underline position of a TabControl. + + + + Sets the Style and Template property to null. + + Removing a TabItem in code behind can produce such nasty output + System.Windows.Data Warning: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='System.Windows.Controls.TabControl', AncestorLevel='1''. BindingExpression:Path=Background; DataItem=null; target element is 'TabItem' (Name=''); target property is 'Background' (type 'Brush') + or + System.Windows.Data Error: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='System.Windows.Controls.TabControl', AncestorLevel='1''. BindingExpression:Path=(0); DataItem=null; target element is 'TabItem' (Name=''); target property is 'UnderlineBrush' (type 'Brush') + + This is a timing problem in WPF of the binding mechanism itself. + + To avoid this, we can set the Style and Template to null. + + + + Identifies the CloseButtonEnabled attached property. + + + + + Gets whether a close button should be visible or not. + + + + + Sets whether a close button should be visible or not. + + + + + Identifies the CloseTabCommand attached property. + + + + + Gets a command for the TabItem which executes if the TabItem will be closed. + + + + + Sets a command for the TabItem which executes if the TabItem will be closed. + + + + + Identifies the CloseTabCommandParameter attached property. + + + + + Gets a command parameter for the TabItem that will be passed to the CloseTabCommand. + + + + + Sets a command parameter for the TabItem that will be passed to the CloseTabCommand. + + + + + Defines whether the underline below the or is shown or not. + + + + + Defines the underline brush below the or . + + + + + Defines the underline brush below the or of an selected item. + + + + + Defines the underline brush below the or if the mouse is over an item. + + + + + Defines the underline brush below the or if the mouse is over a selected item. + + + + + This property can be used to set the Transition for animated TabControls + + + + + Defines the position of the Underline + + + + + A helper class that provides various attached properties for the TextBox control. + + + Password watermarking code from: http://prabu-guru.blogspot.com/2010/06/how-to-add-watermark-text-to-textbox.html + + + + + The clear text button behavior property. It sets a click event to the button if the value is true. + + + + + This property can be used to set the button width (PART_ClearText) of TextBox, PasswordBox, ComboBox, NumericUpDown + + + + + This property can be used to retrieve the watermark using the of bound property. + + + Setting this property to true will uses reflection. + + + + + Indicates if a TextBox or RichTextBox should use SpellCheck context menu + + + + + Indicates if the watermark is automatically retrieved by using the of the bound property. + + This attached property uses reflection; thus it might reduce the performance of the application. + The auto-watermak does work for the following controls: + In the following case no custom watermark is shown + + There is no binding + Binding path errors + Binding to a element of a collection without using a property of that element Binding Path=Collection[0] use: Binding Path=Collection[0].SubProperty + The bound property does not have a + + + + + Gets a value that indicates the horizontal alignment of the watermark. + + + One of the values that specifies the desired alignment. The default is . + + + + + Sets a value that indicates the horizontal alignment of the watermark. + + + + + Gets the text trimming behavior to employ when watermark overflows the content area. + + + One of the values that specifies the text trimming behavior to employ. The default is . + + + + + Sets the text trimming behavior to employ when watermark overflows the content area. + + + + + Gets how the watermark should wrap text. + + One of the values. The default is . + + + + + Sets how the watermark should wrap text. + + + + + Gets if the attached TextBox has text. + + + + + Gets the clear text button visibility / feature. Can be used to enable text deletion. + + + + + Sets the clear text button visibility / feature. Can be used to enable text deletion. + + + + + Gets the text button visibility. + + + + + Sets the text button visibility. + + + + + Gets the buttons placement variant. + + + + + Sets the buttons placement variant. + + + + + Gets the clear text button behavior. + + + + + Sets the clear text button behavior. + + + + + ButtonContentTemplate is the template used to display the content of the ClearText button. + + + + + This property can be used to handle the style for CheckBox and RadioButton + LeftToRight means content left and button right and RightToLeft vise versa + + + + + This property can be used to handle the style for CheckBox and RadioButton + LeftToRight means content left and button right and RightToLeft vise versa + + + + + Gets the toggle button style used for the TreeViewItem expander. + + + + + Sets the toggle button style used for the TreeViewItem expander. + + + + + Identifies the CloseOnMouseLeftButtonDown attached property. + + + + + Gets whether if the popup can be closed by left mouse button down. + + + + + Sets whether if the popup can be closed by left mouse button down. + + + + + Identifies the ShowValidationErrorOnMouseOver attached property. + + + + + Gets whether the validation error text will be shown when hovering the validation triangle. + + + + + Sets whether the validation error text will be shown when hovering the validation triangle. + + + + + Represents the base class for an icon UI element. + + + + + A MetroTabControl (Pivot) that wraps TabItem/MetroTabItem headers on a single row. + + + + + Initializes a new instance of the pyRevitLabs.MahAppsMetro.Controls.MetroAnimatedSingleRowTabControl class. + + + + + A MetroTabControl (Pivot) that uses a TransitioningContentControl to animate the contents of a TabItem/MetroTabItem. + + + + + Initializes a new instance of the pyRevitLabs.MahAppsMetro.Controls.MetroAnimatedTabControl class. + + + + + A ContentControl which use a transition to slide in the content. + + + + Identifies the dependency property. + + + + Gets or sets whether the reverse version of the transition should be used. + + + + Identifies the dependency property. + + + + Gets or sets the value if a transition should be used or not. + + + + Identifies the dependency property. + + + + Gets or sets whether the transition should be used only at the loaded event of the control. + + + + Identifies the routed event. + + + + The event which will be fired when the transition starts. + + + + Identifies the routed event. + + + + The event which will be fired when the transition ends. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets whether if the content is transitioning. + + + + + Execute the transition again. + + + + + + + + Creates AutomationPeer () + + + + + A reimplementation of NavigationWindow based on MetroWindow. + + + + MetroNavigationWindow + + + + + Gets an IEnumerable that you use to enumerate the entries in back navigation history for a NavigationWindow. + + + + + + Gets an IEnumerable that you use to enumerate the entries in back navigation history for a NavigationWindow. + + + + + + Gets the NavigationService that is used by this MetroNavigationWindow to provide navigation services to its content. + + + + + + Gets a value that indicates whether there is at least one entry in back navigation history. + + + + + + Gets a value that indicates whether there is at least one entry in forward navigation history. + + + + + + Gets or sets the base uniform resource identifier (URI) of the current context. + + + + + + Gets or sets the uniform resource identifier (URI) of the current content, or the URI of new content that is currently being navigated to. + + + + + + Adds an entry to back navigation history that contains a CustomContentState object. + + A CustomContentState object that represents application-defined state that is associated with a specific piece of content. + + + + + Removes the most recent journal entry from back history. + + The most recent JournalEntry in back navigation history, if there is one. + + + + + Navigates to the most recent item in back navigation history. + + + + + + Navigates to the most recent item in forward navigation history. + + + + + + Navigates asynchronously to content that is contained by an object. + + An Object that contains the content to navigate to. + true if a navigation is not canceled; otherwise, false. + + + + + Navigates asynchronously to content that is specified by a uniform resource identifier (URI). + + A Uri object initialized with the URI for the desired content. + true if a navigation is not canceled; otherwise, false. + + + + + Navigates asynchronously to content that is contained by an object, and passes an object that contains data to be used for processing during navigation. + + An Object that contains the content to navigate to. + A Object that contains data to be used for processing during navigation. + true if a navigation is not canceled; otherwise, false. + + + + + Navigates asynchronously to source content located at a uniform resource identifier (URI), and pass an object that contains data to be used for processing during navigation. + + A Uri object initialized with the URI for the desired content. + A Object that contains data to be used for processing during navigation. + true if a navigation is not canceled; otherwise, false. + + + + + Stops further downloading of content for the current navigation request. + + + + + + Occurs when navigation to a content fragment begins, which occurs immediately, if the desired fragment is in the current content, or after the source XAML content has been loaded, if the desired fragment is in different content. + + + + + + Occurs when a new navigation is requested. + + + + + + Occurs when an error is raised while navigating to the requested content. + + + + + + Occurs periodically during a download to provide navigation progress information. + + + + + + Occurs when the StopLoading method is called, or when a new navigation is requested while a current navigation is in progre + + + + + + Occurs when the content that is being navigated to has been found, and is available from the PageContent property, although it may not have completed loading + + + + + + Occurs when content that was navigated to has been loaded, parsed, and has begun rendering. + + + + + + InitializeComponent + + + + + A metrofied ProgressBar. + + + + + + Gets/sets the diameter of the ellipses used in the indeterminate animation. + + + + + Gets/sets the offset of the ellipses used in the indeterminate animation. + + + + + A standard MetroTabControl (Pivot). + + + + + Initializes a new instance of the pyRevitLabs.MahAppsMetro.Controls.MetroTabControl class. + + + + Identifies the dependency property. + + + + A base class for every MetroTabControl (Pivot). + + + + + Get/sets the command that executes when a MetroTabItem's close button is clicked. + + + + + An event that is raised when a TabItem is closed. + + + + + Event args that is created when a TabItem is closed. + + + + + Gets the MetroTabItem that will be closed. + + + + + An extended TabItem with a metro style. + + + + + Gets/sets whether the Close Button is visible. + + + + + Gets/sets the command that is executed when the Close Button is clicked. + + + + + Gets/sets the command parameter which is passed to the close button command. + + + + + Gets/sets the Close Button Margin. + + + + + The MetroThumbContentControl control can be used for titles or something else and enables basic drag movement functionality. + + + + + Adds or remove a DragStartedEvent handler + + + + + Adds or remove a DragDeltaEvent handler + + + + + Adds or remove a DragCompletedEvent handler + + + + + DependencyProperty for the IsDragging property. + + + + + Indicates that the left mouse button is pressed and is over the MetroThumbContentControl. + + + + + An extended, metrofied Window class. + + + + + Identifies the dependency property. + + + + + Identifies the dependency property. + + + + + Identifies the dependency property. + + + + + Identifies the dependency property. + + + + + Allows easy handling of window commands brush. Theme is also applied based on this brush. + + + + + Gets/sets whether the window's entrance transition animation is enabled. + + + + + Gets/sets the FlyoutsControl that hosts the window's flyouts. + + + + + Gets/sets the icon content template to show a custom icon. + + + + + Gets/sets the title content template to show a custom title. + + + + + Gets/sets the left window commands that hosts the user commands. + + + + + Gets/sets the right window commands that hosts the user commands. + + + + + Gets/sets the window button commands that hosts the min/max/close commands. + + + + + Defines if the Taskbar should be ignored when maximizing a Window. + This only works with WindowStyle = None. + + + + + Identifies the dependency property. + + + + + Gets or sets resize border thickness. This enables animation, styling, binding, etc... + + + + + for . + + + + + Gets/sets if the border thickness value should be kept on maximize + if the MaxHeight/MaxWidth of the window is less than the monitor resolution. + + + + + for . + + + + + Gets or sets wether the resizing of the window should be tried in a way that does not cause flicker/jitter, especially when resizing from the left side. + + + Please note that setting this to true may cause resize lag and black areas appearing on some systems. + + + + + for . + + + + + Gets/sets the brush used for the titlebar's foreground. + + + + + Gets/sets whether the window will save it's position between loads. + + + + + Gets the window placement settings (can be overwritten). + + + + + Get/sets whether the titlebar icon is visible or not. + + + + + Get/sets whether dialogs show over the title bar. + + + + + Gets whether one or more dialogs are shown. + + + + + Gets/sets edge mode of the titlebar icon. + + + + + Gets/sets bitmap scaling mode of the titlebar icon. + + + + + Gets/sets icon scaling mode of the titlebar. + + + + + Gets/sets whether the TitleBar is visible or not. + + + + + Gets/sets whether the WindowStyle is None or not. + + + + + Gets or sets whether if the minimize button is visible and the minimize system menu is enabled. + + + + + Gets or sets whether if the maximize/restore button is visible and the maximize/restore system menu is enabled. + + + + + Gets or sets whether if the close button is visible. + + + + + Gets/sets if the min button is enabled. + + + + + Gets/sets if the max/restore button is enabled. + + + + + Gets/sets if the close button is enabled. + + + + + Gets or sets whether if the close button should be enabled or not if a dialog is shown. + + + + + Gets or sets a value that indicates whether the system menu should popup with left mouse click on the window icon. + + + + + Gets or sets a value that indicates whether the system menu should popup with right mouse click if the mouse position is on title bar or on the entire window if it has no title bar (and no title bar height). + + + + + Gets/sets the TitleBar's height. + + + + + Character casing of the title + + + + + Gets/sets the title horizontal alignment. + + + + + Gets/sets the brush used for the Window's title bar. + + + + + Gets/sets the brush used for the Window's glow. + + + + + Gets/sets the brush used for the Window's non-active glow. + + + + + Gets/sets the brush used for the Window's non-active border. + + + + + Gets/sets the brush used for the Window's non-active title bar. + + + + + Gets/sets the brush used for the dialog overlay. + + + + + Gets/sets the opacity used for the dialog overlay. + + + + + Gets or sets the brush used for the Flyouts overlay. + + + + + Gets or sets the overlay fade in storyboard. + + + + + Gets or sets the overlay fade out storyboard. + + + + + Begins to show the MetroWindow's overlay effect. + + A task representing the process. + + + + Begins to hide the MetroWindow's overlay effect. + + A task representing the process. + + + + Stores the given element, or the last focused element via FocusManager, for restoring the focus after closing a dialog. + + The element which will be focused again. + + + + Clears the stored element which would get the focus after closing a dialog. + + + + + Initializes a new instance of the pyRevitLabs.MahAppsMetro.Controls.MetroWindow class. + + + + + Initializes various behaviors for the window. + For example , and . + + + + + + + + Creates AutomationPeer () + + + + + Gets the template child with the given name. + + The interface type inheirted from DependencyObject. + The name of the template child. + + + + Gets the template child with the given name. + + The name of the template child. + + + + This class eats little children. + + + + + Sets the IsHitTestVisibleInChromeProperty to a MetroWindow template child + + The MetroWindow. + The name of the template child. + + + + + Sets the WindowChrome ResizeGripDirection to a MetroWindow template child. + + The MetroWindow. + The name of the template child. + The direction. + + + + Adapts the WindowCommands to the theme of the first opened, topmost && (top || right || left) flyout + + The MetroWindow + All the flyouts! Or flyouts that fall into the category described in the summary. + + + + For specifying where the navigation index is placed relative to the . + + + + + Index on left side + + + + + Index on right side + + + + + Index on top side + + + + + Index on bottom side + + + + + Index on left side over the item + + + + + Index on right side over the item + + + + + Index on top side over the item + + + + + Index on bottom side over the item + + + + + Enum NumericInput which indicates what input is allowed for NumericUpdDown. + + + + + Only numbers are allowed + + + + + Numbers with decimal point and allowed scientific input + + + + + All is allowed + + + + + Represents a Windows spin box (also known as an up-down control) that displays numeric values. + + + + Identifies the routed event. + + + + Add / Remove ValueIncrementedEvent handler + Event which will be fired from this NumericUpDown when its value was incremented. + + + + Identifies the routed event. + + + + Add / Remove ValueDecrementedEvent handler + Event which will be fired from this NumericUpDown when its value was decremented. + + + + Identifies the routed event. + + + + Add / Remove DelayChangedEvent handler + Event which will be fired from this NumericUpDown when its delay value has been changed. + + + + Identifies the routed event. + + + + Add / Remove MaximumReachedEvent handler + Event fired from this NumericUpDown when its value has reached the maximum value. + + + + Identifies the routed event. + + + + Add / Remove MinimumReachedEvent handler + Event fired from this NumericUpDown when its value has reached the minimum value. + + + + Identifies the routed event. + + + + Add / Remove ValueChangedEvent handler + Event which will be fired from this NumericUpDown when its value has been changed. + + + + Identifies the dependency property. + + + + Gets or sets the amount of time, in milliseconds, the NumericUpDown waits while the up/down button is pressed + before it starts increasing/decreasing the for the specified . + The value must be non-negative. + + + + Identifies the dependency property. + + + + Gets or sets the horizontal alignment of the contents inside the text box. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the value to be added to or subtracted from remains + always or if it will increase faster after pressing the up/down button/arrow some time. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the text can be changed by the use of the up or down buttons only. + + + + Identifies the dependency property. + + + + Gets or sets the formatting for the displaying + + + + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the user can use the arrow keys and to change the value. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the user can use the mouse wheel to change the value. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the user can enter text in the control. + + + + Identifies the dependency property. + + + + Gets or sets the value of the NumericUpDown. + + + + Identifies the dependency property. + + + + Minimum restricts the minimum value of the Value property. + + + + Identifies the dependency property. + + + + Maximum restricts the maximum value of the Value property. + + + + Identifies the dependency property. + + + + Gets or sets the interval value for increasing/decreasing the . + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the control must have the focus in order to change values using the mouse wheel. + + + If the value is true then the value changes when the mouse wheel is over the control.
+ If the value is false then the value changes only if the control has the focus.
+ If is set to "false" then this property has no effect. +
+
+ + Identifies the dependency property. + + + + The ButtonsAlignment property specifies horizontal alignment of the up/down buttons. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the up/down button of the control are visible. + + + If the value is false then the of the control can be changed only if one of the following cases is satisfied: + + + is true. + + + is true. + + + is true. + + + + + + Identifies the dependency property. + + + + Gets or sets the width of the up/down buttons. + + + + Identifies the dependency property. + + + + Gets or sets whether the up and down buttons will got the focus when using them. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the up/down buttons will be switched. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the value will be changed directly on every TextBox text changed input event or when using the Enter key. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating the culture to be used in string formatting and converting operations. + + + + Identifies the dependency property. + + + + Gets or sets which numeric input for this NumericUpDown is allowed. + + + + Identifies the dependency property. + + + + Gets or sets the decimal-point correction mode. The default is + + + + Identifies the dependency property. + + + + Indicates if the NumericUpDown should round the value to the nearest possible interval when the focus moves to another element. + + + + Identifies the dependency property. + + + + Gets or sets the parsing number style for the value from text to numeric value. + + + + + Called when this element or any below gets focus. + + + + + When overridden in a derived class, is invoked whenever application code or internal processes call + . + + + + + This method is invoked when the Delay property changes. + + The old value of the Delay property. + The new value of the Delay property. + + + + This method is invoked when the Speedup property changes. + + The old value of the Speedup property. + The new value of the Speedup property. + + + + This method is invoked when the Maximum property changes. + + The old value of the Maximum property. + The new value of the Maximum property. + + + + This method is invoked when the Minimum property changes. + + The old value of the Minimum property. + The new value of the Minimum property. + + + + Raises the routed event. + + + Old value of the property + + + New value of the property + + + + + Insertion of the proper decimal-point as part of the TextBox content + + The TextBox which will be used for the correction + The decimal correction mode. + The culture with the decimal-point information. + + Typical "async-void" pattern as "fire-and-forget" behavior. + + + + + Doesn't overlay Flyouts nor a hidden TitleBar. + + + + + Overlays opened controls. + + + + + Overlays a hidden TitleBar. + + + + + Based on Greg Schechter's Planerator + http://blogs.msdn.com/b/greg_schechter/archive/2007/10/26/enter-the-planerator-dead-simple-3d-in-wpf-with-a-stupid-name.aspx + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + An Enum representing different positions, such as Left or Right. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + This delegate must used by handlers of the RangeSelectionChangedEvent event. + + The current element along the event's route. + The event arguments containing additional information about the event. + Nothing. + + + + This RangeSelectionChangedEventArgs class contains old and new value when + RangeSelectionChanged is raised. + + + + + + + Return the old lower value. + + + + + Return the new lower value. + + + + + Return the old upper value. + + + + + Return the new upper value. + + + + + This is an instance constructor for the RangeSelectionChangedEventArgs class. + + The old lower property value + The new lower property value + The old upper property value + The new upper property value + + + + This is an instance constructor for the RoutedPropertyChangedEventArgs class. + It is constructed with a reference to the event being raised. + + The old lower property value + The new lower property value + The old upper property value + The new upper property value + RoutedEvent + + + + This method is used to perform the proper type casting in order to + call the type-safe RoutedPropertyChangedEventHandler delegate for the IsCheckedChangedEvent event. + + The handler to invoke. + The current object along the event's route. + Nothing. + + + + A slider control with the ability to select a range between two values. + + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the routed event. + + + Identifies the dependency property. + + + + Get/sets the end of the range selection. + + + + Identifies the dependency property. + + + + Get/sets the beginning of the range selection. + + + + Identifies the dependency property. + + + + Get/sets the minimum range that can be selected. + + + + Identifies the dependency property. + + + + Get/sets the minimal distance between two thumbs. + + + + Identifies the dependency property. + + + + Get/sets whether whole range will be moved when press on right/left/central part of control + + + + Identifies the dependency property. + + + + Get/sets whether possibility to make manipulations inside range with left/right mouse buttons + cotrol button + + + + Identifies the dependency property. + + + + Get/sets whether possibility to make manipulations inside range with left/right mouse buttons + cotrol button + + + + Identifies the dependency property. + + + + Gets or sets the orientation of the . + + + + Identifies the dependency property. + + + + Gets or sets the position of tick marks with respect to the of the . + + + A value that defines how to position the tick marks in a with respect to the slider bar. The default is . + + + + Identifies the dependency property. + + + + Gets or sets the interval between tick marks. + + + The distance between tick marks. The default is (1.0). + + + + Identifies the dependency property. + + + + Gets or sets the positions of the tick marks to display for a . + + A set of tick marks to display for a . The default is . + + + + Identifies the dependency property. + + + + Get or sets IsMoveToPoint feature which will enable/disable moving to exact point inside control when user clicked on it + Gets or sets a value that indicates whether the two of a moves immediately to the location of the mouse click that occurs while the mouse pointer pauses on the tracks. + + + + Identifies the dependency property. + + + + Gets or sets whether a tooltip that contains the current value of the displays when the is pressed. If a tooltip is displayed, this property also specifies the placement of the tooltip. + + + One of the values that determines where to display the tooltip with respect to the of the , or that specifies to not show a tooltip. The default is , which specifies that a tooltip is not displayed. + + + + Identifies the dependency property. + + + + Gets or sets the number of digits that are displayed to the right side of the decimal point for the of the in a tooltip. + + + The precision of the that displays in the tooltip, specified as the number of digits that appear to the right of the decimal point. The default is zero (0). + + + + Identifies the dependency property. + + + + Gets or sets a template for the auto tooltip to show the lower value. + + + + Identifies the dependency property. + + + + Gets or sets a template for the auto tooltip to show the upper value. + + + + Identifies the dependency property. + + + + Gets or sets a template for the auto tooltip to show the center value. + + + + Identifies the dependency property. + + + + Get/sets value how fast thumbs will move when user press on left/right/central with left mouse button (IsMoveToPoint must be set to FALSE) + + + + Identifies the dependency property. + + + + Gets or sets a value that indicates whether the displays a selection range along the . + + + if a selection range is displayed; otherwise, . The default is . + + + + Identifies the dependency property. + + + + Gets or sets the smallest value of a specified selection for a . + + + The largest value of a selected range of values of a . The default is zero (0.0). + + + + Identifies the dependency property. + + + + Gets or sets the largest value of a specified selection for a . + + + The largest value of a selected range of values of a . The default is zero (0.0). + + + + + Responds to a change in the value of the property. + + The old value of the property.The new value of the property. + + + + Responds to a change in the value of the property. + + The old value of the property.The new value of the property. + + + + Gets the lower value of the range selection. + + + + + Gets the upper value of the range selection. + + + + + + + + RevealImage + + + + + InitializeComponent + + + + Identifies the routed event. + + + Identifies the dependency property. + + + + Gets or sets an extra tag. + + + + Identifies the dependency property. + + + + Gets or sets the orientation of children stacking. + + + + Identifies the dependency property. + + + + Gets or sets the content for the icon part. + + + + Identifies the dependency property. + + + + Gets or sets the DataTemplate for the icon part. + + + + Identifies the dependency property. + + + + Gets or sets the command to invoke when the content button is pressed. + + + + Identifies the dependency property. + + + + Gets or sets the element on which to raise the specified command. + + + + Identifies the dependency property. + + + + Gets or sets the parameter to pass to the command property. + + + + Identifies the dependency property. + + + + Gets or sets the button content style. + + + + Identifies the dependency property. + + + + Gets or sets the button arrow style. + + + + Identifies the dependency property. + + + + Gets or sets the foreground brush for the button arrow icon. + + + + Identifies the dependency property. + + + + Gets or sets the foreground brush of the button arrow icon if the mouse is over the split button. + + + + Identifies the dependency property. + + + + Gets or sets the foreground brush of the button arrow icon if the arrow button is pressed. + + + + + + + + A special animation used to animates the length of a . + + + + + + + Represents a container with two views; one view for the main content and another view that is typically used for + navigation commands. + + + + Identifies the dependency property. + + + + Gets or sets the width of the pane in its compact display mode. + + + The width of the pane in it's compact display mode. The default is 48 device-independent pixel (DIP) (defined + by the SplitViewCompactPaneThemeLength resource). + + + + Identifies the dependency property. + + + + Gets or sets the contents of the main panel of a . + + The contents of the main panel of a . The default is null. + + + Identifies the dependency property. + + + + Gets of sets a value that specifies how the pane and content areas of a are shown. + + + A value of the enumeration that specifies how the pane and content areas of a are + shown. The default is . + + + + Identifies the dependency property. + + + + Gets or sets a value that specifies whether the pane is expanded to its full width. + + true if the pane is expanded to its full width; otherwise, false. The default is true. + + + Identifies the dependency property. + + + + Gets or sets a value that specifies the OverlayBrush + + The current OverlayBrush + + + Identifies the dependency property. + + + + Gets or sets the width of the pane when it's fully expanded. + + + The width of the pane when it's fully expanded. The default is 320 device-independent + pixel (DIP). + + + + Identifies the dependency property. + + + + Gets or sets the minimum width of the pane when it's fully expanded. + + + The minimum width of the pane when it's fully expanded. The default is 320 device-independent + pixel (DIP). + + + + Identifies the dependency property. + + + + Gets or sets the maximum width of the pane when it's fully expanded. + + + The maximum width of the pane when it's fully expanded. The default is 320 device-independent + pixel (DIP). + + + + Identifies the dependency property. + + + + Gets or Sets if the open pane can be resized by the user. The default value is false. + + + + Identifies the dependency property. + + + + Gets or Sets the for the resizing Thumb (type of ) + + + + Identifies the dependency property. + + + + Gets or sets the contents of the pane of a . + + The contents of the pane of a . The default is null. + + + Identifies the dependency property. + + + + Gets or sets the Brush to apply to the background of the area of the control. + + The Brush to apply to the background of the area of the control. + + + Identifies the dependency property. + + + + Gets or sets the Brush to apply to the foreground of the area of the control. + + The Brush to apply to the background of the area of the control. + + + Identifies the dependency property. + + + + Gets or sets a value that specifies whether the pane is shown on the right or left side of the + . + + + A value of the enumeration that specifies whether the pane is shown on the right or left side of the + . The default is . + + + + Identifies the dependency property. + + + + Gets an object that provides calculated values that can be referenced as TemplateBinding sources when defining + templates for a control. + + An object that provides calculated values for templates. + + + + Initializes a new instance of the class. + + + + + Occurs when the pane is closed. + + + + + Occurs when the pane is closing. + + + + + + + + + + + + + + Constants that specify how the pane is shown in a . + + + + + The pane covers the content when it's open and does not take up space in the control layout. + + + + + The pane is shown side-by-side with the content and takes up space in the control layout. + + + + + The amount of the pane defined by the property is shown side-by-side + with the content and takes up space in the control layout. + The remaining part of the pane covers the content when it's open and does not take up space in the control layout. + + + + + The amount of the pane defined by the property is shown side-by-side + with the content and takes up space in the control layout. + The remaining part of the pane pushes the content to the side when it's open and takes up space in the control + layout. + + + + + Provides event data for the event. + + + + + Gets or sets a value that indicates whether the pane closing action should be canceled. + + true to cancel the pane closing action; otherwise, false. + + + + Constants that specify whether the pane is set to the left or to the right of the content in a + . + + + + + The pane is shown to the left of the content. + + + + + The pane is shown to the right of the content. + + + + + Provides calculated values that can be referenced as TemplatedParent sources when defining templates for a + . + Not intended for general use. + + + + Identifies the dependency property. + + + + Gets the value as a GridLength. + + + + Identifies the dependency property. + + + + Gets the negative of the value. + + + + Identifies the dependency property. + + + + Gets the negative of the value calculated by subtracting the value from + the value. + + + + Identifies the dependency property. + + + + Gets the value as a GridLength. + + + + Identifies the dependency property. + + + + Gets the value. + + + + Identifies the dependency property. + + + + Gets a value calculated by subtracting the value from the + value. + + + + + HorizontalTitleAlignment Dependency Property. + Default Value: HorizontalAlignment.Left + + + + + Gets/Sets the horizontal alignment of the title. + + + + + VerticalTitleAlignment Dependency Property. + Default Value: VerticalAlignment.Bottom + + + + + Gets/Sets the vertical alignment of the title. + + + + + Represents a control that allows the user to select a date and a time. + + + + Identifies the dependency property. + + + + Gets or sets the last date to be displayed. + + The last date to display. + + + Identifies the dependency property. + + + + Gets or sets the date to display + + + The date to display. The default is . + + + + Identifies the dependency property. + + + + Gets or sets the first date to be displayed. + + The first date to display. + + + Identifies the dependency property. + + + + Gets or sets the day that is considered the beginning of the week. + + + A that represents the beginning of the week. The default is the + that is determined by the current culture. + + + + Identifies the dependency property. + + + + Gets or sets a value that indicates whether the current date will be highlighted. + + true if the current date is highlighted; otherwise, false. The default is true. + + + Identifies the dependency property. + + + + Gets or sets the format that is used to display the selected date. + + + + Identifies the dependency property. + + + + Gets or sets a value that indicates the dimension by which calendar and clock are stacked. + + + The of the calendar and clock. The default is + . + + + + Identifies the dependency property. + + + + Gets or sets the style that is used when rendering the calendar. + + + + + Gets the days that are not selectable. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Defines the visibility for time-parts that are visible for the . + + + + + Represents a control that allows the user to select a time. + + + + + + + + + + + Represents a base-class for time picking. + + + + + This list contains values from 0 to 55 with an interval of 5. It can be used to bind to and . + + + <MahApps:TimePicker SourceSeconds="{x:Static MahApps:TimePickerBase.IntervalOf5}" /> + <MahApps:DateTimePicker SourceSeconds="{x:Static MahApps:TimePickerBase.IntervalOf5}" /> + + + Returns a list containing {0, 5, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55}. + + + + + This list contains values from 0 to 50 with an interval of 10. It can be used to bind to and . + + + <MahApps:TimePicker SourceSeconds="{x:Static MahApps:TimePickerBase.IntervalOf10}" /> + <MahApps:DateTimePicker SourceSeconds="{x:Static MahApps:TimePickerBase.IntervalOf10}" /> + + + Returns a list containing {0, 10, 20, 30, 40, 50}. + + + + + This list contains values from 0 to 45 with an interval of 15. It can be used to bind to and . + + + <MahApps:TimePicker SourceSeconds="{x:Static MahApps:TimePickerBase.IntervalOf15}" /> + <MahApps:DateTimePicker SourceSeconds="{x:Static MahApps:TimePickerBase.IntervalOf15}" /> + + + Returns a list containing {0, 15, 30, 45}. + + + + Identifies the dependency property. + + + + Gets or sets a collection used to generate the content for selecting the hours. + + + A collection that is used to generate the content for selecting the hours. The default is a list of interger from 0 + to 23 if is false or a list of interger from + 1 to 12 otherwise.. + + + + Identifies the dependency property. + + + + Gets or sets a collection used to generate the content for selecting the minutes. + + + A collection that is used to generate the content for selecting the minutes. The default is a list of int from + 0 to 59. + + + + Identifies the dependency property. + + + + Gets or sets a collection used to generate the content for selecting the seconds. + + + A collection that is used to generate the content for selecting the minutes. The default is a list of int from + 0 to 59. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the drop-down for a box is currently + open. + + true if the drop-down is open; otherwise, false. The default is false. + + + + IsDropDownOpenProperty property changed handler. + + DatePicker that changed its IsDropDownOpen. + DependencyPropertyChangedEventArgs. + + + + This method is invoked when the changes. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the clock of this control is visible in the user interface (UI). This is a + dependency property. + + + If this value is set to false then is set to + + + + true if the clock is visible; otherwise, false. The default value is true. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the contents of the are not editable. + + + true if the is read-only; otherwise, false. The default is false. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating the visibility of the clock hands in the user interface (UI). + + + The visibility definition of the clock hands. The default is . + + + + Identifies the dependency property. + + + + Gets or sets a value indicating the culture to be used in string formatting operations. + + + + Identifies the dependency property. + + + + Gets or sets a value indicating the visibility of the selectable date-time-parts in the user interface (UI). + + + visibility definition of the selectable date-time-parts. The default is . + + + + + Occurs when the property is changed. + + + + Identifies the dependency property. + + + + Gets or sets the currently selected date and time. + + + The date and time which is currently selected. The default is null. + + + + Identifies the dependency property. + + + + Gets or sets the format that is used to display the selected time. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the hour items. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the minute items. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the second items. + + + + + This readonly dependency property is to control whether to show the date-picker (in case of ) or hide it (in case of . + + + + Identifies the dependency property. + + + + Gets or sets a value indicating whether the date can be selected or not. This property is read-only. + + + + + Gets a value indicating whether the that is specified by the + + set by the ( if null) has not a value. + + + + + When overridden in a derived class, is invoked whenever application code or internal processes call + . + + + + + Gets the offset from the selected to use it in as hour + parameter. + + The current hour. + + An integer representing the offset to add to the hour that is selected in the hour-picker for setting the correct + . The offset is determined as follows: + + + ConditionOffset + + + is false0 + + + Selected hour is between 1 AM and 11 AM0 + + + Selected hour is 12 AM-12h + + + Selected hour is between 12 PM and 11 PM+12h + + + + + + + A control that allows the user to toggle between two states: One represents true; The other represents false. + + + + Identifies the dependency property. + + + + Gets or sets the flow direction of the switch and content. + + + LeftToRight means content left and button right and RightToLeft vise versa. + + + + Identifies the dependency property. + + + + Gets or sets the padding of the inner content. + + + + Identifies the dependency property. + + + + Gets or sets a value that declares whether the state of the ToggleSwitch is "On". + + + + Identifies the dependency property. + + + + Provides the object content that should be displayed using the OnContentTemplate when this ToggleSwitch has state of "On". + + + + Identifies the dependency property. + + + + Gets or sets the DataTemplate used to display the control's content while in "On" state. + + + + Identifies the dependency property. + + + + Gets or sets a template selector for OnContent property that enables an application writer to provide custom template-selection logic . + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the OnContent property if it is displayed as a string. + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + + Provides the object content that should be displayed using the OffContentTemplate when this ToggleSwitch has state of "Off". + + + + Identifies the dependency property. + + + + Gets or sets the DataTemplate used to display the control's content while in "Off" state. + + + + Identifies the dependency property. + + + + Gets or sets a template selector for OffContent property that enables an application writer to provide custom template-selection logic . + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + + Gets or sets a composite string that specifies how to format the OffContent property if it is displayed as a string. + + + This property is ignored if is set. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets or sets a command which will be executed when the changes. + + + + Identifies the dependency property. + + + + Gets or sets a command which will be executed when the changes. + + + + Identifies the dependency property. + + + + Gets or sets a command which will be executed when the changes. + + + + Identifies the dependency property. + + + + Gets or sets the command parameter which will be passed by the Command. + + + + Identifies the dependency property. + + + + Gets or sets the element on which to raise the specified Command. + + + Element on which to raise the Command. + + + + + Occurs when "On"/"Off" state changes for this ToggleSwitch. + + + + This method is invoked when the changes. + + + + + + + enumeration for the different transition types + + + + + Use the VisualState DefaultTransition + + + + + Use the VisualState Normal + + + + + Use the VisualState UpTransition + + + + + Use the VisualState DownTransition + + + + + Use the VisualState RightTransition + + + + + Use the VisualState RightReplaceTransition + + + + + Use the VisualState LeftTransition + + + + + Use the VisualState LeftReplaceTransition + + + + + Use a custom VisualState, the name must be set using CustomVisualStatesName property + + + + + A ContentControl that animates content as it loads and unloads. + + + + + Gets or sets the name of the custom transition visual state. + + + + + Gets/sets if the content is transitioning. + + + + + Reload the current transition if the content is the same. + + + + + Helper methods for UI-related tasks. + This class was obtained from Philip Sumi (a fellow WPF Disciples blog) + http://www.hardcodet.net/uploads/2009/06/UIHelper.cs + + + + + Finds a parent of a given item on the visual tree. + + The type of the queried item. + A direct or indirect child of the + queried item. + The first parent item that matches the submitted + type parameter. If not matching item can be found, a null + reference is being returned. + + + + Finds all Ancestors of a given item on the visual tree. + + A node in a visual tree + All ancestors in visual tree of element + + + + Returns full visual ancestry, starting at the leaf. + If element is not of or the logical ancestry is used. + + The starting object. + + + + + Tries to find and returns a visual ancestor, starting at the leaf. + If element is not of or the logical ancestry is used. + + The starting object. + + + + + Finds a Child of a given item in the visual tree. + + A direct parent of the queried item. + The type of the queried item. + x:Name or Name of child. + The first parent item that matches the submitted type parameter. + If not matching item can be found, + a null parent is being returned. + + + + This method is an alternative to WPF's + method, which also supports content elements. Keep in mind that for content element, + this method falls back to the logical tree of the element! + + The item to be processed. + The submitted item's parent, if available. Otherwise + null. + + + + Analyzes both visual and logical tree in order to find all elements of a given + type that are descendants of the item. + + The type of the queried items. + The root element that marks the source of the search. If the + source is already of the requested type, it will not be included in the result. + Sometimes it's better to search in the VisualTree (e.g. in tests) + All descendants of that match the requested type. + + + + This method is an alternative to WPF's + method, which also + supports content elements. Keep in mind that for content elements, + this method falls back to the logical tree of the element. + + The item to be processed. + Sometimes it's better to search in the VisualTree (e.g. in tests) + The submitted item's child elements, if available. + + + + Tries to locate a given item within the visual tree, + starting with the dependency object at a given position. + + The type of the element to be found + on the visual tree of the element at the given location. + The main element which is used to perform + hit testing. + The position to be evaluated on the origin. + + + + Get the working area size of the monitor from where the visual stays. + + The visual element to get the monitor information. + The working area size of the monitor. + + + Gets the text associated with the given window handle. + The window to act on. + The window text. + + + Gets the text associated with the given window handle. + The window to act on. + The window text. + + + Identifies the dependency property. + + + + Gets or sets the value indicating current light style for the minimize button. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating current light style for the maximize button. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating current light style for the close button. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating current dark style for the minimize button. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating current dark style for the maximize button. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating current dark style for the close button. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating current theme. + + + + Identifies the dependency property. + + + + Gets or sets the minimize button tooltip. + + + + Identifies the dependency property. + + + + Gets or sets the maximize button tooltip. + + + + Identifies the dependency property. + + + + Gets or sets the close button tooltip. + + + + Identifies the dependency property. + + + + Gets or sets the restore button tooltip. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets the window. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating the current theme. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating the light theme ControlTemplate. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating the light theme ControlTemplate. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating whether to show the separators or not. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating whether to show the last separator or not. + + + + Identifies the dependency property. + + + + Gets or sets the value indicating the height of the separators. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + Gets the window. + + + + + Creates AutomationPeer () + + + + Identifies the dependency property. + + + + Gets or sets the value indicating whether to show the separator. + + + + Identifies the dependency property. + + + Identifies the dependency property. + + + + + + + Doesn't overlay a hidden TitleBar. + + + + + Overlays a hidden TitleBar. + + + + + Refreshes the application settings property values from persistent storage. + + + + + Upgrades the application settings on loading. + + + + + Updates application settings to reflect a more recent installation of the application. + + + + + Stores the current values of the settings properties. + + + + + this settings class is the default way to save the placement of the window + + + + + Upgrades the application settings on loading. + + + + + Determining Ideal Text Color Based on Specified Background Color + http://www.codeproject.com/KB/GDI-plus/IdealTextColor.aspx + + The bg. + + + + + Converts a double representing either hour/minute/second to the corresponding angle. + + + + + Channel type for ColorChannelMinMaxConverter to pass in in as parameter. + + + + + Converts a given Color to a new Color with the specified Channel turned to the Min or Max Value + + + + Gets the default instance + + + + Converts a given to its Name + + Needed: The . + + Optional: A + + The name of the color or the Hex-Code if no name is available + + + + Converts a given to its Name + + Needed: The . Optional: A + + + + The name of the color or the Hex-Code if no name is available + + + + Converts a given back to a + + The name of the + + Optional: A + + + + + + The ConvertBack-Method is not available inside a . Use a with the optional instead. + + + + + + + + + + + Converts a given into a . + + + + + Gets a static instance of the converter if needed. + + + + + Gets or Sets the brush which will be used if the conversion fails. + + + + + Gets or Sets the color which will be used if the conversion fails. + + + + + Converts a CornerRadius to a new CornerRadius. It's possible to ignore a side with the IgnoreRadius property. + + + + + Filters a CornerRadius by the given Filter property. Result can be a new CornerRadius or a value of it's 4 corners. + + + + Gets the default instance + + + + Converts a given Color to a new Color with the specified Channel turned to the Min or Max Value + + + + Gets the default instance + + + + Converts the value from true to false and false to true. + + + + + The math operations which can be used at the + + + + + MathConverter provides a value converter which can be used for math operations. + It can be used for normal binding or multi binding as well. + If it is used for normal binding the given parameter will be used as operands with the selected operation. + If it is used for multi binding then the first and second binding will be used as operands with the selected operation. + This class cannot be inherited. + + + + + MathAddConverter provides a multi value converter as a MarkupExtension which can be used for math operations. + This class cannot be inherited. + + + + + MathSubtractConverter provides a multi value converter as a MarkupExtension which can be used for math operations. + This class cannot be inherited. + + + + + MathMultiplyConverter provides a multi value converter as a MarkupExtension which can be used for math operations. + This class cannot be inherited. + + + + + MathDivideConverter provides a multi value converter as a MarkupExtension which can be used for math operations. + This class cannot be inherited. + + + + Gets the default instance + + + + Use the radius of all corners. + + + + + Ignore the radius of the top-left and bottom-left corner. + + + + + Ignore the radius of the top-left and top-right corner. + + + + + Ignore the radius of the top-right and bottom-right corner. + + + + + Ignore the radius of the bottom-left and bottom-right corner. + + + + + Ignore the radius of the top-left corner. + + + + + Ignore radius of the top-right corner. + + + + + Ignore the radius of the bottom-right corner. + + + + + Ignore the radius of the bottom-left corner. + + + + + This Converter converts a given height or width of an control to a CornerRadius + + + + + Converts a String into a Visibility enumeration (and back) + The FalseEquivalent can be declared with the "FalseEquivalent" property + + + + + Initialize the properties with standard values + + + + + FalseEquivalent (default : Visibility.Collapsed => see Constructor) + + + + + Define whether the opposite boolean value is crucial (default : false) + + + + + Converts a Thickness to a new Thickness. It's possible to ignore a side with the IgnoreThicknessSide property. + + + + + Use all sides. + + + + + Ignore the left side. + + + + + Ignore the top side. + + + + + Ignore the right side. + + + + + Ignore the bottom side. + + + + Converts a value. + A converted value. If the method returns null, the valid null value is used. + The value produced by the binding source. + The type of the binding target property. + The converter parameter to use. + The culture to use in the converter. + + + Converts a value. + A converted value. If the method returns null, the valid null value is used. + The value that is produced by the binding target. + The type to convert to. + The converter parameter to use. + The culture to use in the converter. + + + + A strongly-typed resource class, for looking up localized strings, etc. + + + + + Returns the cached ResourceManager instance used by this class. + + + + + Overrides the current thread's CurrentUICulture property for all + resource lookups using this strongly typed resource class. + + + + + Implements a markup extension that supports static (XAML load time) resource references made from XAML. + + + + + Provides theme resources from pyRevitLabs.MahAppsMetro. + + + + + + + + Helps boxing Boolean values. + + + + + Gets a boxed representation for Boolean's "true" value. + + + + + Gets a boxed representation for Boolean's "false" value. + + + + + Returns a boxed representation for the specified Boolean value. + + The value to box. + + + + + GeneratedInternalTypeHelper + + + + + CreateInstance + + + + + GetPropertyValue + + + + + SetPropertyValue + + + + + CreateDelegate + + + + + AddEventHandler + + +
+
diff --git a/dev/libs/pyRevitLabs.NLog.dll b/dev/libs/netfx/pyRevitLabs.NLog.dll similarity index 100% rename from dev/libs/pyRevitLabs.NLog.dll rename to dev/libs/netfx/pyRevitLabs.NLog.dll diff --git a/dev/libs/pyRevitLabs.NLog.xml b/dev/libs/netfx/pyRevitLabs.NLog.xml similarity index 100% rename from dev/libs/pyRevitLabs.NLog.xml rename to dev/libs/netfx/pyRevitLabs.NLog.xml diff --git a/dev/libs/pyrevit-stubsbuilder.exe b/dev/libs/netfx/pyrevit-stubsbuilder.exe similarity index 100% rename from dev/libs/pyrevit-stubsbuilder.exe rename to dev/libs/netfx/pyrevit-stubsbuilder.exe diff --git a/dev/libs/pyrevit-toast.exe b/dev/libs/netfx/pyrevit-toast.exe similarity index 100% rename from dev/libs/pyrevit-toast.exe rename to dev/libs/netfx/pyrevit-toast.exe diff --git a/dev/libs/rhino3dmio_native.dll b/dev/libs/netfx/rhino3dmio_native.dll similarity index 100% rename from dev/libs/rhino3dmio_native.dll rename to dev/libs/netfx/rhino3dmio_native.dll diff --git a/dev/modules/pyRevitLabs.MahApps.Metro b/dev/modules/pyRevitLabs.MahApps.Metro index c08a42575..721f7f1ba 160000 --- a/dev/modules/pyRevitLabs.MahApps.Metro +++ b/dev/modules/pyRevitLabs.MahApps.Metro @@ -1 +1 @@ -Subproject commit c08a42575e079085666643d7cae070963799f09b +Subproject commit 721f7f1ba64a22516171791dfce043bed0e729b6 diff --git a/dev/modules/pyRevitLabs.NLog b/dev/modules/pyRevitLabs.NLog index 6394d99d8..ceb524ee4 160000 --- a/dev/modules/pyRevitLabs.NLog +++ b/dev/modules/pyRevitLabs.NLog @@ -1 +1 @@ -Subproject commit 6394d99d8ff15cd87950cda8b2c4d1f36ec2b0f6 +Subproject commit ceb524ee46cf1757cf0da99175b5229d80b67182 diff --git a/dev/modules/pyRevitLabs.Newtonsoft.Json b/dev/modules/pyRevitLabs.Newtonsoft.Json index 91d0c9775..8d029da84 160000 --- a/dev/modules/pyRevitLabs.Newtonsoft.Json +++ b/dev/modules/pyRevitLabs.Newtonsoft.Json @@ -1 +1 @@ -Subproject commit 91d0c977592415326463fc6ec7d1108a20a9657c +Subproject commit 8d029da84d0846992a6118309e73d07d8d6f7ea9 diff --git a/dev/modules/pyRevitLabs.Python.Net b/dev/modules/pyRevitLabs.Python.Net index bbc74f2fc..dfa2affd0 160000 --- a/dev/modules/pyRevitLabs.Python.Net +++ b/dev/modules/pyRevitLabs.Python.Net @@ -1 +1 @@ -Subproject commit bbc74f2fcd64a6fc6d261aca9d9826f0b3acfe50 +Subproject commit dfa2affd0c0ee77fb7ecbbe48270098772904745 diff --git a/dev/modules/pyRevitLabs.Python.Net.sln b/dev/modules/pyRevitLabs.Python.Net.sln index 519d13d1a..ed2c2b4be 100644 --- a/dev/modules/pyRevitLabs.Python.Net.sln +++ b/dev/modules/pyRevitLabs.Python.Net.sln @@ -8,16 +8,13 @@ EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU - ReleasePY37|Any CPU = ReleasePY37|Any CPU - ReleasePY38|Any CPU = ReleasePY38|Any CPU + Release|Any CPU = Release|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution {12A1F593-296C-4BAF-BC61-6065ED8D09C3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {12A1F593-296C-4BAF-BC61-6065ED8D09C3}.Debug|Any CPU.Build.0 = Debug|Any CPU - {12A1F593-296C-4BAF-BC61-6065ED8D09C3}.ReleasePY37|Any CPU.ActiveCfg = ReleasePY37|Any CPU - {12A1F593-296C-4BAF-BC61-6065ED8D09C3}.ReleasePY37|Any CPU.Build.0 = ReleasePY37|Any CPU - {12A1F593-296C-4BAF-BC61-6065ED8D09C3}.ReleasePY38|Any CPU.ActiveCfg = ReleasePY38|Any CPU - {12A1F593-296C-4BAF-BC61-6065ED8D09C3}.ReleasePY38|Any CPU.Build.0 = ReleasePY38|Any CPU + {12A1F593-296C-4BAF-BC61-6065ED8D09C3}.Release|Any CPU.ActiveCfg = Release|Any CPU + {12A1F593-296C-4BAF-BC61-6065ED8D09C3}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/dev/modules/pyRevitLabs.dlr b/dev/modules/pyRevitLabs.dlr index 42f4eb417..eb8f2ca22 160000 --- a/dev/modules/pyRevitLabs.dlr +++ b/dev/modules/pyRevitLabs.dlr @@ -1 +1 @@ -Subproject commit 42f4eb4175e13476f3befc7c071c92e3fef8fe69 +Subproject commit eb8f2ca2215fe269b3b8d8e3c9f466a8d93a3ccd diff --git a/dev/modules/pyRevitLabs.dlr3 b/dev/modules/pyRevitLabs.dlr3 index 2bf8d881d..eb8f2ca22 160000 --- a/dev/modules/pyRevitLabs.dlr3 +++ b/dev/modules/pyRevitLabs.dlr3 @@ -1 +1 @@ -Subproject commit 2bf8d881def235265a9c4a1b541e56347cf29819 +Subproject commit eb8f2ca2215fe269b3b8d8e3c9f466a8d93a3ccd diff --git a/dev/modules/pyRevitLabs.ironpython2 b/dev/modules/pyRevitLabs.ironpython2 index 982510bfc..870a670f1 160000 --- a/dev/modules/pyRevitLabs.ironpython2 +++ b/dev/modules/pyRevitLabs.ironpython2 @@ -1 +1 @@ -Subproject commit 982510bfcee30e98b4129498174a992f04b38adc +Subproject commit 870a670f1a4bff4b01a77a6e32045a817f8585c9 diff --git a/dev/modules/pyRevitLabs.ironpython3 b/dev/modules/pyRevitLabs.ironpython3 index e26ab90fc..629d16179 160000 --- a/dev/modules/pyRevitLabs.ironpython3 +++ b/dev/modules/pyRevitLabs.ironpython3 @@ -1 +1 @@ -Subproject commit e26ab90fc13b856f394b796a7161782319410f01 +Subproject commit 629d161795fcac9a6da1022ef3fa0bb5f45f9a30 diff --git a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2017.csproj b/dev/pyRevitLabs.PyRevit.Runtime/2017/pyRevitLabs.PyRevit.Runtime.2017.csproj similarity index 55% rename from dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2017.csproj rename to dev/pyRevitLabs.PyRevit.Runtime/2017/pyRevitLabs.PyRevit.Runtime.2017.csproj index 9af37acb3..3dd2c3a4f 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2017.csproj +++ b/dev/pyRevitLabs.PyRevit.Runtime/2017/pyRevitLabs.PyRevit.Runtime.2017.csproj @@ -1,9 +1,6 @@  2017 - - - - $(DefineConstants) + net48 \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2018.csproj b/dev/pyRevitLabs.PyRevit.Runtime/2018/pyRevitLabs.PyRevit.Runtime.2018.csproj similarity index 55% rename from dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2018.csproj rename to dev/pyRevitLabs.PyRevit.Runtime/2018/pyRevitLabs.PyRevit.Runtime.2018.csproj index 06d5c8d87..4cb4fc136 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2018.csproj +++ b/dev/pyRevitLabs.PyRevit.Runtime/2018/pyRevitLabs.PyRevit.Runtime.2018.csproj @@ -1,9 +1,6 @@  2018 - - - - $(DefineConstants) + net48 \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2019.csproj b/dev/pyRevitLabs.PyRevit.Runtime/2019/pyRevitLabs.PyRevit.Runtime.2019.csproj similarity index 55% rename from dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2019.csproj rename to dev/pyRevitLabs.PyRevit.Runtime/2019/pyRevitLabs.PyRevit.Runtime.2019.csproj index cf35c4336..6a76459ca 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2019.csproj +++ b/dev/pyRevitLabs.PyRevit.Runtime/2019/pyRevitLabs.PyRevit.Runtime.2019.csproj @@ -1,9 +1,6 @@  2019 - - - - $(DefineConstants) + net48 \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2020.csproj b/dev/pyRevitLabs.PyRevit.Runtime/2020/pyRevitLabs.PyRevit.Runtime.2020.csproj similarity index 55% rename from dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2020.csproj rename to dev/pyRevitLabs.PyRevit.Runtime/2020/pyRevitLabs.PyRevit.Runtime.2020.csproj index 360a4c8c1..7531724fe 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2020.csproj +++ b/dev/pyRevitLabs.PyRevit.Runtime/2020/pyRevitLabs.PyRevit.Runtime.2020.csproj @@ -1,9 +1,6 @@  2020 - - - - $(DefineConstants) + net48 \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2021.csproj b/dev/pyRevitLabs.PyRevit.Runtime/2021/pyRevitLabs.PyRevit.Runtime.2021.csproj similarity index 55% rename from dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2021.csproj rename to dev/pyRevitLabs.PyRevit.Runtime/2021/pyRevitLabs.PyRevit.Runtime.2021.csproj index 43015bacf..6ccfde595 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2021.csproj +++ b/dev/pyRevitLabs.PyRevit.Runtime/2021/pyRevitLabs.PyRevit.Runtime.2021.csproj @@ -1,9 +1,6 @@  2021 - - - - $(DefineConstants) + net48 \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2022.csproj b/dev/pyRevitLabs.PyRevit.Runtime/2022/pyRevitLabs.PyRevit.Runtime.2022.csproj similarity index 55% rename from dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2022.csproj rename to dev/pyRevitLabs.PyRevit.Runtime/2022/pyRevitLabs.PyRevit.Runtime.2022.csproj index d27c4ea30..dd040ed3e 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2022.csproj +++ b/dev/pyRevitLabs.PyRevit.Runtime/2022/pyRevitLabs.PyRevit.Runtime.2022.csproj @@ -1,9 +1,6 @@ 2022 - - - - $(DefineConstants) + net48 \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2023.csproj b/dev/pyRevitLabs.PyRevit.Runtime/2023/pyRevitLabs.PyRevit.Runtime.2023.csproj similarity index 55% rename from dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2023.csproj rename to dev/pyRevitLabs.PyRevit.Runtime/2023/pyRevitLabs.PyRevit.Runtime.2023.csproj index c7799f3ec..6e77a4d59 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2023.csproj +++ b/dev/pyRevitLabs.PyRevit.Runtime/2023/pyRevitLabs.PyRevit.Runtime.2023.csproj @@ -1,9 +1,6 @@ 2023 - - - - $(DefineConstants) + net48 \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2024.csproj b/dev/pyRevitLabs.PyRevit.Runtime/2024/pyRevitLabs.PyRevit.Runtime.2024.csproj similarity index 55% rename from dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2024.csproj rename to dev/pyRevitLabs.PyRevit.Runtime/2024/pyRevitLabs.PyRevit.Runtime.2024.csproj index e4f3e09e7..b32991465 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.2024.csproj +++ b/dev/pyRevitLabs.PyRevit.Runtime/2024/pyRevitLabs.PyRevit.Runtime.2024.csproj @@ -1,9 +1,6 @@ 2024 - - - - $(DefineConstants) + net48 \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/2025/pyRevitLabs.PyRevit.Runtime.2025.csproj b/dev/pyRevitLabs.PyRevit.Runtime/2025/pyRevitLabs.PyRevit.Runtime.2025.csproj new file mode 100644 index 000000000..970fe3030 --- /dev/null +++ b/dev/pyRevitLabs.PyRevit.Runtime/2025/pyRevitLabs.PyRevit.Runtime.2025.csproj @@ -0,0 +1,11 @@ + + + true + true + + + + 2025 + net8.0-windows + + \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/CLREngine.cs b/dev/pyRevitLabs.PyRevit.Runtime/CLREngine.cs deleted file mode 100644 index 70bbe9df1..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/CLREngine.cs +++ /dev/null @@ -1,407 +0,0 @@ -using System; -using System.IO; -using System.Linq; -using System.Collections.Generic; - -using System.Reflection; -using Autodesk.Revit.UI; - -// csharp uses roslyn compiler in -using pyRevitLabs.Common; -using pyRevitLabs.Common.Extensions; -using pyRevitLabs.NLog; -using pyRevitLabs.NLog.Config; -using pyRevitLabs.NLog.Targets; -using SHARED = pyRevitLabs.PyRevit.Runtime.Shared; - -namespace PyRevitLabs.PyRevit.Runtime -{ - public class ExecParams - { - public string ExecId { get; set; } - public string ExecTimeStamp { get; set; } - public string ScriptPath { get; set; } - public string ConfigScriptPath { get; set; } - public string CommandUniqueId { get; set; } - public string CommandControlId { get; set; } - public string CommandName { get; set; } - public string CommandBundle { get; set; } - public string CommandExtension { get; set; } - public string HelpSource { get; set; } - public bool RefreshEngine { get; set; } - public bool ConfigMode { get; set; } - public bool DebugMode { get; set; } - public bool ExecutedFromUI { get; set; } - public Autodesk.Windows.RibbonItem UIButton { get; set; } - } - - public class CLREngineOutputTarget : TargetWithLayout - { - public SHARED.ExecParams CurrentExecParams { get; set; } - - protected override void Write(LogEventInfo logEvent) - { - try - { - var message = Layout.Render(logEvent); - if (logEvent.Level == LogLevel.Debug) - { - if (CurrentExecParams.DebugMode) - Console.WriteLine(message); - } - else - Console.WriteLine(message); - } - catch { } - } - } - - public class CLREngine : ScriptEngine - { - private static readonly Logger logger = LogManager.GetCurrentClassLogger(); - - private string scriptSig = string.Empty; - private bool scriptDbg = false; - private Assembly scriptAssm = null; - - public override void Init(ref ScriptRuntime runtime) - { - base.Init(ref runtime); - - // If the user is asking to refresh the cached engine for the command, - UseNewEngine = runtime.ScriptRuntimeConfigs.RefreshEngine; - } - - public override int Execute(ref ScriptRuntime runtime) - { - // compile first - // only if the signature doesn't match - var errors = new List(); - if (scriptSig == null || runtime.ScriptSourceFileSignature != scriptSig || scriptDbg != runtime.ScriptRuntimeConfigs.DebugMode) - { - try - { - scriptSig = runtime.ScriptSourceFileSignature; - scriptDbg = runtime.ScriptRuntimeConfigs.DebugMode; - scriptAssm = CompileCLRScript(ref runtime, out errors); - if (scriptAssm == null) - { - if (runtime.RuntimeType == ScriptRuntimeType.ExternalCommand) - { - var errorReport = string.Join(Environment.NewLine, errors.ToArray()); - runtime.OutputStream.WriteError( - errorReport != string.Empty ? errorReport : "Failed to compile assembly for unknown reason", - runtime.EngineType - ); - } - // clear script signature - scriptSig = null; - return ScriptExecutorResultCodes.CompileException; - } - } - catch (Exception compileEx) - { - // make sure a bad compile is not cached - scriptAssm = null; - string traceMessage = compileEx.ToString(); - traceMessage = traceMessage.NormalizeNewLine(); - runtime.TraceMessage = traceMessage; - - if (runtime.RuntimeType == ScriptRuntimeType.ExternalCommand) - { - var dialog = new TaskDialog(PyRevitLabsConsts.ProductName); - dialog.MainInstruction = "Error compiling .NET script."; - string errorReport = string.Empty; - foreach (var errline in errors) - errorReport += $"{errline}\n"; - errorReport += string.Format("\nTrace:\n{0}\n{1}", compileEx.Message, traceMessage); - dialog.ExpandedContent = errorReport; - dialog.Show(); - } - - return ScriptExecutorResultCodes.CompileException; - } - } - - // scriptAssm must have value - switch (runtime.RuntimeType) - { - // if is an external command - case ScriptRuntimeType.ExternalCommand: - try - { - // execute now - var resultCode = ExecuteExternalCommand(scriptAssm, null, ref runtime); - if (resultCode == ScriptExecutorResultCodes.ExternalInterfaceNotImplementedException) - TaskDialog.Show(PyRevitLabsConsts.ProductName, - string.Format( - "Can not find any type implementing IExternalCommand in assembly \"{0}\"", - scriptAssm.Location - )); - return resultCode; - } - catch (Exception execEx) - { - string traceMessage = execEx.ToString(); - traceMessage = traceMessage.NormalizeNewLine(); - runtime.TraceMessage = traceMessage; - - var dialog = new TaskDialog(PyRevitLabsConsts.ProductName); - dialog.MainInstruction = "Error executing .NET script."; - dialog.ExpandedContent = string.Format("{0}\n{1}", traceMessage, execEx.StackTrace); - dialog.Show(); - - return ScriptExecutorResultCodes.ExecutionException; - } - - // if is an event hook - case ScriptRuntimeType.EventHandler: - try - { - return ExecuteEventHandler(scriptAssm, ref runtime); - } - catch (Exception execEx) - { - string traceMessage = execEx.ToString(); - traceMessage = traceMessage.NormalizeNewLine(); - runtime.TraceMessage = traceMessage; - - runtime.OutputStream.WriteError(traceMessage, runtime.EngineType); - - return ScriptExecutorResultCodes.ExecutionException; - } - - default: - return ScriptExecutorResultCodes.ExternalInterfaceNotImplementedException; - } - } - - public static IEnumerable GetTypesSafely(Assembly assembly) - { - try - { - return assembly.GetTypes(); - } - catch (ReflectionTypeLoadException ex) - { - return ex.Types.Where(x => x != null); - } - } - - public static Assembly CompileCLRScript(ref ScriptRuntime runtime, out List errors) - { - // https://stackoverflow.com/a/3188953 - - // read the referenced dlls from env vars - // pyrevit sets this when loading - List refFiles; - var envDic = new EnvDictionary(); - if (envDic.ReferencedAssemblies.Length == 0) - { - var refs = AppDomain.CurrentDomain.GetAssemblies(); - refFiles = refs.Select(a => a.Location).ToList(); - } - else - { - refFiles = envDic.ReferencedAssemblies.ToList(); - } - - // add location of this assembly - refFiles.Add(typeof(ScriptExecutor).Assembly.Location); - - // create output assembly - string outputAssembly = Path.Combine( - UserEnv.UserTemp, - string.Format("{0}_{1}.dll", runtime.ScriptData.CommandName, runtime.ScriptSourceFileSignature) - ); - - List defines = new List { - $"REVIT{runtime.App.VersionNumber}", -#if (REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - $"REVIT{runtime.App.VersionNumber}_0" -#else - $"REVIT{runtime.App.SubVersionNumber.Replace(".", "_")}" -#endif - }; - - // determine which compiler to use - switch (runtime.EngineType) - { - case ScriptEngineType.CSharp: - return CompileCSharp(runtime.ScriptSourceFile, outputAssembly, refFiles, defines, runtime.ScriptRuntimeConfigs.DebugMode, out errors); - case ScriptEngineType.VisualBasic: - return CompileVB(runtime.ScriptSourceFile, outputAssembly, refFiles, defines, runtime.ScriptRuntimeConfigs.DebugMode, out errors); - default: - throw new PyRevitException("Specified language does not have a compiler."); - } - } - - private static Assembly CompileCSharp(string sourceFile, string outputPath, List refFiles, List defines, bool debug, out List errors) - { - return pyRevitLabs.Common.CodeCompiler.CompileCSharpToAssembly( - sourceFiles: new string[] { sourceFile }, - assemblyName: Path.GetFileName(outputPath), - references: refFiles, - defines: defines, - debug, - out errors - ); - } - - private static Assembly CompileVB(string sourceFile, string outputPath, List refFiles, List defines, bool debug, out List errors) - { - return pyRevitLabs.Common.CodeCompiler.CompileVisualBasicToAssembly( - sourceFiles: new string[] { sourceFile }, - assemblyName: Path.GetFileName(outputPath), - references: refFiles, - defines: defines.Select(x => new KeyValuePair(x, null)), - debug, - out errors - ); - } - - public static int ExecuteExternalCommand(Assembly assmObj, string className, ref ScriptRuntime runtime) - { - foreach (Type assmType in GetTypesSafely(assmObj)) - { - if (assmType.IsClass) - { - // find the appropriate type and execute - if (className != null) - { - if (assmType.Name == className) - return ExecuteExternalCommandType(assmType, ref runtime); - else - continue; - } - else if (assmType.GetInterfaces().Contains(typeof(IExternalCommand))) - return ExecuteExternalCommandType(assmType, ref runtime); - } - } - - return ScriptExecutorResultCodes.ExternalInterfaceNotImplementedException; - } - - public static int ExecuteExternalCommandType(Type extCommandType, ref ScriptRuntime runtime) - { - // create instance - object extCommandInstance = Activator.CreateInstance(extCommandType); - - // set properties if available - // set ExecParams - var execParams = new SHARED.ExecParams( - execId: runtime.ExecId, - execTimeStamp: runtime.ExecTimestamp, - scriptPath: runtime.ScriptData.ScriptPath, - configScriptPath: runtime.ScriptData.ConfigScriptPath, - commandUniqueId: runtime.ScriptData.CommandUniqueId, - commandControlId: runtime.ScriptData.CommandControlId, - commandName: runtime.ScriptData.CommandName, - commandBundle: runtime.ScriptData.CommandBundle, - commandExtension: runtime.ScriptData.CommandExtension, - helpSource: runtime.ScriptData.HelpSource, - refreshEngine: runtime.ScriptRuntimeConfigs.RefreshEngine, - configMode: runtime.ScriptRuntimeConfigs.ConfigMode, - debugMode: runtime.ScriptRuntimeConfigs.DebugMode, - executedFromUI: runtime.ScriptRuntimeConfigs.ExecutedFromUI, - uiButton: runtime.UIControl - ); - - FieldInfo execParamField = null; - foreach (var fieldInfo in extCommandType.GetFields()) - { - if (fieldInfo.FieldType == typeof(SHARED.ExecParams)) - { - execParamField = fieldInfo; - execParamField.SetValue(extCommandInstance, execParams); - } - } - - // reroute console output to runtime stream - var existingOutStream = Console.Out; - StreamWriter runtimeOutputStream = new StreamWriter(runtime.OutputStream); - StreamReader runtimeInputStream = new StreamReader(runtime.OutputStream); - runtimeOutputStream.AutoFlush = true; - Console.SetOut(runtimeOutputStream); - Console.SetIn(runtimeInputStream); - - // setup logger - var prevLoggerCfg = LogManager.Configuration; - var newLoggerCfg = new LoggingConfiguration(); - var target = new CLREngineOutputTarget(); - target.CurrentExecParams = execParams; - target.Name = logger.Name; - target.Layout = "${level:uppercase=true}: [${logger}] ${message}"; - newLoggerCfg.AddTarget(target.Name, target); - newLoggerCfg.AddRuleForAllLevels(target); - LogManager.Configuration = newLoggerCfg; - - // execute - string commandMessage = string.Empty; - try - { - extCommandType.InvokeMember( - "Execute", - BindingFlags.Default | BindingFlags.InvokeMethod, - null, - extCommandInstance, - new object[] { - runtime.ScriptRuntimeConfigs.CommandData, - commandMessage, - runtime.ScriptRuntimeConfigs.SelectedElements} - ); - } - catch (Exception ex) - { - string message = "Error Invoking Command"; - if (ex.InnerException is Exception inner) - message += $"\n{inner.Message}"; - - TaskDialog.Show(PyRevitLabsConsts.ProductName, message); - } - - // revert logger back to previous - LogManager.Configuration = prevLoggerCfg; - - // cleanup reference to exec params - target.CurrentExecParams = null; - if (execParamField != null) - execParamField.SetValue(extCommandInstance, null); - - // reroute console output back to original - Console.SetOut(existingOutStream); - - return ScriptExecutorResultCodes.Succeeded; - } - - public static int ExecuteEventHandler(Assembly assmObj, ref ScriptRuntime runtime) - { - var argsType = runtime.ScriptRuntimeConfigs.EventArgs.GetType(); - foreach (Type assmType in GetTypesSafely(assmObj)) - foreach (MethodInfo methodInfo in assmType.GetMethods()) - { - var methodParams = methodInfo.GetParameters(); - if (methodParams.Count() == 2 - && methodParams[0].Name == "sender" - && (methodParams[1].Name == "e" || methodParams[1].Name == "args") - && methodParams[1].ParameterType == argsType) - { - object extEventInstance = Activator.CreateInstance(assmType); - assmType.InvokeMember( - methodInfo.Name, - BindingFlags.Default | BindingFlags.InvokeMethod, - null, - extEventInstance, - new object[] { - runtime.ScriptRuntimeConfigs.EventSender, - runtime.ScriptRuntimeConfigs.EventArgs - } - ); - return ScriptExecutorResultCodes.Succeeded; - } - } - - return ScriptExecutorResultCodes.ExternalInterfaceNotImplementedException; - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/CPythonEngine.cs b/dev/pyRevitLabs.PyRevit.Runtime/CPythonEngine.cs deleted file mode 100644 index 5c3332a44..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/CPythonEngine.cs +++ /dev/null @@ -1,288 +0,0 @@ -using System; -using System.IO; -using System.Linq; -using System.Collections.Generic; -using System.Text.RegularExpressions; - -// cpython -using Python.Runtime; -using CpyRuntime = Python.Runtime.Runtime; - -using pyRevitLabs.Common.Extensions; -using pyRevitLabs.NLog; - -namespace PyRevitLabs.PyRevit.Runtime { - public class CPythonEngine : ScriptEngine { - private static readonly Logger logger = LogManager.GetCurrentClassLogger(); - - private List _sysPaths = new List(); - - public override void Init(ref ScriptRuntime runtime) { - base.Init(ref runtime); - - // If the user is asking to refresh the cached engine for the command, - UseNewEngine = runtime.ScriptRuntimeConfigs.RefreshEngine; - } - - public override void Start(ref ScriptRuntime runtime) { - // if this is the first run - if (!RecoveredFromCache) { - // initialize - PythonEngine.ProgramName = "pyrevit"; - using (Py.GIL()) { - if (!PythonEngine.IsInitialized) - PythonEngine.Initialize(); - } - // if this is a new engine, save the syspaths - StoreSearchPaths(); - } - - SetupBuiltins(ref runtime); - SetupStreams(ref runtime); - SetupCaching(ref runtime); - SetupSearchPaths(ref runtime); - SetupArguments(ref runtime); - } - - public override int Execute(ref ScriptRuntime runtime) { - int result = ScriptExecutorResultCodes.Succeeded; - - using (Py.GIL()) { - // read script - var scriptContents = File.ReadAllText(runtime.ScriptSourceFile, encoding: System.Text.Encoding.UTF8); - - // create new scope and set globals - var scope = Py.CreateScope("__main__"); - scope.Set("__file__", runtime.ScriptSourceFile); - - // execute - try { - scope.Exec(scriptContents); - } - catch (PythonException cpyex) { - string cleanedPyTraceback = string.Empty; - string pyNetTraceback = string.Empty; - if (cpyex.StackTrace != null && cpyex.StackTrace != string.Empty) { - var traceBackParts = cpyex.StackTrace.Split(']'); - int nextIdx = 0; - // if stack trace contains file info, clean it up - if (traceBackParts.Count() == 2) { - nextIdx = 1; - string pyTraceback = traceBackParts[0].Trim() + "]"; - cleanedPyTraceback = string.Empty; - foreach (string tbLine in pyTraceback.ConvertFromTomlListString()) { - if (tbLine.Contains("File \"\"")) { - var fixedTbLine = tbLine.Replace("File \"\"", string.Format("File \"{0}\"", runtime.ScriptSourceFile)); - cleanedPyTraceback += fixedTbLine; - var lineNo = new Regex(@"\,\sline\s(?\d+)\,").Match(tbLine).Groups["lineno"].Value; - cleanedPyTraceback += scriptContents.Split('\n')[int.Parse(lineNo.Trim()) - 1] + "\n"; - } - else { - cleanedPyTraceback += tbLine; - } - } - } - // grab the dotnet cpython stack trace - pyNetTraceback = traceBackParts[nextIdx].Trim(); - } - - string traceMessage = string.Join( - "\n", - cpyex.Message, - cleanedPyTraceback, - cpyex.Source, - pyNetTraceback - ); - - // Print all errors to stdout and return cancelled to Revit. - // This is to avoid getting window prompts from Revit. - // Those pop ups are small and errors are hard to read. - traceMessage = traceMessage.NormalizeNewLine(); - runtime.TraceMessage = traceMessage; - runtime.OutputStream.WriteError(traceMessage, ScriptEngineType.CPython); - result = ScriptExecutorResultCodes.ExecutionException; - } - catch (Exception ex) { - runtime.OutputStream.WriteError(ex.Message, ScriptEngineType.CPython); - result = ScriptExecutorResultCodes.ExecutionException; - } - finally { - // remove scope - scope.Dispose(); - } - } - - return result; - } - - public override void Stop(ref ScriptRuntime runtime) { - } - - public override void Shutdown() { - CleanupBuiltins(); - CleanupStreams(); - PythonEngine.Shutdown(); - } - - private void SetupBuiltins(ref ScriptRuntime runtime) { - // get builtins - IntPtr builtins = CpyRuntime.PyEval_GetBuiltins(); - - // Add timestamp and executuin uuid - SetVariable(builtins, "__execid__", runtime.ExecId); - SetVariable(builtins, "__timestamp__", runtime.ExecTimestamp); - - // set builtins - SetVariable(builtins, "__cachedengine__", RecoveredFromCache); - SetVariable(builtins, "__cachedengineid__", TypeId); - SetVariable(builtins, "__scriptruntime__", runtime); - - if (runtime.UIApp != null) - SetVariable(builtins, "__revit__", runtime.UIApp); - else if (runtime.UIControlledApp != null) - SetVariable(builtins, "__revit__", runtime.UIControlledApp); - else if (runtime.App != null) - SetVariable(builtins, "__revit__", runtime.App); - else - SetVariable(builtins, "__revit__", null); - - // Adding data provided by IExternalCommand.Execute - SetVariable(builtins, "__commanddata__", runtime.ScriptRuntimeConfigs.CommandData); - SetVariable(builtins, "__elements__", runtime.ScriptRuntimeConfigs.SelectedElements); - - // Add ui button handle - SetVariable(builtins, "__uibutton__", runtime.UIControl); - - // Adding information on the command being executed - SetVariable(builtins, "__commandpath__", Path.GetDirectoryName(runtime.ScriptData.ScriptPath)); - SetVariable(builtins, "__configcommandpath__", Path.GetDirectoryName(runtime.ScriptData.ConfigScriptPath)); - SetVariable(builtins, "__commandname__", runtime.ScriptData.CommandName); - SetVariable(builtins, "__commandbundle__", runtime.ScriptData.CommandBundle); - SetVariable(builtins, "__commandextension__", runtime.ScriptData.CommandExtension); - SetVariable(builtins, "__commanduniqueid__", runtime.ScriptData.CommandUniqueId); - SetVariable(builtins, "__commandcontrolid__", runtime.ScriptData.CommandControlId); - SetVariable(builtins, "__forceddebugmode__", runtime.ScriptRuntimeConfigs.DebugMode); - SetVariable(builtins, "__shiftclick__", runtime.ScriptRuntimeConfigs.ConfigMode); - - // Add reference to the results dictionary - // so the command can add custom values for logging - SetVariable(builtins, "__result__", runtime.GetResultsDictionary()); - - // EVENT HOOKS BUILTINS ---------------------------------------------------------------------------------- - // set event arguments for engine - SetVariable(builtins, "__eventsender__", runtime.ScriptRuntimeConfigs.EventSender); - SetVariable(builtins, "__eventargs__", runtime.ScriptRuntimeConfigs.EventArgs); - } - - private void SetupStreams(ref ScriptRuntime runtime) { - // set output stream - PyObject sys = PythonEngine.ImportModule("sys"); - var baseStream = PyObject.FromManagedObject(runtime.OutputStream); - sys.SetAttr("stdout", baseStream); - sys.SetAttr("stdin", baseStream); - sys.SetAttr("stderr", baseStream); - } - - private void SetupCaching(ref ScriptRuntime runtime) { - // set output stream - PyObject sys = PythonEngine.ImportModule("sys"); - // dont write bytecode (__pycache__) - // https://docs.python.org/3.7/library/sys.html?highlight=pythondontwritebytecode#sys.dont_write_bytecode - sys.SetAttr("dont_write_bytecode", PyObject.FromManagedObject(true)); - } - - private void SetupSearchPaths(ref ScriptRuntime runtime) { - // set sys paths - PyList sysPaths = RestoreSearchPaths(); - - // manually add PYTHONPATH since we are overwriting the sys paths - var pythonPath = Environment.GetEnvironmentVariable("PYTHONPATH"); - if (pythonPath != null && pythonPath != string.Empty) { - var searthPathStr = new PyString(pythonPath); - sysPaths.Insert(0, searthPathStr); - } - - // now add the search paths for the script bundle - foreach (string searchPath in runtime.ScriptRuntimeConfigs.SearchPaths.Reverse()) { - var searthPathStr = new PyString(searchPath); - sysPaths.Insert(0, searthPathStr); - } - } - - private void SetupArguments(ref ScriptRuntime runtime) { - // setup arguments (sets sys.argv) - PyObject sys = PythonEngine.ImportModule("sys"); - PyObject sysArgv = sys.GetAttr("argv"); - - var pythonArgv = new PyList(); - - // for python make sure the first argument is the script - var scriptSourceStr = new PyString(runtime.ScriptSourceFile); - pythonArgv.Append(scriptSourceStr); - - // add the rest of the args - foreach (string arg in runtime.ScriptRuntimeConfigs.Arguments) { - var argStr = new PyString(arg); - pythonArgv.Append(argStr); - } - - sys.SetAttr("argv", pythonArgv); - } - - private void CleanupBuiltins() { - - } - - private void CleanupStreams() { - - } - - private void StoreSearchPaths() { - var currentSysPath = GetSysPaths(); - _sysPaths = new List(); - long itemsCount = currentSysPath.Length(); - for (long i = 0; i < itemsCount; i++) { - BorrowedReference item = - CpyRuntime.PyList_GetItem(currentSysPath.Handle, i); - string path = CpyRuntime.GetManagedString(item); - _sysPaths.Add(path); - } - } - - private PyList RestoreSearchPaths() { - var newList = new PyList(); - int i = 0; - foreach (var searchPath in _sysPaths) { - var searthPathStr = new PyString(searchPath); - newList.Insert(i, searthPathStr); - i++; - } - SetSysPaths(newList); - return newList; - } - - private PyList GetSysPaths() { - // set sys paths - PyObject sys = PythonEngine.ImportModule("sys"); - PyObject sysPathsObj = sys.GetAttr("path"); - return PyList.AsList(sysPathsObj); - } - - private void SetSysPaths(PyList sysPaths) { - PyObject sys = PythonEngine.ImportModule("sys"); - sys.SetAttr("path", sysPaths); - } - - private static void SetVariable(IntPtr? globals, string key, IntPtr value) { - CpyRuntime.PyDict_SetItemString( - pointer: globals.Value, - key: key, - value: value - ); - } - - private static void SetVariable(IntPtr? globals, string key, object value) { - SetVariable(globals, key, PyObject.FromManagedObject(value).Handle); - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ContentEngine.cs b/dev/pyRevitLabs.PyRevit.Runtime/ContentEngine.cs deleted file mode 100644 index 809058403..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ContentEngine.cs +++ /dev/null @@ -1,108 +0,0 @@ -using System; -using System.IO; -using System.Linq; -using Autodesk.Revit.UI; -using Autodesk.Revit.DB; - -using pyRevitLabs.Common; - -namespace PyRevitLabs.PyRevit.Runtime { - public class ContentEngine : ScriptEngine { - public override void Init(ref ScriptRuntime runtime) { - base.Init(ref runtime); - // this is not a cachable engine; always use new engines - UseNewEngine = true; - } - - public override int Execute(ref ScriptRuntime runtime) { -#if (REVIT2013 || REVIT2014) - TaskDialog.Show(PyRevitLabsConsts.ProductName, NotSupportedFeatureException.NotSupportedMessage); - return ScriptExecutorResultCodes.NotSupportedFeatureException; -#else - if (runtime.UIApp != null && runtime.UIApp.ActiveUIDocument != null) { - string familySourceFile = runtime.ScriptSourceFile; - UIDocument uidoc = runtime.UIApp.ActiveUIDocument; - Document doc = uidoc.Document; - - // find or load family first - Family contentFamily = null; - - // attempt to find previously loaded family - Element existingFamily = null; - string familyName = Path.GetFileNameWithoutExtension(familySourceFile); - var currentFamilies = - new FilteredElementCollector(doc).OfClass(typeof(Family)).Where(q => q.Name == familyName); - if (currentFamilies.Count() > 0) - existingFamily = currentFamilies.First(); - - if (existingFamily != null) - contentFamily = (Family)existingFamily; - - // if not found, attemt to load - if (contentFamily == null) { - try { - var txn = new Transaction(doc, "Load pyRevit Content"); - txn.Start(); - doc.LoadFamily( - familySourceFile, - new ContentLoaderOptions(), - out contentFamily - ); - txn.Commit(); - } - catch (Exception loadEx) { - var dialog = new TaskDialog(PyRevitLabsConsts.ProductName); - dialog.MainInstruction = "Failed loading content."; - dialog.ExpandedContent = string.Format("{0}\n{1}", loadEx.Message, loadEx.StackTrace); - dialog.Show(); - return ScriptExecutorResultCodes.FailedLoadingContent; - } - } - - if (contentFamily == null) { - TaskDialog.Show(PyRevitLabsConsts.ProductName, - string.Format("Failed finding or loading bundle content at:\n{0}", familySourceFile)); - return ScriptExecutorResultCodes.FailedLoadingContent; - } - - // now ask ui to place an instance - ElementId firstSymbolId = contentFamily.GetFamilySymbolIds().First(); - if (firstSymbolId != null && firstSymbolId != ElementId.InvalidElementId) { - FamilySymbol firstSymbol = (FamilySymbol)doc.GetElement(firstSymbolId); - if (firstSymbol != null) - try { - var placeOps = new PromptForFamilyInstancePlacementOptions(); - uidoc.PromptForFamilyInstancePlacement(firstSymbol, placeOps); - return ScriptExecutorResultCodes.Succeeded; - } - catch (Autodesk.Revit.Exceptions.OperationCanceledException) { - // user cancelled placement - return ScriptExecutorResultCodes.Succeeded; - } - catch (Exception promptEx) { - var dialog = new TaskDialog(PyRevitLabsConsts.ProductName); - dialog.MainInstruction = "Failed placing content."; - dialog.ExpandedContent = string.Format("{0}\n{1}", promptEx.Message, promptEx.StackTrace); - dialog.Show(); - return ScriptExecutorResultCodes.FailedLoadingContent; - } - } - } - - TaskDialog.Show(PyRevitLabsConsts.ProductName, "Failed accessing Application."); - return ScriptExecutorResultCodes.FailedLoadingContent; -#endif - } - } - - public class ContentLoaderOptions : IFamilyLoadOptions { - public bool OnFamilyFound(bool familyInUse, out bool overwriteParameterValues) { - overwriteParameterValues = true; - return overwriteParameterValues; - } - - public bool OnSharedFamilyFound(Family sharedFamily, bool familyInUse, out FamilySource source, out bool overwriteParameterValues) { - throw new NotImplementedException(); - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/Directory.Build.props b/dev/pyRevitLabs.PyRevit.Runtime/Directory.Build.props index 22f1c9a3e..2e4d54b69 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/Directory.Build.props +++ b/dev/pyRevitLabs.PyRevit.Runtime/Directory.Build.props @@ -1,4 +1,14 @@ + + true + true + true + + + + + + \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/Directory.Build.targets b/dev/pyRevitLabs.PyRevit.Runtime/Directory.Build.targets index b6b54b95b..07c8162c9 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/Directory.Build.targets +++ b/dev/pyRevitLabs.PyRevit.Runtime/Directory.Build.targets @@ -1,35 +1,30 @@ - + + - $(DefineConstants);REVIT$(RevitVersion) + $(PyRevitBinDir)\$(AssemblyName).dll - + + - - - - - - - - - - - - - - - - - - + + + + + + + + + + + @@ -37,50 +32,17 @@ - - - - - - - - - + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/DynamoBIMEngine.cs b/dev/pyRevitLabs.PyRevit.Runtime/DynamoBIMEngine.cs deleted file mode 100644 index 2154463cc..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/DynamoBIMEngine.cs +++ /dev/null @@ -1,114 +0,0 @@ -using System; -using System.IO; -using System.Collections.Generic; -using System.Runtime.Remoting; -using System.Reflection; - -using Autodesk.Revit.UI; - -using pyRevitLabs.Common; -using pyRevitLabs.Json; - -namespace PyRevitLabs.PyRevit.Runtime { - public class DynamoBIMEngineConfigs : ScriptEngineConfigs { - public bool clean = false; - public bool automate = true; - public string dynamo_path = string.Empty; - public bool dynamo_path_exec = true; - public bool dynamo_path_check_existing = false; - public bool dynamo_force_manual_run = false; - public string dynamo_model_nodes_info = string.Empty; - } - - public class DynamoBIMEngine : ScriptEngine { - public DynamoBIMEngineConfigs ExecEngineConfigs = new DynamoBIMEngineConfigs(); - - public override void Init(ref ScriptRuntime runtime) { - base.Init(ref runtime); - // this is not a cachable engine; always use new engines - UseNewEngine = true; - - // extract engine configuration from runtime data - try { - ExecEngineConfigs = JsonConvert.DeserializeObject(runtime.ScriptRuntimeConfigs.EngineConfigs); - } catch {} - } - - public override int Execute(ref ScriptRuntime runtime) { - var journalData = new Dictionary() { - // Specifies the path to the Dynamo workspace to execute. - { "dynPath", runtime.ScriptSourceFile }, - - // Specifies whether the Dynamo UI should be visible (set to false - Dynamo will run headless). - { "dynShowUI", runtime.ScriptRuntimeConfigs.DebugMode.ToString() }, - - // If the journal file specifies automation mode - // Dynamo will run on the main thread without the idle loop. - { "dynAutomation", ExecEngineConfigs.automate ? "True" : "False" }, - - // The journal file can specify if the Dynamo workspace opened - // from DynPathKey will be executed or not. - // If we are in automation mode the workspace will be executed regardless of this key. - { "dynPathExecute", ExecEngineConfigs.dynamo_path_exec ? "True" : "False" }, - - // The journal file can specify if the existing UIless RevitDynamoModel - // needs to be shutdown before performing any action. - // per comments on https://github.com/eirannejad/pyRevit/issues/570 - // Setting this to True slows down Dynamo by a factor of 3 - { "dynModelShutDown", ExecEngineConfigs.clean ? "True" : "False" }, - }; - - if (ExecEngineConfigs.dynamo_path != null && ExecEngineConfigs.dynamo_path != string.Empty) { - // The journal file can specify a Dynamo workspace to be opened - // (and executed if we are in automation mode) at run time. - journalData["dynPath"] = ExecEngineConfigs.dynamo_path; - // The journal file can specify if a check should be performed to see if the - // current workspaceModel already points to the Dynamo file we want to - // run (or perform other tasks). If that's the case, we want to use the - // current workspaceModel. - journalData["dynPathCheckExisting "] = ExecEngineConfigs.dynamo_path_check_existing ? "True" : "False"; - // The journal file can specify if the Dynamo workspace opened - // from DynPathKey will be forced in manual mode. - journalData["dynForceManualRun "] = ExecEngineConfigs.dynamo_force_manual_run ? "True" : "False"; - } - - if (ExecEngineConfigs.dynamo_model_nodes_info != null && ExecEngineConfigs.dynamo_model_nodes_info != string.Empty) { - // The journal file can specify the values of Dynamo nodes. - journalData["dynModelNodesInfo"] = ExecEngineConfigs.dynamo_model_nodes_info; - } - - //return new DynamoRevit().ExecuteCommand(new DynamoRevitCommandData() { - // JournalData = journalData, - // Application = commandData.Application - //}); - - try { - // find the DynamoRevitApp from DynamoRevitDS.dll - // this should be already loaded since Dynamo loads before pyRevit - ObjectHandle dynRevitAppObjHandle = - Activator.CreateInstance("DynamoRevitDS", "Dynamo.Applications.DynamoRevitApp"); - object dynRevitApp = dynRevitAppObjHandle.Unwrap(); - MethodInfo execDynamo = dynRevitApp.GetType().GetMethod("ExecuteDynamoCommand"); - - // run the script - execDynamo.Invoke(dynRevitApp, new object[] { journalData, runtime.UIApp }); - return ScriptExecutorResultCodes.Succeeded; - } - catch (FileNotFoundException) { - // if failed in finding DynamoRevitDS.dll, assume no dynamo - TaskDialog.Show(PyRevitLabsConsts.ProductName, - "Can not find Dynamo installation or determine which Dynamo version to Run.\n\n" + - "Run Dynamo once to select the active version."); - return ScriptExecutorResultCodes.ExecutionException; - } - catch (Exception dynEx) { - // on any other errors - var dialog = new TaskDialog(PyRevitLabsConsts.ProductName); - dialog.MainInstruction = "Error executing Dynamo script."; - dialog.ExpandedContent = string.Format("{0}\n{1}", dynEx.Message, dynEx.StackTrace); - dialog.Show(); - return ScriptExecutorResultCodes.ExecutionException; - } - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/EnvVariables.cs b/dev/pyRevitLabs.PyRevit.Runtime/EnvVariables.cs deleted file mode 100644 index a03e22f32..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/EnvVariables.cs +++ /dev/null @@ -1,173 +0,0 @@ -using System; -using System.IO; -using System.Collections.Generic; -using IronPython.Runtime; - -using pyRevitLabs.Common; - -namespace PyRevitLabs.PyRevit.Runtime { - public static class DomainStorageKeys { - public static string keyPrefix = PyRevitLabsConsts.ProductName.ToUpperInvariant(); - - public static string EnvVarsDictKey = keyPrefix + "EnvVarsDict"; - public static string EnginesDictKey = keyPrefix + "CachedEngines"; - public static string IronPythonEngineDefaultOutputStreamCfgKey = keyPrefix + "CachedEngineDefaultOutputStreamCfg"; - public static string IronPythonEngineDefaultInputStreamCfgKey = keyPrefix + "CachedEngineDefaultInputStreamCfg"; - public static string OutputWindowsDictKey = keyPrefix + "OutputWindowsDict"; - } - - public static class EnvDictionaryKeys - { - public static string keyPrefix = PyRevitLabsConsts.ProductName.ToUpperInvariant(); - - public static string SessionUUID = string.Format("{0}_UUID", keyPrefix); - public static string RevitVersion = string.Format("{0}_APPVERSION", keyPrefix); - public static string Version = string.Format("{0}_VERSION", keyPrefix); - public static string Clone = string.Format("{0}_CLONE", keyPrefix); - public static string IPYVersion = string.Format("{0}_IPYVERSION", keyPrefix); - public static string CPYVersion = string.Format("{0}_CPYVERSION", keyPrefix); - - public static string LoggingLevel = string.Format("{0}_LOGGINGLEVEL", keyPrefix); - public static string FileLogging = string.Format("{0}_FILELOGGING", keyPrefix); - - public static string LoadedAssms = string.Format("{0}_LOADEDASSMS", keyPrefix); - public static string RefedAssms = string.Format("{0}_REFEDASSMS", keyPrefix); - - public static string TelemetryState = string.Format("{0}_TELEMETRYSTATE", keyPrefix); - public static string TelemetryUTCTimeStamps = string.Format("{0}_TELEMETRYUTCTIMESTAMPS", keyPrefix); - public static string TelemetryFileDir = string.Format("{0}_TELEMETRYDIR", keyPrefix); - public static string TelemetryFilePath = string.Format("{0}_TELEMETRYFILE", keyPrefix); - public static string TelemetryServerUrl = string.Format("{0}_TELEMETRYSERVER", keyPrefix); - public static string TelemetryIncludeHooks = string.Format("{0}_TELEMETRYINCLUDEHOOKS", keyPrefix); - - public static string AppTelemetryState = string.Format("{0}_APPTELEMETRYSTATE", keyPrefix); - public static string AppTelemetryHandler = string.Format("{0}_APPTELEMETRYHANDLER", keyPrefix); - public static string AppTelemetryServerUrl = string.Format("{0}_APPTELEMETRYSERVER", keyPrefix); - public static string AppTelemetryEventFlags = string.Format("{0}_APPTELEMETRYEVENTFLAGS", keyPrefix); - - public static string Hooks = string.Format("{0}_HOOKS", keyPrefix); - public static string HooksHandler = string.Format("{0}_HOOKSHANDLER", keyPrefix); - - public static string AutoUpdating = string.Format("{0}_AUTOUPDATE", keyPrefix); - public static string OutputStyleSheet = string.Format("{0}_STYLESHEET", keyPrefix); - public static string RibbonUpdator = string.Format("{0}_RIBBONUPDATOR", keyPrefix); - public static string TabColorizer = string.Format("{0}_TABCOLORIZER", keyPrefix); - } - - public class EnvDictionary - { - private PythonDictionary _envData = null; - - public string SessionUUID; - public string RevitVersion; - public string PyRevitVersion; - public string PyRevitClone; - public string PyRevitIPYVersion; - public string PyRevitCPYVersion; - - public int LoggingLevel; - public bool FileLogging; - - public string[] LoadedAssemblies; - public string[] ReferencedAssemblies; - - public bool TelemetryState; - public string TelemetryFilePath; - public string TelemetryServerUrl; - public bool TelemetryIncludeHooks; - - public bool AppTelemetryState; - public string AppTelemetryServerUrl; - public string AppTelemetryEventFlags; - - public Dictionary> EventHooks = - new Dictionary>(); - - public string ActiveStyleSheet; - public bool AutoUpdate; - public bool TelemetryUTCTimeStamps; - - - public EnvDictionary() - { - // get the dictionary from appdomain - _envData = (PythonDictionary)AppDomain.CurrentDomain.GetData(DomainStorageKeys.EnvVarsDictKey); - - // base info - if (_envData.Contains(EnvDictionaryKeys.SessionUUID)) - SessionUUID = (string)_envData[EnvDictionaryKeys.SessionUUID]; - - if (_envData.Contains(EnvDictionaryKeys.RevitVersion)) - RevitVersion = (string)_envData[EnvDictionaryKeys.RevitVersion]; - - if (_envData.Contains(EnvDictionaryKeys.Version)) - PyRevitVersion = (string)_envData[EnvDictionaryKeys.Version]; - - if (_envData.Contains(EnvDictionaryKeys.Clone)) - PyRevitClone = (string)_envData[EnvDictionaryKeys.Clone]; - - if (_envData.Contains(EnvDictionaryKeys.IPYVersion)) - PyRevitIPYVersion = (string)_envData[EnvDictionaryKeys.IPYVersion]; - - if (_envData.Contains(EnvDictionaryKeys.CPYVersion)) - PyRevitCPYVersion = (string)_envData[EnvDictionaryKeys.CPYVersion]; - - // logging - if (_envData.Contains(EnvDictionaryKeys.LoggingLevel)) - LoggingLevel = (int)_envData[EnvDictionaryKeys.LoggingLevel]; - if (_envData.Contains(EnvDictionaryKeys.FileLogging)) - FileLogging = (bool)_envData[EnvDictionaryKeys.FileLogging]; - - // assemblies - if (_envData.Contains(EnvDictionaryKeys.LoadedAssms)) - LoadedAssemblies = ((string)_envData[EnvDictionaryKeys.LoadedAssms]).Split(Path.PathSeparator); - if (_envData.Contains(EnvDictionaryKeys.RefedAssms)) - ReferencedAssemblies = ((string)_envData[EnvDictionaryKeys.RefedAssms]).Split(Path.PathSeparator); - - // telemetry - if (_envData.Contains(EnvDictionaryKeys.TelemetryUTCTimeStamps)) - TelemetryUTCTimeStamps = (bool)_envData[EnvDictionaryKeys.TelemetryUTCTimeStamps]; - - // script telemetry - if (_envData.Contains(EnvDictionaryKeys.TelemetryState)) - TelemetryState = (bool)_envData[EnvDictionaryKeys.TelemetryState]; - - if (_envData.Contains(EnvDictionaryKeys.TelemetryFilePath)) - TelemetryFilePath = (string)_envData[EnvDictionaryKeys.TelemetryFilePath]; - - if (_envData.Contains(EnvDictionaryKeys.TelemetryServerUrl)) - TelemetryServerUrl = (string)_envData[EnvDictionaryKeys.TelemetryServerUrl]; - - if (_envData.Contains(EnvDictionaryKeys.TelemetryIncludeHooks)) - TelemetryIncludeHooks = (bool)_envData[EnvDictionaryKeys.TelemetryIncludeHooks]; - - // app events telemetry - if (_envData.Contains(EnvDictionaryKeys.AppTelemetryState)) - AppTelemetryState = (bool)_envData[EnvDictionaryKeys.AppTelemetryState]; - - if (_envData.Contains(EnvDictionaryKeys.AppTelemetryServerUrl)) - AppTelemetryServerUrl = (string)_envData[EnvDictionaryKeys.AppTelemetryServerUrl]; - - if (_envData.Contains(EnvDictionaryKeys.AppTelemetryEventFlags)) - AppTelemetryEventFlags = (string)_envData[EnvDictionaryKeys.AppTelemetryEventFlags]; - - // hooks - if (_envData.Contains(EnvDictionaryKeys.Hooks)) - EventHooks = (Dictionary>)_envData[EnvDictionaryKeys.Hooks]; - else - _envData[EnvDictionaryKeys.Hooks] = EventHooks; - - // misc - if (_envData.Contains(EnvDictionaryKeys.AutoUpdating)) - AutoUpdate = (bool)_envData[EnvDictionaryKeys.AutoUpdating]; - - if (_envData.Contains(EnvDictionaryKeys.OutputStyleSheet)) - ActiveStyleSheet = (string)_envData[EnvDictionaryKeys.OutputStyleSheet]; - - } - - public void ResetEventHooks() { - ((Dictionary>)_envData[EnvDictionaryKeys.Hooks]).Clear(); - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/EventHandling.cs b/dev/pyRevitLabs.PyRevit.Runtime/EventHandling.cs deleted file mode 100644 index a65b81162..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/EventHandling.cs +++ /dev/null @@ -1,1640 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text.RegularExpressions; -using System.Windows; -using System.Windows.Interop; -using System.Windows.Controls; -using System.Windows.Media; -using System.Reflection; - -using Autodesk.Revit.DB; -using Autodesk.Revit.DB.Events; -using Autodesk.Revit.UI; -using Autodesk.Revit.UI.Events; - -using UIFramework; - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018) -using Xceed.Wpf.AvalonDock.Layout; -using Xceed.Wpf.AvalonDock.Controls; -#endif - -using pyRevitLabs.NLog; -using pyRevitLabs.PyRevit; - -namespace PyRevitLabs.PyRevit.Runtime { - public enum EventType { - // Autodesk.Revit.ApplicationServices.Application Events - Application_ApplicationInitialized, - Application_DocumentChanged, - Application_DocumentClosed, - Application_DocumentClosing, - Application_DocumentCreated, - Application_DocumentCreating, - Application_DocumentOpened, - Application_DocumentOpening, - Application_DocumentPrinted, - Application_DocumentPrinting, - Application_DocumentSaved, - Application_DocumentSaving, - Application_DocumentSavedAs, - Application_DocumentSavingAs, - Application_DocumentSynchronizedWithCentral, - Application_DocumentSynchronizingWithCentral, - Application_DocumentWorksharingEnabled, - Application_ElementTypeDuplicated, - Application_ElementTypeDuplicating, - Application_FailuresProcessing, - Application_FamilyLoadedIntoDocument, - Application_FamilyLoadingIntoDocument, - Application_FileExported, - Application_FileExporting, - Application_FileImported, - Application_FileImporting, - Application_LinkedResourceOpened, - Application_LinkedResourceOpening, - Application_ProgressChanged, - Application_ViewExported, - Application_ViewExporting, - Application_ViewPrinted, - Application_ViewPrinting, - Application_WorksharedOperationProgressChanged, - - // Autodesk.Revit.UI.UIApplication Events - UIApplication_ApplicationClosing, - UIApplication_DialogBoxShowing, - UIApplication_DisplayingOptionsDialog, - UIApplication_DockableFrameFocusChanged, - UIApplication_DockableFrameVisibilityChanged, - UIApplication_FabricationPartBrowserChanged, - UIApplication_FormulaEditing, - UIApplication_Idling, - UIApplication_TransferredProjectStandards, - UIApplication_TransferringProjectStandards, - UIApplication_ViewActivated, - UIApplication_ViewActivating, - - // Autodesk.Revit.UI.AddInCommandBinding Events - AddInCommandBinding_BeforeExecuted, - AddInCommandBinding_CanExecute, - AddInCommandBinding_Executed, - - // pyRevit-defined events - Application_JournalUpdated, - Application_JournalCommandExecuted, - Application_IUpdater, - } - - public interface IEventTypeHandler { -#if !(REVIT2013) - void AddInCommandBinding_BeforeExecuted(object sender, BeforeExecutedEventArgs e); -#endif - -#if !(REVIT2013 || REVIT2014) - void Application_FamilyLoadingIntoDocument(object sender, FamilyLoadingIntoDocumentEventArgs e); - void Application_FamilyLoadedIntoDocument(object sender, FamilyLoadedIntoDocumentEventArgs e); - void Application_ElementTypeDuplicating(object sender, ElementTypeDuplicatingEventArgs e); - void Application_ElementTypeDuplicated(object sender, ElementTypeDuplicatedEventArgs e); - void Application_DocumentWorksharingEnabled(object sender, DocumentWorksharingEnabledEventArgs e); - void UIApplication_DockableFrameVisibilityChanged(object sender, DockableFrameVisibilityChangedEventArgs e); - void UIApplication_DockableFrameFocusChanged(object sender, DockableFrameFocusChangedEventArgs e); -#endif - -#if !(REVIT2013 || REVIT2014 || REVIT2015) -#endif - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016) - void UIApplication_FabricationPartBrowserChanged(object sender, FabricationPartBrowserChangedEventArgs e); -#endif - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - void Application_ViewExporting(object sender, ViewExportingEventArgs e); - void Application_ViewExported(object sender, ViewExportedEventArgs e); - void Application_LinkedResourceOpening(object sender, LinkedResourceOpeningEventArgs e); - void Application_LinkedResourceOpened(object sender, LinkedResourceOpenedEventArgs e); - void Application_WorksharedOperationProgressChanged(object sender, WorksharedOperationProgressChangedEventArgs e); - void UIApplication_TransferringProjectStandards(object sender, TransferringProjectStandardsEventArgs e); - void UIApplication_TransferredProjectStandards(object sender, TransferredProjectStandardsEventArgs e); -#endif - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018) - void UIApplication_FormulaEditing(object sender, FormulaEditingEventArgs e); -#endif - - void Application_ViewPrinting(object sender, ViewPrintingEventArgs e); - void Application_ViewPrinted(object sender, ViewPrintedEventArgs e); - void Application_ProgressChanged(object sender, ProgressChangedEventArgs e); - void Application_FileImporting(object sender, FileImportingEventArgs e); - void Application_FileImported(object sender, FileImportedEventArgs e); - void Application_FileExporting(object sender, FileExportingEventArgs e); - void Application_FileExported(object sender, FileExportedEventArgs e); - void Application_FailuresProcessing(object sender, FailuresProcessingEventArgs e); - void Application_DocumentSynchronizingWithCentral(object sender, DocumentSynchronizingWithCentralEventArgs e); - void Application_DocumentSynchronizedWithCentral(object sender, DocumentSynchronizedWithCentralEventArgs e); - void Application_DocumentSavingAs(object sender, DocumentSavingAsEventArgs e); - void Application_DocumentSavedAs(object sender, DocumentSavedAsEventArgs e); - void Application_DocumentSaving(object sender, DocumentSavingEventArgs e); - void Application_DocumentSaved(object sender, DocumentSavedEventArgs e); - void Application_DocumentPrinting(object sender, DocumentPrintingEventArgs e); - void Application_DocumentPrinted(object sender, DocumentPrintedEventArgs e); - void Application_DocumentOpening(object sender, DocumentOpeningEventArgs e); - void Application_DocumentOpened(object sender, DocumentOpenedEventArgs e); - void Application_DocumentCreating(object sender, DocumentCreatingEventArgs e); - void Application_DocumentCreated(object sender, DocumentCreatedEventArgs e); - void Application_DocumentClosing(object sender, DocumentClosingEventArgs e); - void Application_DocumentClosed(object sender, DocumentClosedEventArgs e); - void Application_DocumentChanged(object sender, DocumentChangedEventArgs e); - void Application_ApplicationInitialized(object sender, ApplicationInitializedEventArgs e); - void UIApplication_ViewActivating(object sender, ViewActivatingEventArgs e); - void UIApplication_ViewActivated(object sender, ViewActivatedEventArgs e); - void UIApplication_Idling(object sender, IdlingEventArgs e); - void UIApplication_DisplayingOptionsDialog(object sender, DisplayingOptionsDialogEventArgs e); - void UIApplication_ApplicationClosing(object sender, ApplicationClosingEventArgs e); - void UIApplication_DialogBoxShowing(object sender, DialogBoxShowingEventArgs e); - void AddInCommandBinding_CanExecute(object sender, CanExecuteEventArgs e); - void AddInCommandBinding_Executed(object sender, ExecutedEventArgs e); - - // custom events. These are called from a non-main thread - void Application_JournalUpdated(object sender, JournalUpdateArgs e); - void Application_JournalCommandExecuted(object sender, CommandExecutedArgs e); - - void Application_IUpdater(object sender, UpdaterData d); - } - - public static class EventUtils { - private static JournalListener journalListener = null; - private static UpdaterListener updaterListener = null; - - private static Dictionary eventNames = new Dictionary { - { EventType.UIApplication_ApplicationClosing, "app-closing" }, - { EventType.UIApplication_Idling, "app-idling" }, - { EventType.Application_ApplicationInitialized, "app-init" }, - { EventType.UIApplication_DialogBoxShowing, "dialog-showing" }, - { EventType.Application_DocumentChanged, "doc-changed" }, - { EventType.Application_DocumentClosed, "doc-closed" }, - { EventType.Application_DocumentClosing, "doc-closing" }, - { EventType.Application_DocumentCreated, "doc-created" }, - { EventType.Application_DocumentCreating, "doc-creating" }, - { EventType.Application_DocumentOpened, "doc-opened" }, - { EventType.Application_DocumentOpening, "doc-opening" }, - { EventType.Application_DocumentPrinted, "doc-printed" }, - { EventType.Application_DocumentPrinting, "doc-printing" }, - { EventType.Application_DocumentSavedAs, "doc-saved-as" }, - { EventType.Application_DocumentSaved, "doc-saved" }, - { EventType.Application_DocumentSavingAs, "doc-saving-as" }, - { EventType.Application_DocumentSaving, "doc-saving" }, - { EventType.Application_DocumentSynchronizedWithCentral, "doc-synced" }, - { EventType.Application_DocumentSynchronizingWithCentral, "doc-syncing" }, - { EventType.Application_DocumentWorksharingEnabled, "doc-worksharing-enabled" }, - { EventType.UIApplication_DockableFrameFocusChanged, "dock-focus-changed" }, - { EventType.UIApplication_DockableFrameVisibilityChanged, "dock-visibility-changed" }, - { EventType.UIApplication_FabricationPartBrowserChanged, "fabparts-browser-changed" }, - { EventType.Application_FailuresProcessing, "failure-processing" }, - { EventType.Application_FamilyLoadedIntoDocument, "family-loaded" }, - { EventType.Application_FamilyLoadingIntoDocument, "family-loading" }, - { EventType.Application_FileExported, "file-exported" }, - { EventType.Application_FileExporting, "file-exporting" }, - { EventType.Application_FileImported, "file-imported" }, - { EventType.Application_FileImporting, "file-importing" }, - { EventType.UIApplication_FormulaEditing, "formula-editing" }, - { EventType.Application_LinkedResourceOpened, "link-opened" }, - { EventType.Application_LinkedResourceOpening, "link-opening" }, - { EventType.UIApplication_DisplayingOptionsDialog, "options-showing" }, - { EventType.Application_ProgressChanged, "progress-changed" }, - { EventType.UIApplication_TransferredProjectStandards, "transferred-project-standards" }, - { EventType.UIApplication_TransferringProjectStandards, "transferring-project-standards" }, - { EventType.Application_ElementTypeDuplicated, "type-duplicated" }, - { EventType.Application_ElementTypeDuplicating, "type-duplicating" }, - { EventType.UIApplication_ViewActivated, "view-activated" }, - { EventType.UIApplication_ViewActivating, "view-activating" }, - { EventType.Application_ViewExported, "view-exported" }, - { EventType.Application_ViewExporting, "view-exporting" }, - { EventType.Application_ViewPrinted, "view-printed" }, - { EventType.Application_ViewPrinting, "view-printing" }, - { EventType.Application_WorksharedOperationProgressChanged, "worksharing-ops-progress-changed" }, - { EventType.AddInCommandBinding_BeforeExecuted, "command-before-exec" }, - { EventType.AddInCommandBinding_CanExecute, "command-can-exec" }, - { EventType.AddInCommandBinding_Executed, "command-exec" }, - { EventType.Application_JournalUpdated, "journal-updated" }, - { EventType.Application_JournalCommandExecuted, "journal-command-exec" }, - { EventType.Application_IUpdater, "doc-updater" }, - }; - - public static string GetEventName(EventType eventType) { - string eventName = null; - eventNames.TryGetValue(eventType, out eventName); - return eventName; - } - - public static EventType? GetEventType(string eventName) { - try { - return eventNames.First(x => x.Value == eventName).Key; - } - catch { - return null; - } - } - - public static Array GetAllEventTypes() { - return Enum.GetValues(typeof(EventType)); - } - - public static List GetSupportedEventTypes() { - var supTypes = new List(); - var supportedHandlers = typeof(IEventTypeHandler).GetMembers().Select(m => m.Name); - foreach (EventType eventType in Enum.GetValues(typeof(EventType))) - if (supportedHandlers.Contains(eventType.ToString())) - supTypes.Add(eventType); - return supTypes; - } - - public static AddInCommandBinding GetCommandBinding(UIApplication uiApp, string commandName) { - try { - RevitCommandId commandId = RevitCommandId.LookupCommandId(commandName); - if (commandId != null) - return uiApp.CreateAddInCommandBinding(commandId); - } - catch { } - return null; - } - - private static void ActivateJournalListener(UIApplication uiapp) { - if (journalListener == null) { - journalListener = new JournalListener(uiapp); - journalListener.Start(); - } - } - - private static void DeactivateJournalListener(UIApplication uiapp) { - // shut down the listener only if it is not firing any events - if (journalListener != null && !(journalListener.JournalUpdateEvents || journalListener.JournalCommandExecutedEvents)) { - journalListener.Stop(); - journalListener = null; - } - } - - private static void ActivateUpdaterListener() { - if (updaterListener == null) { - updaterListener = new UpdaterListener(); - UpdaterRegistry.RegisterUpdater(updaterListener); - UpdaterRegistry.AddTrigger( - updaterListener.GetUpdaterId(), - new ElementCategoryFilter(BuiltInCategory.INVALID, inverted: true), - Element.GetChangeTypeAny()); - } - } - - private static void DeactivateUpdaterListener() { - // shut down the listener only if it is not firing any events - if (updaterListener != null) { - var updaterId = updaterListener.GetUpdaterId(); - UpdaterRegistry.RemoveAllTriggers(updaterId); - UpdaterRegistry.UnregisterUpdater(updaterId); - updaterListener = null; - } - } - -#if (!REVIT2013) - public static List GetAllCommandBindings(UIApplication uiApp) { - var cmdBindings = new List(); - foreach (PostableCommand postableCommand in Enum.GetValues(typeof(PostableCommand))) { - try { - RevitCommandId commandId = RevitCommandId.LookupPostableCommandId(postableCommand); - if (commandId != null) - cmdBindings.Add( - uiApp.CreateAddInCommandBinding(commandId) - ); - } - catch { } - } - return cmdBindings; - } -#endif - - public static void ToggleHooks(T hndlr, UIApplication uiApp, EventType eventType, string eventTarget = null, bool toggle_on = true) where T : IEventTypeHandler { - AddInCommandBinding cmdBinding; - - switch (eventType) { - case EventType.Application_ApplicationInitialized: - if (toggle_on) - uiApp.Application.ApplicationInitialized += hndlr.Application_ApplicationInitialized; - else - uiApp.Application.ApplicationInitialized -= hndlr.Application_ApplicationInitialized; - break; - - case EventType.Application_DocumentChanged: - if (toggle_on) - uiApp.Application.DocumentChanged += hndlr.Application_DocumentChanged; - else - uiApp.Application.DocumentChanged -= hndlr.Application_DocumentChanged; - break; - - case EventType.Application_DocumentClosed: - if (toggle_on) - uiApp.Application.DocumentClosed += hndlr.Application_DocumentClosed; - else - uiApp.Application.DocumentClosed -= hndlr.Application_DocumentClosed; - break; - - case EventType.Application_DocumentClosing: - if (toggle_on) - uiApp.Application.DocumentClosing += hndlr.Application_DocumentClosing; - else - uiApp.Application.DocumentClosing -= hndlr.Application_DocumentClosing; - break; - - case EventType.Application_DocumentCreated: - if (toggle_on) - uiApp.Application.DocumentCreated += hndlr.Application_DocumentCreated; - else - uiApp.Application.DocumentCreated -= hndlr.Application_DocumentCreated; - break; - - case EventType.Application_DocumentCreating: - if (toggle_on) - uiApp.Application.DocumentCreating += hndlr.Application_DocumentCreating; - else - uiApp.Application.DocumentCreating -= hndlr.Application_DocumentCreating; - break; - - case EventType.Application_DocumentOpened: - if (toggle_on) - uiApp.Application.DocumentOpened += hndlr.Application_DocumentOpened; - else - uiApp.Application.DocumentOpened -= hndlr.Application_DocumentOpened; - break; - - case EventType.Application_DocumentOpening: - if (toggle_on) - uiApp.Application.DocumentOpening += hndlr.Application_DocumentOpening; - else - uiApp.Application.DocumentOpening -= hndlr.Application_DocumentOpening; - break; - - case EventType.Application_DocumentPrinted: - if (toggle_on) - uiApp.Application.DocumentPrinted += hndlr.Application_DocumentPrinted; - else - uiApp.Application.DocumentPrinted -= hndlr.Application_DocumentPrinted; - break; - - case EventType.Application_DocumentPrinting: - if (toggle_on) - uiApp.Application.DocumentPrinting += hndlr.Application_DocumentPrinting; - else - uiApp.Application.DocumentPrinting -= hndlr.Application_DocumentPrinting; - break; - - case EventType.Application_DocumentSaved: - if (toggle_on) - uiApp.Application.DocumentSaved += hndlr.Application_DocumentSaved; - else - uiApp.Application.DocumentSaved -= hndlr.Application_DocumentSaved; - break; - - case EventType.Application_DocumentSaving: - if (toggle_on) - uiApp.Application.DocumentSaving += hndlr.Application_DocumentSaving; - else - uiApp.Application.DocumentSaving -= hndlr.Application_DocumentSaving; - break; - - case EventType.Application_DocumentSavedAs: - if (toggle_on) - uiApp.Application.DocumentSavedAs += hndlr.Application_DocumentSavedAs; - else - uiApp.Application.DocumentSavedAs -= hndlr.Application_DocumentSavedAs; - break; - - case EventType.Application_DocumentSavingAs: - if (toggle_on) - uiApp.Application.DocumentSavingAs += hndlr.Application_DocumentSavingAs; - else - uiApp.Application.DocumentSavingAs -= hndlr.Application_DocumentSavingAs; - break; - - case EventType.Application_DocumentSynchronizedWithCentral: - if (toggle_on) - uiApp.Application.DocumentSynchronizedWithCentral += hndlr.Application_DocumentSynchronizedWithCentral; - else - uiApp.Application.DocumentSynchronizedWithCentral -= hndlr.Application_DocumentSynchronizedWithCentral; - break; - - case EventType.Application_DocumentSynchronizingWithCentral: - if (toggle_on) - uiApp.Application.DocumentSynchronizingWithCentral += hndlr.Application_DocumentSynchronizingWithCentral; - else - uiApp.Application.DocumentSynchronizingWithCentral -= hndlr.Application_DocumentSynchronizingWithCentral; - break; - - case EventType.Application_DocumentWorksharingEnabled: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016) - if (toggle_on) - uiApp.Application.DocumentWorksharingEnabled += hndlr.Application_DocumentWorksharingEnabled; - else - uiApp.Application.DocumentWorksharingEnabled -= hndlr.Application_DocumentWorksharingEnabled; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.Application_ElementTypeDuplicated: -#if !(REVIT2013 || REVIT2014) - if (toggle_on) - uiApp.Application.ElementTypeDuplicated += hndlr.Application_ElementTypeDuplicated; - else - uiApp.Application.ElementTypeDuplicated -= hndlr.Application_ElementTypeDuplicated; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.Application_ElementTypeDuplicating: -#if !(REVIT2013 || REVIT2014) - if (toggle_on) - uiApp.Application.ElementTypeDuplicating += hndlr.Application_ElementTypeDuplicating; - else - uiApp.Application.ElementTypeDuplicating -= hndlr.Application_ElementTypeDuplicating; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.Application_FailuresProcessing: - if (toggle_on) - uiApp.Application.FailuresProcessing += hndlr.Application_FailuresProcessing; - else - uiApp.Application.FailuresProcessing -= hndlr.Application_FailuresProcessing; - break; - - case EventType.Application_FamilyLoadedIntoDocument: -#if !(REVIT2013 || REVIT2014) - if (toggle_on) - uiApp.Application.FamilyLoadedIntoDocument += hndlr.Application_FamilyLoadedIntoDocument; - else - uiApp.Application.FamilyLoadedIntoDocument -= hndlr.Application_FamilyLoadedIntoDocument; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.Application_FamilyLoadingIntoDocument: -#if !(REVIT2013 || REVIT2014) - if (toggle_on) - uiApp.Application.FamilyLoadingIntoDocument += hndlr.Application_FamilyLoadingIntoDocument; - else - uiApp.Application.FamilyLoadingIntoDocument -= hndlr.Application_FamilyLoadingIntoDocument; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.Application_FileExported: - if (toggle_on) - uiApp.Application.FileExported += hndlr.Application_FileExported; - else - uiApp.Application.FileExported -= hndlr.Application_FileExported; - break; - - case EventType.Application_FileExporting: - if (toggle_on) - uiApp.Application.FileExporting += hndlr.Application_FileExporting; - else - uiApp.Application.FileExporting -= hndlr.Application_FileExporting; - break; - - case EventType.Application_FileImported: - if (toggle_on) - uiApp.Application.FileImported += hndlr.Application_FileImported; - else - uiApp.Application.FileImported -= hndlr.Application_FileImported; - break; - - case EventType.Application_FileImporting: - if (toggle_on) - uiApp.Application.FileImporting += hndlr.Application_FileImporting; - else - uiApp.Application.FileImporting -= hndlr.Application_FileImporting; - break; - - case EventType.Application_LinkedResourceOpened: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - if (toggle_on) - uiApp.Application.LinkedResourceOpened += hndlr.Application_LinkedResourceOpened; - else - uiApp.Application.LinkedResourceOpened -= hndlr.Application_LinkedResourceOpened; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.Application_LinkedResourceOpening: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - if (toggle_on) - uiApp.Application.LinkedResourceOpening += hndlr.Application_LinkedResourceOpening; - else - uiApp.Application.LinkedResourceOpening -= hndlr.Application_LinkedResourceOpening; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.Application_ProgressChanged: - if (toggle_on) - uiApp.Application.ProgressChanged += hndlr.Application_ProgressChanged; - else - uiApp.Application.ProgressChanged -= hndlr.Application_ProgressChanged; - break; - - case EventType.Application_ViewExported: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - if (toggle_on) - uiApp.Application.ViewExported += hndlr.Application_ViewExported; - else - uiApp.Application.ViewExported -= hndlr.Application_ViewExported; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.Application_ViewExporting: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - if (toggle_on) - uiApp.Application.ViewExporting += hndlr.Application_ViewExporting; - else - uiApp.Application.ViewExporting -= hndlr.Application_ViewExporting; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.Application_ViewPrinted: - if (toggle_on) - uiApp.Application.ViewPrinted += hndlr.Application_ViewPrinted; - else - uiApp.Application.ViewPrinted -= hndlr.Application_ViewPrinted; - break; - - case EventType.Application_ViewPrinting: - if (toggle_on) - uiApp.Application.ViewPrinting += hndlr.Application_ViewPrinting; - else - uiApp.Application.ViewPrinting -= hndlr.Application_ViewPrinting; - break; - - case EventType.Application_WorksharedOperationProgressChanged: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - if (toggle_on) - uiApp.Application.WorksharedOperationProgressChanged += hndlr.Application_WorksharedOperationProgressChanged; - else - uiApp.Application.WorksharedOperationProgressChanged -= hndlr.Application_WorksharedOperationProgressChanged; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.UIApplication_ApplicationClosing: - if (toggle_on) - uiApp.ApplicationClosing += hndlr.UIApplication_ApplicationClosing; - else - uiApp.ApplicationClosing -= hndlr.UIApplication_ApplicationClosing; - break; - - case EventType.UIApplication_DialogBoxShowing: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016) - if (toggle_on) - uiApp.DialogBoxShowing += hndlr.UIApplication_DialogBoxShowing; - else - uiApp.DialogBoxShowing -= hndlr.UIApplication_DialogBoxShowing; - break; -#else - throw new NotSupportedFeatureException(); -#endif - case EventType.UIApplication_DisplayingOptionsDialog: - if (toggle_on) - uiApp.DisplayingOptionsDialog += hndlr.UIApplication_DisplayingOptionsDialog; - else - uiApp.DisplayingOptionsDialog -= hndlr.UIApplication_DisplayingOptionsDialog; - break; - - case EventType.UIApplication_DockableFrameFocusChanged: -#if !(REVIT2013 || REVIT2014) - if (toggle_on) - uiApp.DockableFrameFocusChanged += hndlr.UIApplication_DockableFrameFocusChanged; - else - uiApp.DockableFrameFocusChanged -= hndlr.UIApplication_DockableFrameFocusChanged; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.UIApplication_DockableFrameVisibilityChanged: -#if !(REVIT2013 || REVIT2014) - if (toggle_on) - uiApp.DockableFrameVisibilityChanged += hndlr.UIApplication_DockableFrameVisibilityChanged; - else - uiApp.DockableFrameVisibilityChanged -= hndlr.UIApplication_DockableFrameVisibilityChanged; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.UIApplication_FabricationPartBrowserChanged: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016) - if (toggle_on) - uiApp.FabricationPartBrowserChanged += hndlr.UIApplication_FabricationPartBrowserChanged; - else - uiApp.FabricationPartBrowserChanged -= hndlr.UIApplication_FabricationPartBrowserChanged; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.UIApplication_FormulaEditing: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018) - if (toggle_on) - uiApp.FormulaEditing += hndlr.UIApplication_FormulaEditing; - else - uiApp.FormulaEditing -= hndlr.UIApplication_FormulaEditing; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.UIApplication_Idling: - if (toggle_on) - uiApp.Idling += hndlr.UIApplication_Idling; - else - uiApp.Idling -= hndlr.UIApplication_Idling; - break; - - - case EventType.UIApplication_TransferredProjectStandards: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - if (toggle_on) - uiApp.TransferredProjectStandards += hndlr.UIApplication_TransferredProjectStandards; - else - uiApp.TransferredProjectStandards -= hndlr.UIApplication_TransferredProjectStandards; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.UIApplication_TransferringProjectStandards: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - if (toggle_on) - uiApp.TransferringProjectStandards += hndlr.UIApplication_TransferringProjectStandards; - else - uiApp.TransferringProjectStandards -= hndlr.UIApplication_TransferringProjectStandards; - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.UIApplication_ViewActivated: - if (toggle_on) - uiApp.ViewActivated += hndlr.UIApplication_ViewActivated; - else - uiApp.ViewActivated -= hndlr.UIApplication_ViewActivated; - break; - - case EventType.UIApplication_ViewActivating: - if (toggle_on) - uiApp.ViewActivating += hndlr.UIApplication_ViewActivating; - else - uiApp.ViewActivating -= hndlr.UIApplication_ViewActivating; - break; - -#if !(REVIT2013) - case EventType.AddInCommandBinding_BeforeExecuted: - if (eventTarget == null) { - // activate before existing handler on ALL known commands - foreach (AddInCommandBinding addinCmdBinding in GetAllCommandBindings(uiApp)) - if (toggle_on) - addinCmdBinding.BeforeExecuted += hndlr.AddInCommandBinding_BeforeExecuted; - else - addinCmdBinding.BeforeExecuted -= hndlr.AddInCommandBinding_BeforeExecuted; - } - else { - cmdBinding = GetCommandBinding(uiApp, eventTarget); - if (toggle_on) - cmdBinding.BeforeExecuted += hndlr.AddInCommandBinding_BeforeExecuted; - else - cmdBinding.BeforeExecuted -= hndlr.AddInCommandBinding_BeforeExecuted; - } - break; -#else - throw new NotSupportedFeatureException(); -#endif - - case EventType.AddInCommandBinding_CanExecute: - if (eventTarget != null) { - cmdBinding = GetCommandBinding(uiApp, eventTarget); - if (toggle_on) - cmdBinding.CanExecute += hndlr.AddInCommandBinding_CanExecute; - else - cmdBinding.CanExecute -= hndlr.AddInCommandBinding_CanExecute; - } - break; - - case EventType.AddInCommandBinding_Executed: - if (eventTarget != null) { - cmdBinding = GetCommandBinding(uiApp, eventTarget); - if (toggle_on) - cmdBinding.Executed += hndlr.AddInCommandBinding_Executed; - else - cmdBinding.Executed -= hndlr.AddInCommandBinding_Executed; - } - break; - - case EventType.Application_JournalUpdated: - if (toggle_on) { - ActivateJournalListener(uiApp); - journalListener.OnJournalUpdate += hndlr.Application_JournalUpdated; - journalListener.JournalUpdateEvents = true; - } - else if (journalListener != null) { - journalListener.OnJournalUpdate -= hndlr.Application_JournalUpdated; - journalListener.JournalUpdateEvents = false; - DeactivateJournalListener(uiApp); - } - break; - - case EventType.Application_JournalCommandExecuted: - if (toggle_on) { - ActivateJournalListener(uiApp); - journalListener.OnJournalCommandExecuted += hndlr.Application_JournalCommandExecuted; - journalListener.JournalCommandExecutedEvents = true; - } - else if (journalListener != null) { - journalListener.OnJournalCommandExecuted -= hndlr.Application_JournalCommandExecuted; - journalListener.JournalCommandExecutedEvents = false; - DeactivateJournalListener(uiApp); - } - break; - - case EventType.Application_IUpdater: - if (toggle_on) { - ActivateUpdaterListener(); - updaterListener.OnUpdaterExecute += hndlr.Application_IUpdater; - } - else if (updaterListener != null) { - updaterListener.OnUpdaterExecute -= hndlr.Application_IUpdater; - DeactivateUpdaterListener(); - } - break; - } - } - } - - public class AppEventUtils { - } - - public class UIAppEventUtils { - public static Visual GetWindowRoot(UIApplication uiapp) { - IntPtr wndHndle = IntPtr.Zero; - try { -#if (REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018) - wndHndle = Autodesk.Windows.ComponentManager.ApplicationWindow; -#else - wndHndle = uiapp.MainWindowHandle; -#endif - - } - catch { } - - if (wndHndle != IntPtr.Zero) { - var wndSource = HwndSource.FromHwnd(wndHndle); - return wndSource.RootVisual; - } - return null; - } - } - - public static class DocumentEventUtils { - private static bool _txnCompleted = false; - private static Document _doc = null; - private static string _txnName = null; - private static BuiltInParameter _paramToUpdate; - private static string _paramToUpdateStringValue = null; - private static UIApplication _uiApp = null; - private static List _newElements = null; - - private static void OnDocumentChanged(object sender, DocumentChangedEventArgs e) { - if (_newElements == null) - _newElements = new List(); - _newElements.AddRange(e.GetAddedElementIds()); - } - - private static void CancelAllDialogs(object sender, DialogBoxShowingEventArgs e) { - if (e.Cancellable) { -#if (REVIT2013 || REVIT2014) - e.Cancel = true; -#else - e.Cancel(); -#endif - } - else - e.OverrideResult(1); - } - - private static void NewElementPropertyValueUpdater(object sender, IdlingEventArgs e) { - // cancel if txn is completed - if (_txnCompleted) { - _uiApp.Idling -= NewElementPropertyValueUpdater; - EndCancellingAllDialogs(); - EndTrackingElements(); - } - - // now update element parameters - try { - var TXN = new Transaction(_doc, _txnName); - TXN.Start(); - foreach (var newElId in _newElements) { - var element = _doc.GetElement(newElId); - if (element != null) { - var parameter = element.get_Parameter(_paramToUpdate); - if (parameter != null && !parameter.IsReadOnly) - parameter.Set(_paramToUpdateStringValue); - } - } - TXN.Commit(); - } - catch { - } - - _txnCompleted = true; - } - - private static void Init() { - _txnCompleted = false; - _doc = null; - _txnName = null; - _paramToUpdateStringValue = null; - _uiApp = null; - _newElements = null; - } - - private static void StartTrackingElements() { - _uiApp.Application.DocumentChanged += OnDocumentChanged; - } - - private static void EndTrackingElements() { - _uiApp.Application.DocumentChanged -= OnDocumentChanged; - } - - private static void StartCancellingAllDialogs() { - _uiApp.DialogBoxShowing += CancelAllDialogs; - } - - private static void EndCancellingAllDialogs() { - _uiApp.DialogBoxShowing -= CancelAllDialogs; - } - - private static void PostElementPropertyUpdateRequest(Document doc, string txnName, BuiltInParameter bip, string value) { - _doc = doc; - _txnName = txnName; - _paramToUpdate = bip; - _paramToUpdateStringValue = value; - _uiApp.Idling += NewElementPropertyValueUpdater; - } - -#if !(REVIT2013) - public static void PostCommandAndUpdateNewElementProperties(UIApplication uiapp, Document doc, PostableCommand postableCommand, string transactionName, BuiltInParameter bip, string value) { - Init(); - - _uiApp = uiapp; - StartTrackingElements(); - StartCancellingAllDialogs(); - - var postableCommandId = RevitCommandId.LookupPostableCommandId(postableCommand); - _uiApp.PostCommand(postableCommandId); - - PostElementPropertyUpdateRequest(doc, transactionName, bip, value); - } -#endif - } - - public class PlaceKeynoteExternalEventHandler : IExternalEventHandler { - public string KeynoteKey = null; -#if !(REVIT2013) - public PostableCommand KeynoteType = PostableCommand.UserKeynote; -#endif - public void Execute(UIApplication uiApp) { -#if !(REVIT2013) - DocumentEventUtils.PostCommandAndUpdateNewElementProperties( - uiApp, - uiApp.ActiveUIDocument.Document, - KeynoteType, - "Update", - BuiltInParameter.KEY_VALUE, - KeynoteKey - ); -#else - throw new NotSupportedFeatureException(); -#endif - } - - public string GetName() { - return "PlaceKeynoteExternalEvent"; - } - } - - // https://tinyurl.com/yj8x4azp - public class HSLColor { - public readonly double h, s, l, a; - - public HSLColor(double h, double s, double l, double a) { - this.h = h; - this.s = s; - this.l = l; - this.a = a; - } - - public HSLColor(System.Windows.Media.Color rgb) { - RgbToHls(rgb.R, rgb.G, rgb.B, out h, out l, out s); - a = rgb.A / 255.0; - } - - public System.Windows.Media.Color ToRgb() { - int r, g, b; - HlsToRgb(h, l, s, out r, out g, out b); - return System.Windows.Media.Color.FromArgb((byte)(a * 255.0), (byte)r, (byte)g, (byte)b); - } - - public HSLColor Lighten(double amount) { - return new HSLColor(h, s, Clamp(l * amount, 0, 1), a); - } - - public float Luminance { - get { - var c = ToRgb(); - return 0.2126f * c.R + 0.7152f * c.G + 0.0722f * c.B; - } - } - - static double Clamp(double value, double min, double max) { - if (value < min) - return min; - if (value > max) - return max; - - return value; - } - - // Convert an RGB value into an HLS value. - static void RgbToHls(int r, int g, int b, - out double h, out double l, out double s) { - // Convert RGB to a 0.0 to 1.0 range. - double double_r = r / 255.0; - double double_g = g / 255.0; - double double_b = b / 255.0; - - // Get the maximum and minimum RGB components. - double max = double_r; - if (max < double_g) max = double_g; - if (max < double_b) max = double_b; - - double min = double_r; - if (min > double_g) min = double_g; - if (min > double_b) min = double_b; - - double diff = max - min; - l = (max + min) / 2; - if (Math.Abs(diff) < 0.00001) { - s = 0; - h = 0; // H is really undefined. - } - else { - if (l <= 0.5) s = diff / (max + min); - else s = diff / (2 - max - min); - - double r_dist = (max - double_r) / diff; - double g_dist = (max - double_g) / diff; - double b_dist = (max - double_b) / diff; - - if (double_r == max) h = b_dist - g_dist; - else if (double_g == max) h = 2 + r_dist - b_dist; - else h = 4 + g_dist - r_dist; - - h = h * 60; - if (h < 0) h += 360; - } - } - - // Convert an HLS value into an RGB value. - static void HlsToRgb(double h, double l, double s, - out int r, out int g, out int b) { - double p2; - if (l <= 0.5) p2 = l * (1 + s); - else p2 = l + s - l * s; - - double p1 = 2 * l - p2; - double double_r, double_g, double_b; - if (s == 0) { - double_r = l; - double_g = l; - double_b = l; - } - else { - double_r = QqhToRgb(p1, p2, h + 120); - double_g = QqhToRgb(p1, p2, h); - double_b = QqhToRgb(p1, p2, h - 120); - } - - // Convert RGB to the 0 to 255 range. - r = (int)(double_r * 255.0); - g = (int)(double_g * 255.0); - b = (int)(double_b * 255.0); - } - - static double QqhToRgb(double q1, double q2, double hue) { - if (hue > 360) hue -= 360; - else if (hue < 0) hue += 360; - - if (hue < 60) return q1 + (q2 - q1) * hue / 60; - if (hue < 180) return q2; - if (hue < 240) return q1 + (q2 - q1) * (240 - hue) / 60; - return q1; - } - - } - - public class TabColoringRule { - public SolidColorBrush Brush { get; set; } - public Regex TitleFilter { get; set; } - - public TabColoringRule(SolidColorBrush brush, string filter = null) { - Brush = brush; - try { - if (filter is string regexFilter) - TitleFilter = new Regex(regexFilter); - } - catch { - } - } - - public bool IsMatch(string tabTitle) { - if (TitleFilter is Regex filter) - return filter.IsMatch(tabTitle); - return false; - } - } - - public class TabColoringStyle { - public string Name { get; private set; } - - public Thickness BorderThickness { get; set; } = new Thickness(); - public bool FillBackground { get; set; } = false; - - public TabColoringStyle(string name) => Name = name; - - public static readonly Thickness DefaultBorderThickness = new Thickness(); - public static readonly Brush DefaultBorderBrush = Brushes.White; - public static readonly Brush DefaultBackground = Brushes.Transparent; - public static readonly Brush DefaultSelectedBackground = Brushes.White; - public static readonly Brush DefaultForeground = Brushes.Black; - public static readonly Brush LightForeground = Brushes.White; - - public Style CreateStyle(TabItem ctrl, TabColoringRule rule) { - // create a style based on given control - Style tabStyle = new Style(typeof(TabItem), ctrl.Style); - - // setup hsl color for color modifications - var hslColor = new HSLColor(rule.Brush.Color); - - // triggers - var triggerSelected = new Trigger { - Property = TabItem.IsSelectedProperty, - Value = true - }; - var triggerMouseOver = new Trigger { - Property = TabItem.IsMouseOverProperty, - Value = true - }; - - // apply background styling - if (FillBackground) { - tabStyle.Setters.Add( - new Setter { Property = TabItem.BackgroundProperty, Value = rule.Brush } - ); - - // highlighitng on triggers - var bgHightlightBrush = new SolidColorBrush(hslColor.Lighten(1.1).ToRgb()); - triggerMouseOver.Setters.Add( - new Setter { Property = TabItem.BackgroundProperty, Value = bgHightlightBrush } - ); - triggerSelected.Setters.Add( - new Setter { Property = TabItem.BackgroundProperty, Value = bgHightlightBrush } - ); - - // forground based on background - var forgeround = hslColor.Luminance > 127.0f ? DefaultForeground : LightForeground; - tabStyle.Setters.Add( - new Setter { Property = TabItem.ForegroundProperty, Value = forgeround } - ); - // setting forground on the "close" inner button - tabStyle.Resources["ClientAreaForegroundBrush"] = forgeround; - } - - // apply border styling - tabStyle.Setters.Add( - new Setter { Property = TabItem.BorderBrushProperty, Value = rule.Brush } - ); - tabStyle.Setters.Add( - new Setter { Property = TabItem.BorderThicknessProperty, Value = BorderThickness } - ); - - // highlighting borders on triggers - var borderHighlightBrush = new SolidColorBrush(hslColor.Lighten(0.9).ToRgb()); - // selected tab hides the bottom border - var selectedThickness = new Thickness(BorderThickness.Left, BorderThickness.Top, BorderThickness.Right, 0); - triggerSelected.Setters.Add( - new Setter { Property = TabItem.BorderThicknessProperty, Value = FillBackground ? new Thickness(1,1,1,0) : selectedThickness } - ); - - // apply border highlighting only when background is active, otherwise the difference is not visible - if (FillBackground) { - triggerSelected.Setters.Add( - new Setter { Property = TabItem.BorderBrushProperty, Value = Brushes.White } - ); - } else { - triggerSelected.Setters.Add( - new Setter { Property = TabItem.BorderBrushProperty, Value = borderHighlightBrush } - ); - } - - triggerMouseOver.Setters.Add( - new Setter { Property = TabItem.BorderBrushProperty, Value = borderHighlightBrush } - ); - - // add triggers to style - tabStyle.Triggers.Add(triggerSelected); - tabStyle.Triggers.Add(triggerMouseOver); - - return tabStyle; - } - } - - public class TabColoringTheme { - public class RuleSlot { - public TabColoringRule Rule { get; private set; } - - public RuleSlot(TabColoringRule rule) => Rule = rule; - - public long Id { get; set; } - public bool IsFamily { get; set; } - - public void Clear() { - Id = -1; - IsFamily = false; - } - } - - public bool SortDocTabs { get; set; } = false; - - public TabColoringStyle TabStyle { get; set; } - public TabColoringStyle FamilyTabStyle { get; set; } - - public List _tabOrderRules = default; - public List TabOrderRules { - get { - if (_tabOrderRules is null) - _tabOrderRules = new List(); - return _tabOrderRules; - } - - set { - if (value is null) - _tabOrderRules = new List(); - else - _tabOrderRules = value; - } - } - - public List _tabFilterRules = default; - public List TabFilterRules { - get { - if (_tabFilterRules is null) - _tabFilterRules = new List(); - return _tabFilterRules; - } - - set { - if (value is null) - _tabFilterRules = new List(); - else - _tabFilterRules = value; - } - } - - public static readonly List DefaultBrushes = new List { - PyRevitConsts.PyRevitAccentBrush, - PyRevitConsts.PyRevitBackgroundBrush, - Brushes.Blue, - Brushes.SaddleBrown, - Brushes.Gold, - Brushes.DarkTurquoise, - Brushes.OrangeRed, - Brushes.Aqua, - Brushes.YellowGreen, - Brushes.DeepPink - }; - - public static readonly uint DefaultTabColoringStyleIndex = 0; - public static readonly uint DefaultFamilyTabColoringStyleIndex = 4; - - public static readonly List AvailableStyles = new List { - new TabColoringStyle("Top Bar - Light") { BorderThickness = new Thickness(0,1,0,0) }, - new TabColoringStyle("Top Bar - Medium") { BorderThickness = new Thickness(0,2,0,0) }, - new TabColoringStyle("Top Bar - Heavy") { BorderThickness = new Thickness(0,3,0,0) }, - new TabColoringStyle("Top Bar - Heavier") { BorderThickness = new Thickness(0,4,0,0) }, - new TabColoringStyle("Border - Light") { BorderThickness = new Thickness(1) }, - new TabColoringStyle("Border - Medium") { BorderThickness = new Thickness(2) }, - new TabColoringStyle("Border - Heavy") { BorderThickness = new Thickness(3) }, - new TabColoringStyle("Border - Heavier") { BorderThickness = new Thickness(4) }, - new TabColoringStyle("Background Fill") { BorderThickness = new Thickness(2), FillBackground = true }, - }; - - - // keep a unique hash for the state of open tabs - // this helps refreshing the tab styling only once - string _lastTabState = string.Empty; - - // storage for tab original styles set. this is used when resetting tabs - Dictionary _tabOrigStyles = new Dictionary(); - - // used slots for coloring rules - List _ruleSlots = new List(); - - public List StyledDocuments => _ruleSlots.ToList(); - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018) - static string GetTabUniqueId(TabItem tab) { - return $"{((LayoutDocument)tab.Header).Title}+{tab.GetHashCode()}+{tab.IsSelected}"; - } - - static long GetTabDocumentId(TabItem tab) { - return ( - (MFCMDIFrameHost)( - (MFCMDIChildFrameControl)( - (LayoutDocument)tab.Content - ).Content - ).Content - ).document.ToInt64(); - } - - static long GetAPIDocumentId(Document doc) { - MethodInfo getMFCDocMethod = doc.GetType().GetMethod("getMFCDoc", BindingFlags.Instance | BindingFlags.NonPublic); - object mfcDoc = getMFCDocMethod.Invoke(doc, new object[] { }); - MethodInfo ptfValMethod = mfcDoc.GetType().GetMethod("GetPointerValue", BindingFlags.Instance | BindingFlags.NonPublic); - return ((IntPtr)ptfValMethod.Invoke(mfcDoc, new object[] { })).ToInt64(); - } - public void SetTheme(UIApplication uiApp, IEnumerable docTabs) { - // dont do anything if it is the same tabs as before - string newState = string.Join(";", docTabs.Select(t => GetTabUniqueId(t))); - if (newState == _lastTabState) - return; - else - _lastTabState = newState; - - - // collect ids of family documents - var docIds = new List(); - var familyDocIds = new List(); - foreach (Document doc in uiApp.Application.Documents) { - // skip linked docs. they don't have tabs - if (doc.IsLinked) - continue; - - var docId = GetAPIDocumentId(doc); - docIds.Add(docId); - if (doc.IsFamilyDocument) - familyDocIds.Add(docId); - } - - // cleanup styling for docs that do no exists anymore - // empty this before setting new styles so empty slots can be taken - var removedDocs = _ruleSlots.Where(d => !docIds.Contains(d.Id)).ToList(); - foreach (RuleSlot rslot in removedDocs) - rslot.Clear(); - - // cleanup any recorded tabs that do not exist anymore - var removedTabs = _tabOrigStyles.Keys.Where(t => !docTabs.Contains(t)).ToList(); - foreach (TabItem tab in removedTabs) - _tabOrigStyles.Remove(tab); - - // go over each tab and apply style - foreach (TabItem tab in docTabs) { - long docId = GetTabDocumentId(tab); - - // store original style, if it has not been stored yet - if (!_tabOrigStyles.ContainsKey(tab)) - _tabOrigStyles[tab] = tab.Style; - - // set style - Set( - tab: tab, - docId: docId, - isFamilyTab: familyDocIds.Contains(docId) - ); - } - } - - void Set(TabItem tab, long docId, bool isFamilyTab) { - // determine style - TabColoringStyle tstyle = isFamilyTab ? FamilyTabStyle : TabStyle; - - string title = ((LayoutDocument)tab.Header).Title; - - // apply colors by filter - bool filtered = false; - foreach (var rule in TabFilterRules) { - //if tab title does not match the filter do not do anything - if (!rule.IsMatch(title)) - continue; - - tab.Style = tstyle.CreateStyle(tab, rule); - filtered = true; - break; - } - - // if filter is applied to the tab, move on to next - if (filtered) return; - - // otherwise apply colors by order - // if a rule for this doc exist, use that - var docSlot = _ruleSlots.Where(d => d.Id == docId).FirstOrDefault(); - if (docSlot is RuleSlot) { - Style style = tstyle.CreateStyle(tab, docSlot.Rule); - tab.Style = style; - } - // otherwise determine next rule to use - else { - RuleSlot slot = null; - - // if rule slots has space for more slots, - if (_ruleSlots != null && _ruleSlots.Count() >= 1) { - int nextRuleIndex = _ruleSlots.Count(); - // if rules slots are full - if (nextRuleIndex >= TabOrderRules.Count) { - // but have a previously used slot with no doc (slot was used but doc is closed now) - var firstEmptySlot = _ruleSlots.Where(r => r.Id == -1).FirstOrDefault(); - if (firstEmptySlot is RuleSlot) { - slot = firstEmptySlot; - slot.Id = docId; - slot.IsFamily = isFamilyTab; - } - } - // otherwise create a new slot with the next rule - else { - slot = new RuleSlot(TabOrderRules[nextRuleIndex]) { - Id = docId, - IsFamily = isFamilyTab, - }; - _ruleSlots.Add(slot); - } - } - // otherwise, create the first slot, with the first rule - else { - if (TabOrderRules.Count > 0) { - slot = new RuleSlot(TabOrderRules.First()) { - Id = docId, - IsFamily = isFamilyTab, - }; - _ruleSlots.Add(slot); - } - } - - - // if a slot is found, use the rule to create a new override - // framework style for the tab control - if (slot is RuleSlot) { - Style style = tstyle.CreateStyle(tab, slot.Rule); - tab.Style = style; - } - } - } -#endif - - public void ClearTheme(UIApplication uiApp, IEnumerable docTabs) { - foreach (TabItem tab in docTabs) - if (_tabOrigStyles.TryGetValue(tab, out var tabStyle)) - tab.Style = tabStyle; - _tabOrigStyles.Clear(); - _lastTabState = string.Empty; - } - - internal void ResetSlots() { - _ruleSlots.Clear(); - _lastTabState = string.Empty; - } - - internal void InitSlots(TabColoringTheme theme) { - // copy the reserved slots in previous theme to new one - int ruleCount = TabOrderRules.Count(); - if (ruleCount > 0) { - int index = 0; - foreach (RuleSlot slot in theme._ruleSlots) { - if (index >= ruleCount) - break; - - _ruleSlots.Add( - new RuleSlot(TabOrderRules[index]) { - Id = slot.Id, - IsFamily = slot.IsFamily - } - ); - index++; - } - } - } - } - - public static class DocumentTabEventUtils { - static readonly Logger logger = LogManager.GetCurrentClassLogger(); - - public static UIApplication UIApp { get; private set; } - - public static bool IsUpdatingDocumentTabs { get; private set; } - - static object UpdateLock = new object(); - - static TabColoringTheme _tabColoringTheme = null; - public static TabColoringTheme TabColoringTheme { - get => _tabColoringTheme; - set { - // when a new theme is applied, it should adopt the previous slots - // with the new rules - if (value is TabColoringTheme && _tabColoringTheme != null) - value.InitSlots(_tabColoringTheme); - _tabColoringTheme = value; - } - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018) - public static Xceed.Wpf.AvalonDock.DockingManager GetDockingManager(UIApplication uiapp) { - var wndRoot = (MainWindow)UIAppEventUtils.GetWindowRoot(uiapp); - if (wndRoot != null) { - return MainWindow.FindFirstChild(wndRoot); - } - return null; - } - - public static LayoutDocumentPaneGroupControl GetDocumentTabGroup(UIApplication uiapp) { - var wndRoot = UIAppEventUtils.GetWindowRoot(uiapp); - if (wndRoot != null) { - return MainWindow.FindFirstChild((MainWindow)wndRoot); - } - return null; - } - - public static IEnumerable GetDocumentPanes(LayoutDocumentPaneGroupControl docTabGroup) { - if (docTabGroup != null) { - return docTabGroup.FindVisualChildren(); - } - return new List(); - } - - public static DocumentPaneTabPanel GetDocumentTabsPane(LayoutDocumentPaneGroupControl docTabGroup) { - return docTabGroup?.FindVisualChildren()?.FirstOrDefault(); - } - - public static IEnumerable GetDocumentTabs(LayoutDocumentPaneControl docPane) { - if (docPane != null) { - return docPane.FindVisualChildren(); - } - return new List(); - } - - public static IEnumerable GetDocumentTabs(LayoutDocumentPaneGroupControl docTabGroup) { - if (docTabGroup != null) { - return docTabGroup.FindVisualChildren(); - } - return new List(); - } - - public static void StartGroupingDocumentTabs(UIApplication uiapp) { - lock (UpdateLock) { - if (!IsUpdatingDocumentTabs) { - UIApp = uiapp; - IsUpdatingDocumentTabs = true; - - var docMgr = GetDockingManager(UIApp); - docMgr.LayoutUpdated += UpdateDockingManagerLayout; - } - } - } - - public static void StopGroupingDocumentTabs() { - lock (UpdateLock) { - if (IsUpdatingDocumentTabs) { - var docMgr = GetDockingManager(UIApp); - docMgr.LayoutUpdated -= UpdateDockingManagerLayout; - - ClearDocumentTabGroups(); - - IsUpdatingDocumentTabs = false; - } - } - } - - public static void ResetGroupingDocumentTabs() => _tabColoringTheme?.ResetSlots(); - - static void UpdateDockingManagerLayout(object sender, EventArgs e) { - UpdateDocumentTabGroups(); - } - - static void ClearDocumentTabGroups() { - lock (UpdateLock) { - var docTabGroup = GetDocumentTabGroup(UIApp); - if (docTabGroup != null) { - var docTabs = GetDocumentTabs(docTabGroup); - // dont do anything if there are no tabs - if (docTabs.Count() == 0) - return; - - // reset tabs - if (TabColoringTheme is TabColoringTheme theme) - theme.ClearTheme(UIApp, docTabs); - } - } - } - - static void UpdateDocumentTabGroups() { - lock (UpdateLock) { - if (IsUpdatingDocumentTabs) { - // get the ui tabs - var docTabGroup = GetDocumentTabGroup(UIApp); - if (docTabGroup != null) { - var docTabs = GetDocumentTabs(docTabGroup); - - // dont do anything if there are no tabs - if (docTabs.Count() == 0) - return; - - // update tabs - if (TabColoringTheme is TabColoringTheme theme) - theme.SetTheme(UIApp, docTabs); - } - } - } - } -#endif - } - - public static class RibbonEventUtils { - private static readonly Logger logger = LogManager.GetCurrentClassLogger(); - - public static bool IsUpdatingRibbon { get; private set; } - private static object UpdateLock = new object(); - - // updating flow direction on tabs - public static StackPanel PanelSet; - public static string RibbonTabTag; - public static System.Windows.FlowDirection FlowDirection { get; set; } - - public static void StartUpdatingRibbon(StackPanel panelSet, System.Windows.FlowDirection flowDir, string tagTag) { - PanelSet = panelSet; - FlowDirection = flowDir; - RibbonTabTag = tagTag; - - if (PanelSet != null && RibbonTabTag != null) { - PanelSet.LayoutUpdated += PanelSet_LayoutUpdated; - IsUpdatingRibbon = true; - } - } - - public static void StopUpdatingRibbon() { - FlowDirection = System.Windows.FlowDirection.LeftToRight; - - // reset the ui to default flow direction - if (PanelSet != null && RibbonTabTag != null) { - PanelSet.LayoutUpdated -= PanelSet_LayoutUpdated; - SetTabFlowDirection(); - } - - RibbonTabTag = null; - IsUpdatingRibbon = false; - } - - public static void PanelSet_LayoutUpdated(object sender, EventArgs e) { - lock (UpdateLock) { - SetTabFlowDirection(); - } - } - - public static void SetTabFlowDirection() { - foreach (ContentPresenter cpresenter in PanelSet.Children.OfType()) { - if (cpresenter.DataContext is Autodesk.Windows.RibbonTab) { - var ribbonTab = (Autodesk.Windows.RibbonTab)cpresenter.DataContext; - if (ribbonTab.Tag is string - && (string)ribbonTab.Tag == RibbonTabTag - && cpresenter.FlowDirection != FlowDirection) - cpresenter.FlowDirection = FlowDirection; - } - } - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/EventHooks.cs b/dev/pyRevitLabs.PyRevit.Runtime/EventHooks.cs deleted file mode 100644 index b2933fccd..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/EventHooks.cs +++ /dev/null @@ -1,434 +0,0 @@ -using System; -using System.IO; -using System.Linq; -using System.Collections.Generic; - -using Autodesk.Revit.UI; -using Autodesk.Revit.DB; - -using pyRevitLabs.Common; - -using pyRevitLabs.NLog; -using Autodesk.Revit.UI.Events; - -namespace PyRevitLabs.PyRevit.Runtime { - public class EventHook { - public const string id_key = "id"; - public const string name_key = "name"; - public const string target_key = "target"; - public const string script_key = "script"; - public const string syspaths_key = "syspaths"; - public const string extension_name_key = "extension_name"; - - public string EventName; - public string EventTarget; - public string Script; - public string[] SearchPaths; - public string ExtensionName; - public string UniqueId; - - public EventType? EventType { - get { - return EventUtils.GetEventType(EventName); - } - } - - public EventHook(string uniqueId, string eventName, string eventTarget, string scriptPath, string syspaths, string extension_name) { - UniqueId = uniqueId; - EventName = eventName; - EventTarget = eventTarget; - Script = scriptPath; - SearchPaths = syspaths.Split(Path.PathSeparator); - ExtensionName = extension_name; - } - - public override int GetHashCode() { - return UniqueId.GetHashCode(); - } - - public static bool IsValid(string eventName) { - return EventUtils.GetEventType(eventName) != null; - } - } - - public class EventHooks : IEventTypeHandler { - static Logger logger = LogManager.GetCurrentClassLogger(); - - public string HandlerId; - - public EventHooks(string handlerId) { - if (handlerId == null) - handlerId = Guid.NewGuid().ToString(); - HandlerId = handlerId; - } - - public static int Execute(EventHook eventHook, object eventSender, object eventArgs) { - var env = new EnvDictionary(); - return ScriptExecutor.ExecuteScript( - scriptData: new ScriptData { - ScriptPath = eventHook.Script, - ConfigScriptPath = eventHook.Script, - CommandUniqueId = eventHook.UniqueId, - CommandName = string.Format("hooks.{0}", Path.GetFileNameWithoutExtension(eventHook.Script)), - CommandBundle = string.Format("{0}.hooks", eventHook.ExtensionName), - CommandExtension = eventHook.ExtensionName, - HelpSource = "", - }, - scriptRuntimeCfg: new ScriptRuntimeConfigs { - CommandData = null, - SelectedElements = new ElementSet(), - SearchPaths = new List(eventHook.SearchPaths), - Arguments = new List(), - EventSender = eventSender, - EventArgs = eventArgs, - EngineConfigs = " { \"full_frame\" : true } ", - RefreshEngine = false, - ConfigMode = false, - DebugMode = false, - ExecutedFromUI = false - }, - scriptExecConfigs: new ScriptExecutorConfigs { - SendTelemetry = env.TelemetryState && env.TelemetryIncludeHooks - } - ); - } - - public static List GetAllEventHooks() { - var env = new EnvDictionary(); - var eventHooks = new List(); - foreach (KeyValuePair> eventHookInfo in env.EventHooks) { - var eventName = eventHookInfo.Value[EventHook.name_key]; - if (EventHook.IsValid(eventName)) { - eventHooks.Add(new EventHook( - uniqueId: eventHookInfo.Value[EventHook.id_key], - eventName: eventName, - eventTarget: eventHookInfo.Value[EventHook.target_key], - scriptPath: eventHookInfo.Value[EventHook.script_key], - syspaths: eventHookInfo.Value[EventHook.syspaths_key], - extension_name: eventHookInfo.Value[EventHook.extension_name_key] - )); - } - } - return eventHooks; - } - - public static List GetEventHooks(EventType eventType, string eventTarget = null) { - var eventName = EventUtils.GetEventName(eventType); - if (eventTarget != null) - return GetAllEventHooks().Where(x => x.EventName == eventName && x.EventTarget == eventTarget).ToList(); - else - return GetAllEventHooks().Where(x => x.EventName == eventName).ToList(); - } - - public void ExecuteEventHooks(EventType eventType, object eventSender, object eventArgs, string eventTarget = null) { - try { - //var logMsg = string.Format("Executing event hook {0}", eventType.ToString()); - foreach (EventHook eventHook in GetEventHooks(eventType, eventTarget)) - Execute( - eventHook: eventHook, - eventSender: eventSender, - eventArgs: eventArgs - ); - } - catch { - //var logMsg = string.Join(Environment.NewLine, ex.Message, ex.StackTrace, SessionUUID); - } - } - - public void ActivateEventType(UIApplication uiApp, EventType eventType, string eventTarget = null) { - try { - // remove first - EventUtils.ToggleHooks(this, uiApp, eventType, eventTarget: eventTarget, toggle_on: false); - // then add again - EventUtils.ToggleHooks(this, uiApp, eventType, eventTarget: eventTarget); - } - catch (NotSupportedFeatureException) { - logger.Debug(string.Format("Hook type {0} not supported under this Revit version. Skipped.", - eventType.ToString())); - } - catch (Exception) { - logger.Debug(string.Format("Failed registering hook type {0}", eventType.ToString())); - } - } - - public void DeactivateEventType(UIApplication uiApp, EventType eventType, string eventTarget = null) { - try { - EventUtils.ToggleHooks(this, uiApp, eventType, eventTarget: eventTarget, toggle_on: false); - } - catch (NotSupportedFeatureException) { - logger.Debug(string.Format("Hook type {0} not supported under this Revit version. Skipped.", - eventType.ToString())); - } - catch (Exception) { - logger.Debug(string.Format("Failed unregistering hook type {0}", eventType.ToString())); - } - } - - public void RegisterHook(string uniqueId, string eventName, string eventTarget, string scriptPath, string[] searchPaths, string extensionName) { - if (EventHook.IsValid(eventName)) { - var env = new EnvDictionary(); - env.EventHooks[uniqueId] = new Dictionary { - { EventHook.id_key, uniqueId }, - { EventHook.name_key, eventName }, - { EventHook.target_key, eventTarget }, - { EventHook.script_key, scriptPath }, - { EventHook.syspaths_key, string.Join(Path.PathSeparator.ToString(), searchPaths) }, - { EventHook.extension_name_key, extensionName }, - }; - } - else - throw new PyRevitException("Invalid hook type"); - } - - public void UnRegisterHook(string uniqueId) { - var env = new EnvDictionary(); - if (env.EventHooks.ContainsKey(uniqueId)) - env.EventHooks.Remove(uniqueId); - } - - public void UnRegisterAllHooks(UIApplication uiApp) { - var env = new EnvDictionary(); - env.ResetEventHooks(); - } - - public void ActivateEventHooks(UIApplication uiApp) { - foreach (var eventHook in GetAllEventHooks()) - if (eventHook.EventType != null) - ActivateEventType(uiApp, (EventType)eventHook.EventType, eventHook.EventTarget); - } - - public void DeactivateEventHooks(UIApplication uiApp) { - foreach (var eventHook in GetAllEventHooks()) - if (eventHook.EventType != null) - DeactivateEventType(uiApp, (EventType)eventHook.EventType, eventHook.EventTarget); - } - - // event handlers -------------------------------------------------------------------------------------------- - - public void UIApplication_ViewActivating(object sender, Autodesk.Revit.UI.Events.ViewActivatingEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_ViewActivating, sender, e); - } - - public void UIApplication_ViewActivated(object sender, Autodesk.Revit.UI.Events.ViewActivatedEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_ViewActivated, sender, e); - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - public void UIApplication_TransferringProjectStandards(object sender, Autodesk.Revit.UI.Events.TransferringProjectStandardsEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_TransferringProjectStandards, sender, e); - } - - public void UIApplication_TransferredProjectStandards(object sender, Autodesk.Revit.UI.Events.TransferredProjectStandardsEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_TransferredProjectStandards, sender, e); - } -#endif - - public void UIApplication_Idling(object sender, Autodesk.Revit.UI.Events.IdlingEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_Idling, sender, e); - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018) - public void UIApplication_FormulaEditing(object sender, Autodesk.Revit.UI.Events.FormulaEditingEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_FormulaEditing, sender, e); - } -#endif - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016) - public void UIApplication_FabricationPartBrowserChanged(object sender, Autodesk.Revit.UI.Events.FabricationPartBrowserChangedEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_FabricationPartBrowserChanged, sender, e); - } -#endif - -#if !(REVIT2013 || REVIT2014) - public void UIApplication_DockableFrameVisibilityChanged(object sender, Autodesk.Revit.UI.Events.DockableFrameVisibilityChangedEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_DockableFrameVisibilityChanged, sender, e); - } - - public void UIApplication_DockableFrameFocusChanged(object sender, Autodesk.Revit.UI.Events.DockableFrameFocusChangedEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_DockableFrameFocusChanged, sender, e); - } -#endif - - public void UIApplication_DisplayingOptionsDialog(object sender, Autodesk.Revit.UI.Events.DisplayingOptionsDialogEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_DisplayingOptionsDialog, sender, e); - } - - public void UIApplication_DialogBoxShowing(object sender, Autodesk.Revit.UI.Events.DialogBoxShowingEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_DialogBoxShowing, sender, e); - } - - public void UIApplication_ApplicationClosing(object sender, Autodesk.Revit.UI.Events.ApplicationClosingEventArgs e) { - ExecuteEventHooks(EventType.UIApplication_ApplicationClosing, sender, e); - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - public void Application_WorksharedOperationProgressChanged(object sender, Autodesk.Revit.DB.Events.WorksharedOperationProgressChangedEventArgs e) { - ExecuteEventHooks(EventType.Application_WorksharedOperationProgressChanged, sender, e); - } -#endif - public void Application_ViewPrinting(object sender, Autodesk.Revit.DB.Events.ViewPrintingEventArgs e) { - ExecuteEventHooks(EventType.Application_ViewPrinting, sender, e); - } - - public void Application_ViewPrinted(object sender, Autodesk.Revit.DB.Events.ViewPrintedEventArgs e) { - ExecuteEventHooks(EventType.Application_ViewPrinted, sender, e); - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - public void Application_ViewExporting(object sender, Autodesk.Revit.DB.Events.ViewExportingEventArgs e) { - ExecuteEventHooks(EventType.Application_ViewExporting, sender, e); - } - - public void Application_ViewExported(object sender, Autodesk.Revit.DB.Events.ViewExportedEventArgs e) { - ExecuteEventHooks(EventType.Application_ViewExported, sender, e); - } -#endif - public void Application_ProgressChanged(object sender, Autodesk.Revit.DB.Events.ProgressChangedEventArgs e) { - ExecuteEventHooks(EventType.Application_ProgressChanged, sender, e); - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - public void Application_LinkedResourceOpening(object sender, Autodesk.Revit.DB.Events.LinkedResourceOpeningEventArgs e) { - ExecuteEventHooks(EventType.Application_LinkedResourceOpening, sender, e); - } - - public void Application_LinkedResourceOpened(object sender, Autodesk.Revit.DB.Events.LinkedResourceOpenedEventArgs e) { - ExecuteEventHooks(EventType.Application_LinkedResourceOpened, sender, e); - } -#endif - - public void Application_FileImporting(object sender, Autodesk.Revit.DB.Events.FileImportingEventArgs e) { - ExecuteEventHooks(EventType.Application_FileImporting, sender, e); - } - - public void Application_FileImported(object sender, Autodesk.Revit.DB.Events.FileImportedEventArgs e) { - ExecuteEventHooks(EventType.Application_FileImported, sender, e); - } - - public void Application_FileExporting(object sender, Autodesk.Revit.DB.Events.FileExportingEventArgs e) { - ExecuteEventHooks(EventType.Application_FileExporting, sender, e); - } - - public void Application_FileExported(object sender, Autodesk.Revit.DB.Events.FileExportedEventArgs e) { - ExecuteEventHooks(EventType.Application_FileExported, sender, e); - } - -#if !(REVIT2013 || REVIT2014) - public void Application_FamilyLoadingIntoDocument(object sender, Autodesk.Revit.DB.Events.FamilyLoadingIntoDocumentEventArgs e) { - ExecuteEventHooks(EventType.Application_FamilyLoadingIntoDocument, sender, e); - } - - public void Application_FamilyLoadedIntoDocument(object sender, Autodesk.Revit.DB.Events.FamilyLoadedIntoDocumentEventArgs e) { - ExecuteEventHooks(EventType.Application_FamilyLoadedIntoDocument, sender, e); - } -#endif - - public void Application_FailuresProcessing(object sender, Autodesk.Revit.DB.Events.FailuresProcessingEventArgs e) { - ExecuteEventHooks(EventType.Application_FailuresProcessing, sender, e); - } - -#if !(REVIT2013 || REVIT2014) - public void Application_ElementTypeDuplicating(object sender, Autodesk.Revit.DB.Events.ElementTypeDuplicatingEventArgs e) { - ExecuteEventHooks(EventType.Application_ElementTypeDuplicating, sender, e); - } - - public void Application_ElementTypeDuplicated(object sender, Autodesk.Revit.DB.Events.ElementTypeDuplicatedEventArgs e) { - ExecuteEventHooks(EventType.Application_ElementTypeDuplicated, sender, e); - } - public void Application_DocumentWorksharingEnabled(object sender, Autodesk.Revit.DB.Events.DocumentWorksharingEnabledEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentWorksharingEnabled, sender, e); - } -#endif - - public void Application_DocumentSynchronizingWithCentral(object sender, Autodesk.Revit.DB.Events.DocumentSynchronizingWithCentralEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentSynchronizingWithCentral, sender, e); - } - - public void Application_DocumentSynchronizedWithCentral(object sender, Autodesk.Revit.DB.Events.DocumentSynchronizedWithCentralEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentSynchronizedWithCentral, sender, e); - } - - public void Application_DocumentSavingAs(object sender, Autodesk.Revit.DB.Events.DocumentSavingAsEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentSavingAs, sender, e); - } - - public void Application_DocumentSavedAs(object sender, Autodesk.Revit.DB.Events.DocumentSavedAsEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentSavedAs, sender, e); - } - - public void Application_DocumentSaving(object sender, Autodesk.Revit.DB.Events.DocumentSavingEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentSaving, sender, e); - } - - public void Application_DocumentSaved(object sender, Autodesk.Revit.DB.Events.DocumentSavedEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentSaved, sender, e); - } - - public void Application_DocumentPrinting(object sender, Autodesk.Revit.DB.Events.DocumentPrintingEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentPrinting, sender, e); - } - - public void Application_DocumentPrinted(object sender, Autodesk.Revit.DB.Events.DocumentPrintedEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentPrinted, sender, e); - } - - public void Application_DocumentOpening(object sender, Autodesk.Revit.DB.Events.DocumentOpeningEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentOpening, sender, e); - } - - public void Application_DocumentOpened(object sender, Autodesk.Revit.DB.Events.DocumentOpenedEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentOpened, sender, e); - } - - public void Application_DocumentCreating(object sender, Autodesk.Revit.DB.Events.DocumentCreatingEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentCreating, sender, e); - } - - public void Application_DocumentCreated(object sender, Autodesk.Revit.DB.Events.DocumentCreatedEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentCreated, sender, e); - } - - public void Application_DocumentClosing(object sender, Autodesk.Revit.DB.Events.DocumentClosingEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentClosing, sender, e); - } - - public void Application_DocumentClosed(object sender, Autodesk.Revit.DB.Events.DocumentClosedEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentClosed, sender, e); - } - - public void Application_DocumentChanged(object sender, Autodesk.Revit.DB.Events.DocumentChangedEventArgs e) { - ExecuteEventHooks(EventType.Application_DocumentChanged, sender, e); - } - - public void Application_ApplicationInitialized(object sender, Autodesk.Revit.DB.Events.ApplicationInitializedEventArgs e) { - ExecuteEventHooks(EventType.Application_ApplicationInitialized, sender, e); - } - -#if !(REVIT2013) - public void AddInCommandBinding_BeforeExecuted(object sender, BeforeExecutedEventArgs e) { - ExecuteEventHooks(EventType.AddInCommandBinding_BeforeExecuted, sender, e, e.CommandId.Name); - } -#endif - - public void AddInCommandBinding_CanExecute(object sender, CanExecuteEventArgs e) { - ExecuteEventHooks(EventType.AddInCommandBinding_CanExecute, sender, e, e.CommandId.Name); - } - - public void AddInCommandBinding_Executed(object sender, ExecutedEventArgs e) { - ExecuteEventHooks(EventType.AddInCommandBinding_Executed, sender, e, e.CommandId.Name); - } - - // custom events being called from non-main thread - public void Application_JournalUpdated(object sender, JournalUpdateArgs e) { - ExecuteEventHooks(EventType.Application_JournalUpdated, sender, e); - } - - public void Application_JournalCommandExecuted(object sender, CommandExecutedArgs e) { - ExecuteEventHooks(EventType.Application_JournalCommandExecuted, sender, e); - } - - public void Application_IUpdater(object sender, UpdaterData d) { - ExecuteEventHooks(EventType.Application_IUpdater, sender, d); - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/EventTelemetry.cs b/dev/pyRevitLabs.PyRevit.Runtime/EventTelemetry.cs deleted file mode 100644 index 7fa88263e..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/EventTelemetry.cs +++ /dev/null @@ -1,1163 +0,0 @@ -using System; -using System.Numerics; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; - -using Autodesk.Revit.DB; -using Autodesk.Revit.DB.Events; -using Autodesk.Revit.UI; - -using pyRevitLabs.NLog; -using Autodesk.Revit.UI.Events; - -namespace PyRevitLabs.PyRevit.Runtime { - public class EventTelemetryRecord : TelemetryRecord { - // which event? - public string type { get; set; } - public Dictionary args { get; set; } - public string status { get; set; } - - // by who? - public string username { get; set; } - // on what? - public string handler_id { get; set; } - public string revit { get; set; } - public string revitbuild { get; set; } - - public bool cancellable { get; set; } - public bool cancelled { get; set; } - public int docid { get; set; } - public string doctype { get; set; } - public string doctemplate { get; set; } - public string docname { get; set; } - public string docpath { get; set; } - - public string projectnum { get; set; } - public string projectname { get; set; } - - public EventTelemetryRecord() : base() { } - } - - public delegate void EventTelemetryExternalEventDelegate(UIApplication uiapp, object sender, object e); - - public class EventTelemetryExternalEventHandler : IExternalEventHandler { - public object Sender; - public CommandExecutedArgs CommandExecArgs; - - public EventTelemetryExternalEventDelegate EventTelemetryDelegate; - - public void Execute(UIApplication uiApp) { - if (EventTelemetryDelegate != null) - EventTelemetryDelegate(uiApp, Sender, CommandExecArgs); - } - - public string GetName() { - return "EventTelemetryExternalEventHandler"; - } - } - - public class EventTelemetry : IEventTypeHandler { - private static Logger logger = LogManager.GetCurrentClassLogger(); - - public string HandlerId; - private static EventTelemetryExternalEventHandler extTelemetryEventHandler; - private static ExternalEvent extTelemetryEvent; - - public EventTelemetry(string handlerId, string username) { - if (handlerId == null) - handlerId = Guid.NewGuid().ToString(); - HandlerId = handlerId; - extTelemetryEventHandler = new EventTelemetryExternalEventHandler(); - extTelemetryEvent = ExternalEvent.Create(extTelemetryEventHandler); - - Telemetry.DefaultUser = username; - } - - public static string GetParameterValue(Parameter param) { - switch (param.StorageType) { - case StorageType.Double: return param.AsValueString(); - case StorageType.ElementId: return param.AsValueString(); - case StorageType.Integer: return param.AsValueString(); - case StorageType.String: return param.AsString(); - default: return null; - } - } - - public static List GetElements(Document doc, IEnumerable elementIds) { - var elements = new List(); - if (doc != null) { - foreach (var eid in elementIds) { - if (eid != ElementId.InvalidElementId) { - var element = doc.GetElement(eid); - if (element != null) - elements.Add(element); - } - } - } - return elements; - } - - public static Dictionary GetViewData(Element element) { - var viewData = new Dictionary(); - if (element is View) { - View view = (View)element; - string viewFamilyName = string.Empty; - if (view.Document != null) { - var viewamily = view.Document.GetElement(view.GetTypeId()); - if (viewamily != null) - viewFamilyName = viewamily.Name; - } - - viewData = new Dictionary { - { "type", view.ViewType.ToString() }, - { "family", viewFamilyName }, - { "name", view.Name }, - { "title", view.get_Parameter(BuiltInParameter.VIEW_DESCRIPTION).AsString() }, - }; - } - return viewData; - } - - public static List> GetViewsData(IEnumerable elements) { - var viewsData = new List>(); - foreach (var element in elements) - if (element is View) { - viewsData.Add(GetViewData(element)); - } - return viewsData; - } - - public static Dictionary GetPrintSettings(PrintParameters printParams) { - double marginx, marginy; - int zoom; - string zoom_type; - - // some print parameters throw exceptions - try { -#if !(REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021 || REVIT2022) - marginx = printParams.OriginOffsetX; - marginy = printParams.OriginOffsetY; - -#else - marginx = printParams.UserDefinedMarginX; - marginy = printParams.UserDefinedMarginY; -#endif - } - catch { - marginx = marginy = 0.0; - } - - try { - zoom = printParams.Zoom; - zoom_type = printParams.ZoomType.ToString(); - } - catch { - zoom = 0; - zoom_type = string.Empty; - } - var settings = new Dictionary { - { "color_depth", printParams.ColorDepth.ToString() }, - { "hidden_line_view_type", printParams.HiddenLineViews.ToString() }, - { "hide_cropbounds", printParams.HideCropBoundaries }, - { "hide_refplanes", printParams.HideReforWorkPlanes }, - { "hide_scopeboxes", printParams.HideScopeBoxes }, -#if !(REVIT2013) - { "hide_unref_viewtags", printParams.HideUnreferencedViewTags }, -#else - { "hide_unref_viewtags", null }, -#endif - { "margin_type", printParams.MarginType.ToString() }, -#if !(REVIT2013 || REVIT2014) - { "mask_lines", printParams.MaskCoincidentLines }, -#else - { "mask_lines", null }, -#endif - { "page_orientation", printParams.PageOrientation.ToString() }, - { "paper_placement", printParams.PaperPlacement.ToString() }, - { "paper_size", printParams.PaperSize.Name }, - { "paper_source", printParams.PaperSource.Name }, - { "raster_quality", printParams.RasterQuality.ToString() }, - { "halftone_thinlines", printParams.ReplaceHalftoneWithThinLines }, - { "user_margin_x", marginx }, - { "user_margin_y", marginy }, - { "blue_hyperlinks", printParams.ViewLinksinBlue }, - { "zoom", zoom }, - { "zoom_type", zoom_type }, - }; - - return settings; - } - - public static string GetProjectNumber(Document doc) { - if (doc != null) - return doc.ProjectInformation.get_Parameter(BuiltInParameter.PROJECT_NUMBER).AsString(); - else - return null; - } - - public static string GetProjectName(Document doc) { - if (doc != null) - return doc.ProjectInformation.get_Parameter(BuiltInParameter.PROJECT_NAME).AsString(); - else - return null; - } - - public static Dictionary GetProjectInfo(Document doc) { - var docProps = new Dictionary(); - if (doc != null) { - var pinfo = doc.ProjectInformation; - - var docProjProps = new Dictionary(); - foreach (Parameter param in pinfo.Parameters) -#if !(REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021 || REVIT2022 || REVIT2023) - if (param.Id.Value > 0) -#else - if (param.Id.IntegerValue > 0) -#endif - docProjProps.Add(param.Definition.Name, GetParameterValue(param)); - - docProps = new Dictionary { - { "org_name", pinfo.get_Parameter(BuiltInParameter.PROJECT_ORGANIZATION_NAME).AsString() }, - { "org_description", pinfo.get_Parameter(BuiltInParameter.PROJECT_ORGANIZATION_DESCRIPTION).AsString() }, - { "project_number", GetProjectNumber(doc) }, - { "project_name", GetProjectName(doc) }, - { "project_client_name", pinfo.get_Parameter(BuiltInParameter.CLIENT_NAME).AsString() }, - { "project_building_name", pinfo.get_Parameter(BuiltInParameter.PROJECT_BUILDING_NAME).AsString() }, - { "project_issue_date", pinfo.get_Parameter(BuiltInParameter.PROJECT_ISSUE_DATE).AsString() }, - { "project_status", pinfo.get_Parameter(BuiltInParameter.PROJECT_STATUS).AsString() }, - { "project_author", pinfo.get_Parameter(BuiltInParameter.PROJECT_AUTHOR).AsString() }, - { "project_address", pinfo.get_Parameter(BuiltInParameter.PROJECT_ADDRESS).AsString() }, - { "project_parameters", docProjProps }, - }; - - } - return docProps; - } - - // event management ------------------------------------------------------------------------------------------ - public void LogEventTelemetryRecord(EventTelemetryRecord eventTelemetryRecord, object sender, object args) { - var env = new EnvDictionary(); - - // update general properties on record - // host info - if (sender != null) { - // set the host info based on the sender type - eventTelemetryRecord.username = Telemetry.GetRevitUser(sender); - eventTelemetryRecord.revit = Telemetry.GetRevitVersion(sender); - eventTelemetryRecord.revitbuild = Telemetry.GetRevitBuild(sender); - } - - // set pyrevit info - eventTelemetryRecord.handler_id = HandlerId; - // event general info - var apiEventArgs = args as RevitAPIEventArgs; - if (apiEventArgs != null) { - eventTelemetryRecord.cancellable = ((RevitAPIEventArgs)args).Cancellable; - eventTelemetryRecord.cancelled = ((RevitAPIEventArgs)args).IsCancelled(); - } - else { - var eventArgs = args as RevitEventArgs; - if (eventArgs != null) { - eventTelemetryRecord.cancellable = ((RevitEventArgs)args).Cancellable; - } - } - - // now post the telemetry record - if (env.AppTelemetryState) { - if (env.AppTelemetryServerUrl != null && !string.IsNullOrEmpty(env.AppTelemetryServerUrl)) - new Task(() => - Telemetry.PostTelemetryRecord(env.AppTelemetryServerUrl, eventTelemetryRecord)).Start(); - } - } - - public void RegisterEventTelemetry(UIApplication uiApp, BigInteger flags) { - foreach (EventType eventType in EventUtils.GetAllEventTypes()) - if ((flags & (new BigInteger(1) << (int)eventType)) > 0) { - try { - // remove first - EventUtils.ToggleHooks(this, uiApp, eventType, toggle_on: false); - // then add again - EventUtils.ToggleHooks(this, uiApp, eventType); - } - catch (NotSupportedFeatureException) { - logger.Debug( - string.Format("Event telemetry {0} not supported under this Revit version. Skipped.", - eventType.ToString())); - } - catch { - logger.Debug(string.Format("Failed registering event telemetry {0}", eventType.ToString())); - } - } - - } - - public void UnRegisterEventTelemetry(UIApplication uiApp, BigInteger flags) { - foreach (EventType eventType in Enum.GetValues(typeof(EventType))) - if ((flags & (new BigInteger(1) << (int)eventType)) > 0) - try { - EventUtils.ToggleHooks(this, uiApp, eventType, toggle_on: false); - } - catch (NotSupportedFeatureException) { - logger.Debug( - string.Format("Event telemetry {0} not supported under this Revit version. Skipped.", - eventType.ToString())); - } - catch { - logger.Debug(string.Format("Failed unregistering event telemetry {0}", eventType.ToString())); - } - } - - // event handlers -------------------------------------------------------------------------------------------- - public void UIApplication_ViewActivating(object sender, Autodesk.Revit.UI.Events.ViewActivatingEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_ViewActivating), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "from_view", e.CurrentActiveView != null ? GetViewData(e.CurrentActiveView) : null }, - { "to_view", e.NewActiveView != null ? GetViewData(e.NewActiveView) : null }, - } - }, sender, e); - } - - public void UIApplication_ViewActivated(object sender, Autodesk.Revit.UI.Events.ViewActivatedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_ViewActivated), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "from_view", e.PreviousActiveView != null ? GetViewData(e.PreviousActiveView) : null }, - { "to_view", e.CurrentActiveView != null ? GetViewData(e.CurrentActiveView) : null }, - } - }, sender, e); - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - public void UIApplication_TransferringProjectStandards(object sender, Autodesk.Revit.UI.Events.TransferringProjectStandardsEventArgs e) { - var extItems = new Dictionary(); - foreach (var kvpair in e.GetExternalItems()) - extItems.Add(kvpair.Key.ToString(), kvpair.Value); - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_TransferringProjectStandards), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "from_document", new Dictionary{ - { "docname", e.SourceDocument != null ? e.SourceDocument.Title : "" }, - { "docpath", e.SourceDocument != null ? e.SourceDocument.PathName : "" }, - { "projectnum", GetProjectNumber(e.SourceDocument) }, - { "projectname", GetProjectName(e.SourceDocument) }, - } }, - { "to_document", new Dictionary{ - { "docname", e.TargetDocument != null ? e.TargetDocument.Title : "" }, - { "docpath", e.TargetDocument != null ? e.TargetDocument.PathName : "" }, - { "projectnum", GetProjectNumber(e.TargetDocument) }, - { "projectname", GetProjectName(e.TargetDocument) }, - } }, - { "external_items", extItems }, - } - }, sender, e); - } - - public void UIApplication_TransferredProjectStandards(object sender, Autodesk.Revit.UI.Events.TransferredProjectStandardsEventArgs e) { - var extItems = new Dictionary(); - foreach (var kvpair in e.GetSelectedExternalItems()) - extItems.Add(kvpair.Key.ToString(), kvpair.Value); - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_TransferredProjectStandards), - docname = e.SourceDocument != null ? e.SourceDocument.Title : "", - docpath = e.SourceDocument != null ? e.SourceDocument.PathName : "", - projectnum = GetProjectNumber(e.SourceDocument), - projectname = GetProjectName(e.SourceDocument), - args = new Dictionary { - { "to_document", new Dictionary{ - { "docname", e.TargetDocument != null ? e.TargetDocument.Title : "" }, - { "docpath", e.TargetDocument != null ? e.TargetDocument.PathName : "" }, - { "projectnum", GetProjectNumber(e.TargetDocument) }, - { "projectname", GetProjectName(e.TargetDocument) }, - } }, - { "external_items", extItems }, - } - }, sender, e); - } -#endif - - public void UIApplication_Idling(object sender, Autodesk.Revit.UI.Events.IdlingEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_Idling), - }, sender, e); - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018) - public void UIApplication_FormulaEditing(object sender, Autodesk.Revit.UI.Events.FormulaEditingEventArgs e) { - var paramId = e.ParameterId; -#if !(REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021 || REVIT2022 || REVIT2023) - long paramIdInt = 0; -#else - int paramIdInt = 0; -#endif - string paramName = string.Empty; - Element param = null; - if (paramId != null && paramId != ElementId.InvalidElementId) { - param = e.CurrentDocument != null ? e.CurrentDocument.GetElement(paramId) : param; -#if !(REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021 || REVIT2022 || REVIT2023) - paramIdInt = paramId.Value; -#else - paramIdInt = paramId.IntegerValue; -#endif - paramName = ((ParameterElement)param).Name; - } - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_FormulaEditing), - docname = e.CurrentDocument != null ? e.CurrentDocument.Title : "", - docpath = e.CurrentDocument != null ? e.CurrentDocument.PathName : "", - projectnum = GetProjectNumber(e.CurrentDocument), - projectname = GetProjectName(e.CurrentDocument), - args = new Dictionary { - { "param_id", paramIdInt }, - { "param_name", paramName }, - { "formula", e.Formula }, - } - }, sender, e); - } -#endif - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016) - public void UIApplication_FabricationPartBrowserChanged(object sender, Autodesk.Revit.UI.Events.FabricationPartBrowserChangedEventArgs e) { - // TODO: implement - //e.GetAllSolutionsPartsTypeCounts - //e.GetCurrentSolutionPartTypeIds - //e.GetFabricationPartTypeIds - //e.GetFilteredSolutionsPartsTypeCounts - //e.GetRequiredFabricationPartTypeIds - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_FabricationPartBrowserChanged), - args = new Dictionary { - { "operation", e.Operation.ToString() }, - { "service_id", e.ServiceId }, - { "solutions_count", e.NumberOfSolutions }, - } - }, sender, e); - } -#endif - -#if !(REVIT2013 || REVIT2014) - public void UIApplication_DockableFrameVisibilityChanged(object sender, Autodesk.Revit.UI.Events.DockableFrameVisibilityChangedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_DockableFrameVisibilityChanged), - args = new Dictionary { - { "pane_id", e.PaneId.ToString() }, - { "frame_shown", e.DockableFrameShown }, - } - }, sender, e); - } - - public void UIApplication_DockableFrameFocusChanged(object sender, Autodesk.Revit.UI.Events.DockableFrameFocusChangedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_DockableFrameFocusChanged), - args = new Dictionary { - { "pane_id", e.PaneId.ToString() }, - { "focus_gained", e.FocusGained }, - } - }, sender, e); - } -#endif - - public void UIApplication_DisplayingOptionsDialog(object sender, Autodesk.Revit.UI.Events.DisplayingOptionsDialogEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_DisplayingOptionsDialog), - args = new Dictionary { - { "page_count", e.PagesCount }, - } - }, sender, e); - } - - public void UIApplication_DialogBoxShowing(object sender, Autodesk.Revit.UI.Events.DialogBoxShowingEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_DialogBoxShowing), - args = new Dictionary { -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016) - { "dialog_id", e.DialogId }, -#else - { "dialog_id", null }, -#endif - } - }, sender, e); - } - - public void UIApplication_ApplicationClosing(object sender, Autodesk.Revit.UI.Events.ApplicationClosingEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.UIApplication_ApplicationClosing), - }, sender, e); - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - public void Application_WorksharedOperationProgressChanged(object sender, WorksharedOperationProgressChangedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_WorksharedOperationProgressChanged), - docpath = e.Location, - status = e.Status.ToString(), - }, sender, e); - } -#endif - - public void Application_ViewPrinting(object sender, ViewPrintingEventArgs e) { - var views = new List() { e.View }; - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_ViewPrinting), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "view", GetViewsData(views) }, - { "view_index", e.Index }, - { "total_views", e.TotalViews }, -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016) - { "settings", GetPrintSettings(e.GetSettings().PrintParameters) }, -#else - { "settings", null }, -#endif - } - }, sender, e); - } - - public void Application_ViewPrinted(object sender, ViewPrintedEventArgs e) { - var views = new List() { e.View }; - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_ViewPrinted), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - status = e.Status.ToString(), - args = new Dictionary { - { "view", GetViewsData(views) }, - { "view_index", e.Index }, - { "total_views", e.TotalViews }, - } - }, sender, e); - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - public void Application_ViewExporting(object sender, ViewExportingEventArgs e) { - var views = new List(); - if (e.Document != null) - views.Add(e.Document.GetElement(e.ViewId)); - - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_ViewExporting), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "view", GetViewsData(views) }, - } - }, sender, e); - } - - public void Application_ViewExported(object sender, ViewExportedEventArgs e) { - var views = new List(); - if (e.Document != null) - views.Add(e.Document.GetElement(e.ViewId)); - - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_ViewExported), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - status = e.Status.ToString(), - args = new Dictionary { - { "view", GetViewsData(views) }, - } - }, sender, e); - } -#endif - - public void Application_ProgressChanged(object sender, ProgressChangedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_ProgressChanged), - args = new Dictionary { - { "stage", e.Stage.ToString() }, - { "caption", e.Caption }, - { "position", e.Position }, - { "lower", e.LowerRange }, - { "upper", e.UpperRange }, - } - }, sender, e); - } - -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017) - public void Application_LinkedResourceOpening(object sender, LinkedResourceOpeningEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_LinkedResourceOpening), - args = new Dictionary { - { "link_path", e.LinkedResourcePathName }, - { "link_type", e.ResourceType.ToString() }, - } - }, sender, e); - } - - public void Application_LinkedResourceOpened(object sender, LinkedResourceOpenedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_LinkedResourceOpened), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - status = e.Status.ToString(), - args = new Dictionary { - { "link_path", e.LinkedResourcePathName }, - { "link_type", e.ResourceType.ToString() }, - } - }, sender, e); - } -#endif - - public void Application_FileImporting(object sender, FileImportingEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_FileImporting), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "import_path", e.Path }, - { "import_format", e.Format }, - } - }, sender, e); - } - - public void Application_FileImported(object sender, FileImportedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_FileImported), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - status = e.Status.ToString(), - args = new Dictionary { - { "import_path", e.Path }, - { "import_format", e.Format }, - } - }, sender, e); - } - - public void Application_FileExporting(object sender, FileExportingEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_FileExporting), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "export_path", e.Path }, - { "export_format", e.Format }, - } - }, sender, e); - } - - public void Application_FileExported(object sender, FileExportedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_FileExported), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - status = e.Status.ToString(), - args = new Dictionary { - { "export_path", e.Path }, - { "export_format", e.Format }, - } - }, sender, e); - } - -#if !(REVIT2013 || REVIT2014) - public void Application_FamilyLoadingIntoDocument(object sender, FamilyLoadingIntoDocumentEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_FamilyLoadingIntoDocument), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "family_name", e.FamilyName }, - { "family_path", e.FamilyPath }, - } - }, sender, e); - } - - public void Application_FamilyLoadedIntoDocument(object sender, FamilyLoadedIntoDocumentEventArgs e) { - var doc = e.Document; - string familyCategory = string.Empty; - string originalFamilyName = string.Empty; - - if (doc != null) { - // grab original name and category - if (e.OriginalFamilyId != ElementId.InvalidElementId) { - var origFamily = doc.GetElement(e.OriginalFamilyId); - if (origFamily != null) { - originalFamilyName = origFamily.Name; - familyCategory = origFamily.Category != null ? origFamily.Category.Name : ""; - } - } - - // grab category from new family - if (familyCategory == string.Empty && e.NewFamilyId != ElementId.InvalidElementId) { - var newFamily = doc.GetElement(e.NewFamilyId); - if (newFamily != null) - familyCategory = newFamily.Category != null ? newFamily.Category.Name : ""; - } - } - - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_FamilyLoadedIntoDocument), - docname = doc != null ? doc.Title : "", - docpath = doc != null ? doc.PathName : "", - projectnum = GetProjectNumber(doc), - projectname = GetProjectName(doc), - status = e.Status.ToString(), - args = new Dictionary { - { "family_name", e.FamilyName }, - { "family_path", e.FamilyPath }, - { "family_category", familyCategory}, - { "original_family_name", originalFamilyName }, - } - }, sender, e); - } -#endif - - public void Application_FailuresProcessing(object sender, FailuresProcessingEventArgs e) { - Document doc = null; - var failAcc = e.GetFailuresAccessor(); - - var args = new Dictionary(); - var failMessages = new Dictionary(); - if (failAcc != null) { - doc = failAcc.GetDocument(); - var failOptions = failAcc.GetFailureHandlingOptions(); - // collect failure information - - foreach (var fMsg in failAcc.GetFailureMessages()) { - var attemptedResTypes = new List(); - foreach (var aResType in failAcc.GetAttemptedResolutionTypes(fMsg)) - attemptedResTypes.Add(aResType.ToString()); - failMessages.Add( - fMsg.GetFailureDefinitionId().Guid.ToString(), - new Dictionary { - { "description" , fMsg.GetDescriptionText() }, - { "severity" , fMsg.GetSeverity().ToString() }, - { "failing_elements_count" , fMsg.GetFailingElementIds().Count }, - { "has_resolutions" , fMsg.HasResolutions() }, - { "resolutions_count" , fMsg.GetNumberOfResolutions() }, - { "current_resolution" , fMsg.GetCurrentResolutionType().ToString() }, - { "default_resolution" , fMsg.GetDefaultResolutionCaption() }, - { "attempted_resolutions" , attemptedResTypes }, - }); - } - - args = new Dictionary { - { "txn_committing", failAcc.IsTransactionBeingCommitted() }, - { "pending", failAcc.IsPending() }, - { "permits_resolution", failAcc.IsFailureResolutionPermitted() }, - { "permits_deletion", failAcc.IsElementsDeletionPermitted() }, - { "active", failAcc.IsActive() }, - { "txn_name", failAcc.GetTransactionName() }, - { "severity", failAcc.GetSeverity().ToString() }, - { "messages", failMessages }, - { "can_rollback", failAcc.CanRollBackPendingTransaction() }, - { "can_commit", failAcc.CanCommitPendingTransaction() }, - }; - } - - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_FailuresProcessing), - docname = doc != null ? doc.Title : "", - docpath = doc != null ? doc.PathName : "", - projectnum = GetProjectNumber(doc), - projectname = GetProjectName(doc), - args = args, - }, sender, e); - } - -#if !(REVIT2013 || REVIT2014) - public void Application_ElementTypeDuplicating(object sender, ElementTypeDuplicatingEventArgs e) { - var doc = e.Document; - string typeCategory = string.Empty; - string origTypeName = string.Empty; - - if (doc != null) { - if (e.ElementTypeId != ElementId.InvalidElementId) { - var origType = doc.GetElement(e.ElementTypeId); - if (origType != null) { - origTypeName = origType.Name; - typeCategory = origType.Category != null ? origType.Category.Name : ""; - } - } - } - - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_ElementTypeDuplicating), - docname = doc != null ? doc.Title : "", - docpath = doc != null ? doc.PathName : "", - args = new Dictionary { - { "category", typeCategory }, - { "from_typename", origTypeName }, - } - }, sender, e); - } - - public void Application_ElementTypeDuplicated(object sender, ElementTypeDuplicatedEventArgs e) { - var doc = e.Document; - string typeCategory = string.Empty; - string origTypeName = string.Empty; - - if (doc != null) { - if (e.OriginalElementTypeId != ElementId.InvalidElementId) { - var origType = doc.GetElement(e.OriginalElementTypeId); - if (origType != null) { - origTypeName = origType.Name; - typeCategory = origType.Category != null ? origType.Category.Name : ""; - } - } - } - - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_ElementTypeDuplicated), - docname = doc != null ? doc.Title : "", - docpath = doc != null ? doc.PathName : "", - projectnum = GetProjectNumber(doc), - projectname = GetProjectName(doc), - status = e.Status.ToString(), - args = new Dictionary { - { "category", typeCategory }, - { "from_typename", origTypeName }, - { "to_typename", e.NewName }, -#if !(REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021 || REVIT2022 || REVIT2023) - { "to_typeid", e.NewElementTypeId.Value }, -#else - { "to_typeid", e.NewElementTypeId.IntegerValue }, -#endif - } - }, sender, e); - } - - public void Application_DocumentWorksharingEnabled(object sender, DocumentWorksharingEnabledEventArgs e) { - var doc = e.GetDocument(); - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentWorksharingEnabled), - docname = doc != null ? doc.Title : "", - docpath = doc != null ? doc.PathName : "", - projectnum = GetProjectNumber(doc), - projectname = GetProjectName(doc), - }, sender, e); - } -#endif - - public void Application_DocumentSynchronizingWithCentral(object sender, DocumentSynchronizingWithCentralEventArgs e) { - var syncOpts = e.Options; - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentSynchronizingWithCentral), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "comments", e.Comments }, - { "location", e.Location }, - { "options", new Dictionary { -#if !(REVIT2013) - { "comment", syncOpts.Comment }, - { "compact", syncOpts.Compact }, -#else - { "comment", null }, - { "compact", null }, -#endif - { "relinquish_borrowed", syncOpts.RelinquishBorrowedElements }, - { "relinquish_family_worksets", syncOpts.RelinquishFamilyWorksets }, - { "relinquish_projectstd_worksets", syncOpts.RelinquishProjectStandardWorksets }, - { "relinquish_user_worksets", syncOpts.RelinquishUserCreatedWorksets }, - { "relinquish_view_worksets", syncOpts.RelinquishViewWorksets }, -#if !(REVIT2013) - { "save_local_after", syncOpts.SaveLocalAfter }, - { "save_local_before", syncOpts.SaveLocalBefore }, -#else - { "save_local_after", null }, - { "save_local_before", null }, -#endif - } }, - } - }, sender, e); - } - - public void Application_DocumentSynchronizedWithCentral(object sender, DocumentSynchronizedWithCentralEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentSynchronizedWithCentral), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "status", e.Status.ToString() }, - } - }, sender, e); - } - - public void Application_DocumentSavingAs(object sender, DocumentSavingAsEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentSavingAs), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { -#if (REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021_0) - { "as_master_file", e.IsSavingAsMasterFile }, -#else - // this change was made in Revit 2021.1 - { "as_master_file", e.IsSavingAsCentralFile }, -#endif - { "path", e.PathName }, - } - }, sender, e); - } - - public void Application_DocumentSavedAs(object sender, DocumentSavedAsEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentSavedAs), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - status = e.Status.ToString(), - args = new Dictionary { -#if (REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021_0) - { "as_master_file", e.IsSavingAsMasterFile }, -#else - // this change was made in Revit 2021.1 - { "as_master_file", e.IsSavingAsCentralFile }, -#endif - { "original_path", e.OriginalPath }, - { "project_info", GetProjectInfo(e.Document) } - } - }, sender, e); - } - - public void Application_DocumentSaving(object sender, DocumentSavingEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentSaving), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - }, sender, e); - } - - public void Application_DocumentSaved(object sender, DocumentSavedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentSaved), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - status = e.Status.ToString(), - args = new Dictionary { - { "project_info", GetProjectInfo(e.Document) } - } - }, sender, e); - } - - public void Application_DocumentPrinting(object sender, DocumentPrintingEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentPrinting), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - args = new Dictionary { - { "views", GetViewsData(GetElements(e.Document, e.GetViewElementIds())) }, -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016) - { "settings", GetPrintSettings(e.GetSettings().PrintParameters) }, -#else - { "settings", null }, -#endif - } - }, sender, e); - } - - public void Application_DocumentPrinted(object sender, DocumentPrintedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentPrinted), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - status = e.Status.ToString(), - args = new Dictionary { - { "print_pass_views", GetViewsData(GetElements(e.Document, e.GetPrintedViewElementIds())) }, - { "print_fail_views", GetViewsData(GetElements(e.Document, e.GetFailedViewElementIds())) }, - } - }, sender, e); - } - - public void Application_DocumentOpening(object sender, DocumentOpeningEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentOpening), - doctype = e.DocumentType.ToString(), - docpath = e.PathName, - }, sender, e); - } - - public void Application_DocumentOpened(object sender, DocumentOpenedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentOpened), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - status = e.Status.ToString(), - args = new Dictionary { - { "project_info", GetProjectInfo(e.Document) } - } - }, sender, e); - } - - public void Application_DocumentCreating(object sender, DocumentCreatingEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentCreating), - doctype = e.DocumentType.ToString(), - doctemplate = e.Template, - }, sender, e); - } - - public void Application_DocumentCreated(object sender, DocumentCreatedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentCreated), - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - status = e.Status.ToString(), - args = new Dictionary { - { "project_info", GetProjectInfo(e.Document) } - } - }, sender, e); - } - - public void Application_DocumentClosing(object sender, DocumentClosingEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentClosing), - docid = e.DocumentId, - docname = e.Document != null ? e.Document.Title : "", - docpath = e.Document != null ? e.Document.PathName : "", - projectnum = GetProjectNumber(e.Document), - projectname = GetProjectName(e.Document), - }, sender, e); - } - - public void Application_DocumentClosed(object sender, DocumentClosedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentClosed), - docid = e.DocumentId, - status = e.Status.ToString(), - }, sender, e); - } - - public void Application_DocumentChanged(object sender, DocumentChangedEventArgs e) { - var doc = e.GetDocument(); - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_DocumentChanged), - docname = doc != null ? doc.Title : "", - docpath = doc != null ? doc.PathName : "", - projectnum = GetProjectNumber(doc), - projectname = GetProjectName(doc), - args = new Dictionary { - { "operation", e.Operation.ToString() }, - { "added", e.GetAddedElementIds().Count }, - { "deleted", e.GetDeletedElementIds().Count }, - { "modified", e.GetModifiedElementIds().Count }, - { "txn_names", e.GetTransactionNames().ToList() }, - } - }, sender, e); - } - - public void Application_ApplicationInitialized(object sender, ApplicationInitializedEventArgs e) { - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_ApplicationInitialized), - }, sender, e); - } - -#if !(REVIT2013) - public void AddInCommandBinding_BeforeExecuted(object sender, BeforeExecutedEventArgs e) { - var doc = e.ActiveDocument; - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.AddInCommandBinding_BeforeExecuted), - docname = doc != null ? doc.Title : "", - docpath = doc != null ? doc.PathName : "", - projectnum = GetProjectNumber(doc), - projectname = GetProjectName(doc), - args = new Dictionary { - { "command_id", e.CommandId.Name }, - } - }, sender, e); - } -#endif - - public void AddInCommandBinding_CanExecute(object sender, CanExecuteEventArgs e) { - // do nothing. no interesting telemetry data - } - - public void AddInCommandBinding_Executed(object sender, ExecutedEventArgs e) { - // do nothing. no interesting telemetry data - } - - // custom events being called from non-main thread - public void Application_JournalUpdated(object sender, JournalUpdateArgs e) { - // do nothing. no interesting telemetry data - } - - public void Application_JournalCommandExecuted(object sender, CommandExecutedArgs e) { - if (extTelemetryEvent != null) { - extTelemetryEventHandler.Sender = sender; - extTelemetryEventHandler.CommandExecArgs = e; - extTelemetryEventHandler.EventTelemetryDelegate = SendJournalCommandExecutedTelemetry; - - extTelemetryEvent.Raise(); - while (extTelemetryEvent.IsPending); - } - } - - public void SendJournalCommandExecutedTelemetry(UIApplication uiapp, object sender, object e) { - // grab document data - var doc = uiapp.ActiveUIDocument != null ? uiapp.ActiveUIDocument.Document : null; - - // get args - CommandExecutedArgs args = e as CommandExecutedArgs; - - // send event info - LogEventTelemetryRecord(new EventTelemetryRecord { - type = EventUtils.GetEventName(EventType.Application_JournalCommandExecuted), - docname = doc != null ? doc.Title : "", - docpath = doc != null ? doc.PathName : "", - projectnum = GetProjectNumber(doc), - projectname = GetProjectName(doc), - args = new Dictionary { - { "command_id", args.CommandId }, - } - }, uiapp, args); - } - - public void Application_IUpdater(object sender, UpdaterData d) { - throw new NotImplementedException(); - } - } -} \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/Exceptions.cs b/dev/pyRevitLabs.PyRevit.Runtime/Exceptions.cs deleted file mode 100644 index 37911685c..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/Exceptions.cs +++ /dev/null @@ -1,16 +0,0 @@ -using System; - -namespace PyRevitLabs.PyRevit.Runtime { - public class NotSupportedFeatureException : Exception { - public static string NotSupportedMessage = "This feature is not supported under this Revit version."; - - public NotSupportedFeatureException() { } - - public override string Message { - get { - return NotSupportedMessage; - } - } - } -} - diff --git a/dev/pyRevitLabs.PyRevit.Runtime/GrasshopperEngine.cs b/dev/pyRevitLabs.PyRevit.Runtime/GrasshopperEngine.cs deleted file mode 100644 index 9081e2b5f..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/GrasshopperEngine.cs +++ /dev/null @@ -1,83 +0,0 @@ -using System; -using System.IO; -using System.Linq; -using System.Collections.Generic; -using System.Runtime.Remoting; -using System.Reflection; -using Autodesk.Revit.UI; -using Autodesk.Revit.DB; - -using pyRevitLabs.Common; - -namespace PyRevitLabs.PyRevit.Runtime { - public class GrasshoppertEngine : ScriptEngine { - public override void Init(ref ScriptRuntime runtime) { - base.Init(ref runtime); - // this is not a cachable engine; always use new engines - UseNewEngine = true; - } - - public override int Execute(ref ScriptRuntime runtime) { - try { - // find RhinoInside.Revit.dll - ObjectHandle ghObjHandle = - Activator.CreateInstance("RhinoInside.Revit.AddIn", "RhinoInside.Revit.AddIn.Commands.CommandGrasshopperPlayer"); - object ghPlayer = ghObjHandle.Unwrap(); - foreach (MethodInfo methodInfo in ghPlayer.GetType().GetMethods()) { - var methodParams = methodInfo.GetParameters(); - if (methodInfo.Name == "Execute" && methodParams.Count() == 5) { - - View activeView = null; -#if !(REVIT2013 || REVIT2014) - if (runtime.UIApp != null && runtime.UIApp.ActiveUIDocument != null) - activeView = runtime.UIApp.ActiveUIDocument.ActiveGraphicalView; -#else - if (runtime.UIApp != null && runtime.UIApp.ActiveUIDocument != null) - activeView = runtime.UIApp.ActiveUIDocument.ActiveView; -#endif - - // run the script - if (runtime.UIApp != null) { - string message = string.Empty; - - methodInfo.Invoke( - ghPlayer, - new object[] { - runtime.UIApp, - activeView, - new Dictionary(), - runtime.ScriptSourceFile, - message - }); - - return ScriptExecutorResultCodes.Succeeded; - } - else { - TaskDialog.Show(PyRevitLabsConsts.ProductName, "Can not access the UIApplication instance"); - return ScriptExecutorResultCodes.ExecutionException; - } - } - } - - TaskDialog.Show(PyRevitLabsConsts.ProductName, "Can not find appropriate Grasshopper Execute method"); - return ScriptExecutorResultCodes.ExecutionException; - - } - catch (FileNotFoundException) { - // if failed in finding DynamoRevitDS.dll, assume no dynamo - TaskDialog.Show(PyRevitLabsConsts.ProductName, - "Can not find Rhino.Inside installation or it is not loaded yet.\n\n" + - "Install/Load Rhino.Inside first."); - return ScriptExecutorResultCodes.ExecutionException; - } - catch (Exception ghEx) { - // if failed in finding RhinoInside.Revit.dll, assume no rhino - var dialog = new TaskDialog(PyRevitLabsConsts.ProductName); - dialog.MainInstruction = "Error executing Grasshopper script."; - dialog.ExpandedContent = string.Format("{0}\n{1}", ghEx.Message, ghEx.StackTrace); - dialog.Show(); - return ScriptExecutorResultCodes.ExecutionException; - } - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/HyperlinkEngine.cs b/dev/pyRevitLabs.PyRevit.Runtime/HyperlinkEngine.cs deleted file mode 100644 index b702af279..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/HyperlinkEngine.cs +++ /dev/null @@ -1,41 +0,0 @@ -using System; -using System.Linq; - -using Autodesk.Revit.UI; - -using pyRevitLabs.Common; - -namespace PyRevitLabs.PyRevit.Runtime { - public class HyperlinkEngine : ScriptEngine { - public override void Init(ref ScriptRuntime runtime) { - base.Init(ref runtime); - // this is not a cachable engine; always use new engines - UseNewEngine = true; - } - - public override int Execute(ref ScriptRuntime runtime) { - try { - // first argument is expected to be a hyperlink - if (runtime.ScriptRuntimeConfigs.Arguments.Count == 1) { - string hyperLink = runtime.ScriptRuntimeConfigs.Arguments.First(); - System.Diagnostics.Process.Start(hyperLink); - return ScriptExecutorResultCodes.Succeeded; - } - else { - TaskDialog.Show(PyRevitLabsConsts.ProductName, "Target hyperlink is not set correctly and can not be loaded."); - return ScriptExecutorResultCodes.ExternalInterfaceNotImplementedException; - } - } - catch (Exception hyperlinkEx) { - var dialog = new TaskDialog(PyRevitLabsConsts.ProductName); - dialog.MainInstruction = "Error opening link."; - dialog.ExpandedContent = string.Format("{0}\n{1}", hyperlinkEx.Message, hyperlinkEx.StackTrace); - dialog.Show(); - return ScriptExecutorResultCodes.ExecutionException; - } - finally { - // whatever - } - } - } -} \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/InvokableDLLEngine.cs b/dev/pyRevitLabs.PyRevit.Runtime/InvokableDLLEngine.cs deleted file mode 100644 index 1e011fdfe..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/InvokableDLLEngine.cs +++ /dev/null @@ -1,68 +0,0 @@ -using System; -using System.IO; -using System.Linq; -using System.Reflection; - -using Autodesk.Revit.UI; - -using pyRevitLabs.Common; - -namespace PyRevitLabs.PyRevit.Runtime { - public class InvokableDLLEngine : ScriptEngine { - public override void Init(ref ScriptRuntime runtime) { - base.Init(ref runtime); - - // If the user is asking to refresh the cached engine for the command, - UseNewEngine = runtime.ScriptRuntimeConfigs.RefreshEngine; - } - - public override int Execute(ref ScriptRuntime runtime) { - try { - // first argument is expected to be assmFile:className - if (runtime.ScriptRuntimeConfigs.Arguments.Count == 1) { - // load the binary data from the DLL - // Direct invoke commands use the config script source file to point - // to the target dll assembly location - string argumentString = runtime.ScriptRuntimeConfigs.Arguments.First(); - string assmFile = argumentString; - string className = null; - if (argumentString.Contains("::")) { - var parts = argumentString.Split( - new string[] { "::" }, - StringSplitOptions.RemoveEmptyEntries - ); - - assmFile = parts[0]; - className = parts[1]; - } - - - Assembly scriptAssm = Assembly.Load(File.ReadAllBytes(assmFile)); - var resultCode = CLREngine.ExecuteExternalCommand(scriptAssm, className, ref runtime); - if (resultCode == ScriptExecutorResultCodes.ExternalInterfaceNotImplementedException) - TaskDialog.Show(PyRevitLabsConsts.ProductName, - string.Format( - "Can not find type \"{0}\" in assembly \"{1}\"", - className, - assmFile - )); - return resultCode; - } - else { - TaskDialog.Show(PyRevitLabsConsts.ProductName, "Target assembly is not set correctly and can not be loaded."); - return ScriptExecutorResultCodes.ExternalInterfaceNotImplementedException; - } - } - catch (Exception invokeEx) { - var dialog = new TaskDialog(PyRevitLabsConsts.ProductName); - dialog.MainInstruction = "Error invoking .NET external command."; - dialog.ExpandedContent = string.Format("{0}\n{1}", invokeEx.Message, invokeEx.StackTrace); - dialog.Show(); - return ScriptExecutorResultCodes.ExecutionException; - } - finally { - // whatever - } - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/IronPythonEngine.cs b/dev/pyRevitLabs.PyRevit.Runtime/IronPythonEngine.cs deleted file mode 100644 index 0105bc5ea..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/IronPythonEngine.cs +++ /dev/null @@ -1,320 +0,0 @@ -using System; -using System.IO; -using System.Collections.Generic; - -// iron languages -using Microsoft.Scripting; -using Microsoft.Scripting.Hosting; -using IronPython.Hosting; -using IronPython.Compiler; -using IronPython.Runtime.Exceptions; -using IronPython.Runtime.Operations; - -using pyRevitLabs.Common.Extensions; -using pyRevitLabs.Json; -using pyRevitLabs.NLog; - -namespace PyRevitLabs.PyRevit.Runtime { - public class IronPythonEngineConfigs : ScriptEngineConfigs { - public bool clean = false; - public bool full_frame = false; - public bool persistent = false; - } - - public class IronPythonEngine : ScriptEngine { - private static readonly Logger logger = LogManager.GetCurrentClassLogger(); - - public Microsoft.Scripting.Hosting.ScriptEngine Engine { get; private set; } - public IronPythonEngineConfigs ExecEngineConfigs = new IronPythonEngineConfigs(); - - public static Tuple DefaultOutputStreamConfig { - get { - return (Tuple)AppDomain.CurrentDomain.GetData(DomainStorageKeys.IronPythonEngineDefaultOutputStreamCfgKey); - } - - set { - AppDomain.CurrentDomain.SetData(DomainStorageKeys.IronPythonEngineDefaultOutputStreamCfgKey, value); - } - } - - public static Tuple DefaultInputStreamConfig { - get { - return (Tuple)AppDomain.CurrentDomain.GetData(DomainStorageKeys.IronPythonEngineDefaultInputStreamCfgKey); - } - - set { - AppDomain.CurrentDomain.SetData(DomainStorageKeys.IronPythonEngineDefaultInputStreamCfgKey, value); - } - } - - public override void Init(ref ScriptRuntime runtime) { - base.Init(ref runtime); - - // extract engine configuration from runtime data - try { - ExecEngineConfigs = JsonConvert.DeserializeObject(runtime.ScriptRuntimeConfigs.EngineConfigs); - } catch {} - - // If the command required a fullframe engine - // or if the command required a clean engine - // of if the user is asking to refresh the cached engine for the command, - UseNewEngine = ExecEngineConfigs.clean || runtime.ScriptRuntimeConfigs.RefreshEngine; - } - - public override void Start(ref ScriptRuntime runtime) { - if (!RecoveredFromCache) { - var flags = new Dictionary(); - - // default flags - flags["LightweightScopes"] = true; - - if (ExecEngineConfigs.full_frame) { - flags["Frames"] = true; - flags["FullFrames"] = true; - flags["Tracing"] = true; - } - - Engine = IronPython.Hosting.Python.CreateEngine(flags); - - // also, allow access to the PyRevitLoader internals - Engine.Runtime.LoadAssembly(typeof(PyRevitLoader.ScriptExecutor).Assembly); - - // also, allow access to the PyRevitRuntime internals - Engine.Runtime.LoadAssembly(typeof(ScriptExecutor).Assembly); - - // reference RevitAPI and RevitAPIUI - Engine.Runtime.LoadAssembly(typeof(Autodesk.Revit.DB.Document).Assembly); - Engine.Runtime.LoadAssembly(typeof(Autodesk.Revit.UI.TaskDialog).Assembly); - - // save the default stream for later resetting the streams - DefaultOutputStreamConfig = new Tuple(Engine.Runtime.IO.OutputStream, Engine.Runtime.IO.OutputEncoding); - DefaultInputStreamConfig = new Tuple(Engine.Runtime.IO.InputStream, Engine.Runtime.IO.InputEncoding); - - // setup stdlib - SetupStdlib(Engine); - } - - SetupStreams(ref runtime); - SetupBuiltins(ref runtime); - SetupSearchPaths(ref runtime); - SetupArguments(ref runtime); - } - - public override int Execute(ref ScriptRuntime runtime) { - // Setup the command scope in this engine with proper builtin and scope parameters - var scope = Engine.CreateScope(); - - // Create the script from source file - var script = Engine.CreateScriptSourceFromFile( - runtime.ScriptSourceFile, - System.Text.Encoding.UTF8, - SourceCodeKind.File - ); - - // Setting up error reporter and compile the script - // setting module to be the main module so __name__ == __main__ is True - var compiler_options = (PythonCompilerOptions)Engine.GetCompilerOptions(scope); - compiler_options.ModuleName = "__main__"; - compiler_options.Module |= IronPython.Runtime.ModuleOptions.Initialize; - - var errors = new IronPythonErrorReporter(); - var command = script.Compile(compiler_options, errors); - - // Process compile errors if any - if (command == null) { - // compilation failed, print errors and return - runtime.OutputStream.WriteError(string.Join(Environment.NewLine, errors.Errors.ToArray()), ScriptEngineType.IronPython); - return ScriptExecutorResultCodes.CompileException; - } - - // Finally let's execute - try { - command.Execute(scope); - return ScriptExecutorResultCodes.Succeeded; - } - catch (SystemExitException) { - // ok, so the system exited. That was bound to happen... - return ScriptExecutorResultCodes.SysExited; - } - catch (Exception exception) { - // show (power) user everything! - string clrTraceMessage = exception.ToString(); - string ipyTraceMessage = Engine.GetService().FormatException(exception); - - // Print all errors to stdout and return cancelled to Revit. - // This is to avoid getting window prompts from Revit. - // Those pop ups are small and errors are hard to read. - ipyTraceMessage = ipyTraceMessage.NormalizeNewLine(); - - clrTraceMessage = clrTraceMessage.NormalizeNewLine(); - - // set the trace messages on runtime for later usage (e.g. logging) - runtime.TraceMessage = string.Join("\n", ipyTraceMessage, clrTraceMessage); - - // manually add the CLR traceback since this is a two part error message - clrTraceMessage = string.Join("\n", ScriptConsoleConfigs.ToCustomHtmlTags(ScriptConsoleConfigs.CLRErrorHeader), clrTraceMessage); - - runtime.OutputStream.WriteError(ipyTraceMessage + "\n\n" + clrTraceMessage, ScriptEngineType.IronPython); - return ScriptExecutorResultCodes.ExecutionException; - } - finally { - if (!ExecEngineConfigs.persistent) { - // cleaning removes all references to revit content that's been casualy stored in global-level - // variables and prohibit the GC from cleaning them up and releasing memory - var scopeClearScript = Engine.CreateScriptSourceFromString( - "for __deref in dir():\n" + - " if not __deref.startswith('__'):\n" + - " del globals()[__deref]"); - scopeClearScript.Compile(); - scopeClearScript.Execute(scope); - } - } - } - - public override void Stop(ref ScriptRuntime runtime) { - } - - public override void Shutdown() { - CleanupBuiltins(); - CleanupStreams(); - } - - private void SetupStdlib(Microsoft.Scripting.Hosting.ScriptEngine engine) { - // ask PyRevitLoader to add it's resource ZIP file that contains the IronPython - // standard library to this engine - var tempExec = new PyRevitLoader.ScriptExecutor(); - tempExec.AddEmbeddedLib(engine); - } - - private void SetupStreams(ref ScriptRuntime runtime) { - Engine.Runtime.IO.SetOutput(runtime.OutputStream, System.Text.Encoding.UTF8); - Engine.Runtime.IO.SetInput(runtime.OutputStream, System.Text.Encoding.UTF8); - } - - private void SetupBuiltins(ref ScriptRuntime runtime) { - // BUILTINS ----------------------------------------------------------------------------------------------- - // Get builtin to add custom variables - var builtin = IronPython.Hosting.Python.GetBuiltinModule(Engine); - - // Add timestamp and executuin uuid - builtin.SetVariable("__execid__", runtime.ExecId); - builtin.SetVariable("__timestamp__", runtime.ExecTimestamp); - - // Let commands know if they're being run in a cached engine - builtin.SetVariable("__cachedengine__", RecoveredFromCache); - - // Add current engine id to builtins - builtin.SetVariable("__cachedengineid__", TypeId); - - // Add this script executor to the the builtin to be globally visible everywhere - // This support pyrevit functionality to ask information about the current executing command - builtin.SetVariable("__scriptruntime__", runtime); - - // Add host application handle to the builtin to be globally visible everywhere - if (runtime.UIApp != null) - builtin.SetVariable("__revit__", runtime.UIApp); - else if (runtime.UIControlledApp != null) - builtin.SetVariable("__revit__", runtime.UIControlledApp); - else if (runtime.App != null) - builtin.SetVariable("__revit__", runtime.App); - else - builtin.SetVariable("__revit__", (object)null); - - // Adding data provided by IExternalCommand.Execute - builtin.SetVariable("__commanddata__", runtime.ScriptRuntimeConfigs.CommandData); - builtin.SetVariable("__elements__", runtime.ScriptRuntimeConfigs.SelectedElements); - - // Add ui button handle - builtin.SetVariable("__uibutton__", runtime.UIControl); - - // Adding information on the command being executed - builtin.SetVariable("__commandpath__", Path.GetDirectoryName(runtime.ScriptData.ScriptPath)); - builtin.SetVariable("__configcommandpath__", Path.GetDirectoryName(runtime.ScriptData.ConfigScriptPath)); - builtin.SetVariable("__commandname__", runtime.ScriptData.CommandName); - builtin.SetVariable("__commandbundle__", runtime.ScriptData.CommandBundle); - builtin.SetVariable("__commandextension__", runtime.ScriptData.CommandExtension); - builtin.SetVariable("__commanduniqueid__", runtime.ScriptData.CommandUniqueId); - builtin.SetVariable("__commandcontrolid__", runtime.ScriptData.CommandControlId); - builtin.SetVariable("__forceddebugmode__", runtime.ScriptRuntimeConfigs.DebugMode); - builtin.SetVariable("__shiftclick__", runtime.ScriptRuntimeConfigs.ConfigMode); - - // Add reference to the results dictionary - // so the command can add custom values for logging - builtin.SetVariable("__result__", runtime.GetResultsDictionary()); - - // EVENT HOOKS BUILTINS ---------------------------------------------------------------------------------- - // set event arguments for engine - builtin.SetVariable("__eventsender__", runtime.ScriptRuntimeConfigs.EventSender); - builtin.SetVariable("__eventargs__", runtime.ScriptRuntimeConfigs.EventArgs); - } - - private void SetupSearchPaths(ref ScriptRuntime runtime) { - // process search paths provided to executor - Engine.SetSearchPaths(runtime.ScriptRuntimeConfigs.SearchPaths); - } - - private void SetupArguments(ref ScriptRuntime runtime) { - // setup arguments (sets sys.argv) - // engine.Setup.Options["Arguments"] = arguments; - // engine.Runtime.Setup.HostArguments = new List(arguments); - var sysmodule = Engine.GetSysModule(); - var pythonArgv = PythonOps.MakeEmptyList(2); - // for python make sure the first argument is the script - pythonArgv.append(runtime.ScriptSourceFile); - pythonArgv.extend(runtime.ScriptRuntimeConfigs.Arguments); - sysmodule.SetVariable("argv", pythonArgv); - } - - private void CleanupBuiltins() { - var builtin = IronPython.Hosting.Python.GetBuiltinModule(Engine); - - builtin.SetVariable("__cachedengine__", (object)null); - builtin.SetVariable("__cachedengineid__", (object)null); - builtin.SetVariable("__scriptruntime__", (object)null); - builtin.SetVariable("__commanddata__", (object)null); - builtin.SetVariable("__elements__", (object)null); - builtin.SetVariable("__uibutton__", (object)null); - builtin.SetVariable("__commandpath__", (object)null); - builtin.SetVariable("__configcommandpath__", (object)null); - builtin.SetVariable("__commandname__", (object)null); - builtin.SetVariable("__commandbundle__", (object)null); - builtin.SetVariable("__commandextension__", (object)null); - builtin.SetVariable("__commanduniqueid__", (object)null); - builtin.SetVariable("__commandcontrolid__", (object)null); - builtin.SetVariable("__forceddebugmode__", (object)null); - builtin.SetVariable("__shiftclick__", (object)null); - - builtin.SetVariable("__result__", (object)null); - - builtin.SetVariable("__eventsender__", (object)null); - builtin.SetVariable("__eventargs__", (object)null); - } - - private void CleanupStreams() { - // Remove IO streams references so GC can collect - Tuple outStream = DefaultOutputStreamConfig; - if (outStream != null) { - Engine.Runtime.IO.SetOutput(outStream.Item1, outStream.Item2); - outStream.Item1.Dispose(); - } - Tuple inStream = DefaultInputStreamConfig; - if (inStream != null) { - Engine.Runtime.IO.SetInput(inStream.Item1, inStream.Item2); - inStream.Item1.Dispose(); - } - } - } - - public class IronPythonErrorReporter : ErrorListener { - public List Errors = new List(); - - public override void ErrorReported(ScriptSource source, string message, - SourceSpan span, int errorCode, Severity severity) { - Errors.Add(string.Format("{0} (line {1})", message, span.Start.Line)); - } - - public int Count { - get { return Errors.Count; } - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/IronRubyEngine.cs b/dev/pyRevitLabs.PyRevit.Runtime/IronRubyEngine.cs deleted file mode 100644 index c66a99271..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/IronRubyEngine.cs +++ /dev/null @@ -1,60 +0,0 @@ -using Autodesk.Revit.UI; - -using pyRevitLabs.Common; - -namespace PyRevitLabs.PyRevit.Runtime { - public class IronRubyEngine : ScriptEngine { - public override void Init(ref ScriptRuntime runtime) { - base.Init(ref runtime); - - // If the user is asking to refresh the cached engine for the command, - UseNewEngine = runtime.ScriptRuntimeConfigs.RefreshEngine; - } - - public override int Execute(ref ScriptRuntime runtime) { - // TODO: ExecuteRubyScript - TaskDialog.Show(PyRevitLabsConsts.ProductName, "Ruby-Script Execution Engine Not Yet Implemented."); - return ScriptExecutorResultCodes.EngineNotImplementedException; - //// https://github.com/hakonhc/RevitRubyShell/blob/master/RevitRubyShell/RevitRubyShellApplication.cs - //// 1: ---------------------------------------------------------------------------------------------------- - //// start ruby interpreter - //var engine = Ruby.CreateEngine(); - //var scope = engine.CreateScope(); - - //// 2: ---------------------------------------------------------------------------------------------------- - //// Finally let's execute - //try { - // // Run the code - // engine.ExecuteFile(pyrvtScript.ScriptSourceFile, scope); - // return ExecutionErrorCodes.Succeeded; - //} - //catch (SystemExitException) { - // // ok, so the system exited. That was bound to happen... - // return ExecutionErrorCodes.SysExited; - //} - //catch (Exception exception) { - // // show (power) user everything! - // string _dotnet_err_message = exception.ToString(); - // string _ruby_err_messages = engine.GetService().FormatException(exception); - - // // Print all errors to stdout and return cancelled to Revit. - // // This is to avoid getting window prompts from Revit. - // // Those pop ups are small and errors are hard to read. - // _ruby_err_messages = _ruby_err_messages.NormalizeNewLine(); - // pyrvtScript.IronLanguageTraceBack = _ruby_err_messages; - - // _dotnet_err_message = _dotnet_err_message.NormalizeNewLine(); - // pyrvtScript.TraceMessage = _dotnet_err_message; - - // _ruby_err_messages = string.Join(Environment.NewLine, ExternalConfig.irubyerrtitle, _ruby_err_messages); - // _dotnet_err_message = string.Join(Environment.NewLine, ExternalConfig.dotneterrtitle, _dotnet_err_message); - - // pyrvtScript.OutputStream.WriteError(_ruby_err_messages + "\n\n" + _dotnet_err_message); - // return ExecutionErrorCodes.ExecutionException; - //} - //finally { - // // whatever - //} - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/JournalListener.cs b/dev/pyRevitLabs.PyRevit.Runtime/JournalListener.cs deleted file mode 100644 index 1ab6e17bf..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/JournalListener.cs +++ /dev/null @@ -1,110 +0,0 @@ -using System; -using System.IO; -using System.Threading; -using System.Collections.Generic; -using System.Text.RegularExpressions; - -using Autodesk.Revit.UI; - -namespace PyRevitLabs.PyRevit.Runtime { - public class JournalUpdateArgs : EventArgs { - public string JournalFile; - public string[] NewJournalLines; - - public JournalUpdateArgs(string journalFile, string[] newLines) { - JournalFile = journalFile; - NewJournalLines = newLines; - } - } - - public class CommandExecutedArgs : EventArgs { - public string JournalFile; - public string CommandId; - - public CommandExecutedArgs(string journalFile, string commandId) { - JournalFile = journalFile; - CommandId = commandId; - } - } - - public delegate void JournalUpdate(object source, JournalUpdateArgs e); - public delegate void CommandExecuted(object source, CommandExecutedArgs e); - - public class JournalListener { - private long prevLen = -1; - private string JournalFile = ""; - private Thread jtail; - - private static List JournalCommandExtractors = new List { - new Regex(@".*Jrn\.RibbonEvent\s""Execute external command\:(?.+)\:(.+)"""), - new Regex(@".*Jrn.Command "".+""\s\,\s"".*\s\,\s(?.+)"""), - }; - - public bool JournalUpdateEvents = false; - public event JournalUpdate OnJournalUpdate; - - public bool JournalCommandExecutedEvents = false; - public event CommandExecuted OnJournalCommandExecuted; - - public JournalListener(UIApplication uiapp) { - JournalFile = uiapp.Application.RecordingJournalFilename; - } - - public void Start() { - FileInfo fi = new FileInfo(JournalFile); - prevLen = fi.Length; - jtail = new Thread(TailJournal); - jtail.Start(); - } - - public void Stop() { - if (jtail != null) - jtail.Abort(); - } - - private void TailJournal() { while (true) { Tail(); } } - - private void Tail() { - FileInfo fi = new FileInfo(JournalFile); - if (fi.Exists) { - if (fi.Length != prevLen) { - using (var stream = new FileStream(fi.FullName, FileMode.Open, FileAccess.Read, FileShare.Delete | FileShare.ReadWrite)) { - stream.Seek(prevLen, SeekOrigin.Begin); - - var newlengh = stream.Length; - prevLen = newlengh; - - using (StreamReader sr = new StreamReader(stream)) { - string all = sr.ReadToEnd(); - string[] newLines = all.Split(Environment.NewLine.ToCharArray()); - if (OnJournalUpdate != null) - OnJournalUpdate(this, new JournalUpdateArgs(JournalFile, newLines)); - - if (OnJournalCommandExecuted != null) - DetectCommandExecutions(newLines); - } - } - } - } - } - - private void DetectCommandExecutions(string[] newLines) { - // find the commands in new journal lines - var commands = new List(); - foreach (var line in newLines) { - foreach (var finder in JournalCommandExtractors) { - var m = finder.Match(line); - if (m.Success) { - commands.Add(m.Groups["command_id"].Value); - break; - } - } - } - // now call the handlers - foreach (var commandId in commands) - OnJournalCommandExecuted(this, new CommandExecutedArgs(JournalFile, commandId)); - } - - } -} - diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ScriptCommands.cs b/dev/pyRevitLabs.PyRevit.Runtime/ScriptCommands.cs deleted file mode 100644 index 09fd80943..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ScriptCommands.cs +++ /dev/null @@ -1,866 +0,0 @@ -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Windows.Input; -using System.Windows.Controls; - -using Autodesk.Revit.UI; -using Autodesk.Revit.DB; -using Autodesk.Revit.Attributes; - -namespace PyRevitLabs.PyRevit.Runtime { - public class CommandTypeExecConfigs { - // unlike fullframe or clean engine modes, the config script mode is determined at - // script execution by using a shortcut key combination. This parameter is created to - // trigger the config script mode when executing a command from a program and not - // from the Revit user interface. - public bool UseConfigScript = false; - - // this is true by default since commands are normally executed from ui. - // pyrevit module will set this to false, when manually executing a - // pyrevit command from python code. (e.g when executing reload after update) - public bool MimicExecFromUI = true; - } - - - [Regeneration(RegenerationOption.Manual)] - [Transaction(TransactionMode.Manual)] - public abstract class ScriptCommand : IExternalCommand { - - public ScriptData ScriptData; - public ScriptRuntimeConfigs ScriptRuntimeConfigs; - - public CommandTypeExecConfigs ExecConfigs = new CommandTypeExecConfigs(); - - public ScriptCommand( - string scriptSource, - string configScriptSource, - string searchPaths, - string arguments, - string helpSource, - string tooltip, - string cmdName, - string cmdBundle, - string cmdExtension, - string cmdUniqueName, - string cmdControlId, - string cmdContext, - string engineCfgs) { - ScriptData = new ScriptData { - ScriptPath = scriptSource, - ConfigScriptPath = configScriptSource, - CommandUniqueId = cmdUniqueName, - CommandControlId = cmdControlId, - CommandName = cmdName, - CommandBundle = cmdBundle, - CommandExtension = cmdExtension, - CommandContext = cmdContext, - HelpSource = helpSource, - Tooltip = tooltip, - }; - - // build search paths - List searchPathList = new List(); - if (searchPaths != null && searchPaths != string.Empty) - searchPathList = new List(searchPaths.Split(Path.PathSeparator)); - - // build arguments - List argumentList = new List(); - if (arguments != null && arguments != string.Empty) - argumentList = new List(arguments.Split(Path.PathSeparator)); - - ScriptRuntimeConfigs = new ScriptRuntimeConfigs { - SearchPaths = searchPathList, - Arguments = argumentList, - EngineConfigs = engineCfgs, - }; - } - - - public Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements) { - // 1: ---------------------------------------------------------------------------------------------------- - #region Processing modifier keys - // Processing modifier keys - - bool refreshEngine = false; - bool configScriptMode = false; - bool forcedDebugMode = false; - - bool ALT = Keyboard.IsKeyDown(Key.LeftAlt) || Keyboard.IsKeyDown(Key.RightAlt); - bool SHIFT = Keyboard.IsKeyDown(Key.LeftShift) || Keyboard.IsKeyDown(Key.RightShift); - bool CTRL = Keyboard.IsKeyDown(Key.LeftCtrl) || Keyboard.IsKeyDown(Key.RightCtrl); - bool WIN = Keyboard.IsKeyDown(Key.LWin) || Keyboard.IsKeyDown(Key.RWin); - - - // If Ctrl+Alt+Shift clicking on the tool run in clean engine - if (CTRL && ALT && SHIFT) { - refreshEngine = true; - } - - // If Alt+Shift clicking on button, open the context menu with options. - else if (SHIFT && WIN) { - // start creating context menu - ContextMenu pyRevitCmdContextMenu = new ContextMenu(); - - // menu item to open help url if exists - if (ScriptData.HelpSource != null && ScriptData.HelpSource != "") { - MenuItem openHelpSource = new MenuItem(); - openHelpSource.Header = "Open Help"; - openHelpSource.ToolTip = ScriptData.HelpSource; - openHelpSource.Click += delegate { System.Diagnostics.Process.Start(ScriptData.HelpSource); }; - pyRevitCmdContextMenu.Items.Add(openHelpSource); - } - - // menu item to copy script path to clipboard - MenuItem copyScriptPath = new MenuItem(); - copyScriptPath.Header = "Copy Script Path"; - copyScriptPath.ToolTip = ScriptData.ScriptPath; - copyScriptPath.Click += delegate { System.Windows.Forms.Clipboard.SetText(ScriptData.ScriptPath); }; - pyRevitCmdContextMenu.Items.Add(copyScriptPath); - - // menu item to copy config script path to clipboard, if exists - if (ScriptData.ConfigScriptPath != null && ScriptData.ConfigScriptPath != "") { - MenuItem copyAltScriptPath = new MenuItem(); - copyAltScriptPath.Header = "Copy Config Script Path"; - copyAltScriptPath.ToolTip = ScriptData.ConfigScriptPath; - copyAltScriptPath.Click += delegate { System.Windows.Forms.Clipboard.SetText(ScriptData.ConfigScriptPath); }; - pyRevitCmdContextMenu.Items.Add(copyAltScriptPath); - } - - // menu item to copy bundle path to clipboard - var bundlePath = Path.GetDirectoryName(ScriptData.ScriptPath); - MenuItem copyBundlePath = new MenuItem(); - copyBundlePath.Header = "Copy Bundle Path"; - copyBundlePath.ToolTip = bundlePath; - copyBundlePath.Click += delegate { System.Windows.Forms.Clipboard.SetText(bundlePath); }; - pyRevitCmdContextMenu.Items.Add(copyBundlePath); - - // menu item to copy command unique name (assigned by pyRevit) to clipboard - MenuItem copyUniqueName = new MenuItem(); - copyUniqueName.Header = "Copy Unique Id"; - copyUniqueName.ToolTip = ScriptData.CommandUniqueId; - copyUniqueName.Click += delegate { System.Windows.Forms.Clipboard.SetText(ScriptData.CommandUniqueId); }; - pyRevitCmdContextMenu.Items.Add(copyUniqueName); - - // menu item to copy command unique name (assigned by pyRevit) to clipboard - MenuItem copyControlIdName = new MenuItem(); - copyControlIdName.Header = "Copy Control Id"; - copyControlIdName.ToolTip = ScriptData.CommandControlId; - copyControlIdName.Click += delegate { System.Windows.Forms.Clipboard.SetText(ScriptData.CommandControlId); }; - pyRevitCmdContextMenu.Items.Add(copyControlIdName); - - // menu item to copy ;-separated sys paths to clipboard - // Example: "path1;path2;path3" - MenuItem copySysPaths = new MenuItem(); - string sysPathsText = string.Join(Environment.NewLine, ScriptRuntimeConfigs.SearchPaths); - copySysPaths.Header = "Copy Sys Paths"; - copySysPaths.ToolTip = sysPathsText; - copySysPaths.Click += delegate { System.Windows.Forms.Clipboard.SetText(sysPathsText); }; - pyRevitCmdContextMenu.Items.Add(copySysPaths); - - // menu item to copy ;-separated arguments to clipboard - // Example: "path1;path2;path3" - MenuItem copyArguments = new MenuItem(); - string argumentsText = string.Join(Environment.NewLine, ScriptRuntimeConfigs.Arguments); - copyArguments.Header = "Copy Arguments"; - copyArguments.ToolTip = argumentsText; - copyArguments.Click += delegate { System.Windows.Forms.Clipboard.SetText(argumentsText); }; - pyRevitCmdContextMenu.Items.Add(copyArguments); - if (argumentsText == null || argumentsText == string.Empty) - copyArguments.IsEnabled = false; - - // menu item to copy command context strings - MenuItem copyContext = new MenuItem(); - copyContext.IsEnabled = !string.IsNullOrEmpty(ScriptData.CommandContext); - copyContext.Header = "Copy Context Filter"; - copyContext.ToolTip = ScriptData.CommandContext; - copyContext.Click += delegate { - try { - var contextFilter = ScriptCommandExtendedAvail.FromContextDefinition(ScriptData.CommandContext); - System.Windows.Forms.Clipboard.SetText( - $"Original: {ScriptData.CommandContext}\n" + - $"Compiled: {contextFilter}" - ); - } - catch (Exception ex) { - System.Windows.Forms.Clipboard.SetText( - $"Error occured while compiling context \"{ScriptData.CommandContext}\" | {ex.Message}" - ); - } - }; - pyRevitCmdContextMenu.Items.Add(copyContext); - - // menu item to copy engine configs - MenuItem copyEngineConfigs = new MenuItem(); - string engineCfgs = ScriptRuntimeConfigs.EngineConfigs; - copyEngineConfigs.Header = "Copy Engine Configs"; - copyEngineConfigs.ToolTip = engineCfgs; - copyEngineConfigs.Click += delegate { System.Windows.Forms.Clipboard.SetText(engineCfgs); }; - pyRevitCmdContextMenu.Items.Add(copyEngineConfigs); - if (engineCfgs == null || engineCfgs == string.Empty) - copyEngineConfigs.IsEnabled = false; - - // menu item to copy help url - MenuItem copyHelpSource = new MenuItem(); - copyHelpSource.Header = "Copy Help Url"; - copyHelpSource.ToolTip = ScriptData.HelpSource; - copyHelpSource.Click += delegate { System.Windows.Forms.Clipboard.SetText(ScriptData.HelpSource); }; - pyRevitCmdContextMenu.Items.Add(copyHelpSource); - if (ScriptData.HelpSource == null || ScriptData.HelpSource == string.Empty) - copyHelpSource.IsEnabled = false; - - // open the menu - pyRevitCmdContextMenu.IsOpen = true; - - return Result.Succeeded; - } - - // If Ctrl+Shift clicking on button, run the script in debug mode and run config script instead. - else if (CTRL && (SHIFT || ExecConfigs.UseConfigScript)) { - configScriptMode = true; - forcedDebugMode = true; - } - - // If Alt clicking on button, open the script in explorer and return. - else if (SHIFT && ALT) { - // combine the arguments together - // it doesn't matter if there is a space after ',' - if (ScriptExecutor.EnsureTargetScript(ScriptData.ConfigScriptPath)) { - string argument = "/select, \"" + ScriptData.ConfigScriptPath + "\""; - - System.Diagnostics.Process.Start("explorer.exe", argument); - } - return Result.Succeeded; - } - - else if (ALT) { - // combine the arguments together - // it doesn't matter if there is a space after ',' - if (ScriptExecutor.EnsureTargetScript(ScriptData.ScriptPath)) { - string argument = "/select, \"" + ScriptData.ScriptPath + "\""; - - System.Diagnostics.Process.Start("explorer.exe", argument); - } - return Result.Succeeded; - } - - // If Shift clicking on button, run config script instead - else if (SHIFT || ExecConfigs.UseConfigScript) { - configScriptMode = true; - } - - // If Ctrl clicking on button, set forced debug mode. - else if (CTRL) { - forcedDebugMode = true; - } - #endregion - - // 2: ---------------------------------------------------------------------------------------------------- - #region Setup pyRevit Command Runtime Configs - // fill in the rest of runtime info - ScriptRuntimeConfigs.CommandData = commandData; - ScriptRuntimeConfigs.SelectedElements = elements; - ScriptRuntimeConfigs.RefreshEngine = refreshEngine; - ScriptRuntimeConfigs.ConfigMode = configScriptMode; - ScriptRuntimeConfigs.DebugMode = forcedDebugMode; - ScriptRuntimeConfigs.ExecutedFromUI = ExecConfigs.MimicExecFromUI; - - #endregion - - // 3: ---------------------------------------------------------------------------------------------------- - #region Execute and log results - // Executing the script and logging the results - // Get script executor and Execute the script - var env = new EnvDictionary(); - int result = ScriptExecutor.ExecuteScript( - ScriptData, - ScriptRuntimeConfigs, - new ScriptExecutorConfigs { - SendTelemetry = env.TelemetryState - } - ); - - // Return results to Revit. Don't report errors since we don't want Revit popup with error results - if (result == 0) - return Result.Succeeded; - else - return Result.Cancelled; - #endregion - } - } - - - public abstract class ScriptCommandExtendedAvail : IExternalCommandAvailability { - // separators - const char CONTEXT_CONDITION_ALL_SEP = '&'; - const char CONTEXT_CONDITION_ANY_SEP = '|'; - const char CONTEXT_CONDITION_EXACT_SEP = ';'; - const char CONTEXT_CONDITION_NOT = '!'; - - // category name separator for comparisons - const string SEP = "|"; - - public ScriptCommandExtendedAvail(string contextString) { - CompiledContextFilter = FromContextDefinition(contextString); - } - - public static ContextFilter FromContextDefinition(string contextString) { - /* - * Context string format is a list of tokens joined by either & or | but not both - * and grouped inside (). Groups can also be joined by either & or | but not both - * Context strings can not be nested - * Examples: a,b,c are tokens - * (a) - * (a&b&c) - * (a|b|c) - * (a|b|c)&(a&b&c) - * (a|b|c)|(a&b&c) - */ - - // parse context string - bool supportsZeroDoc = false; - ContextFilter ctxFilter = new ContextFilter(); - var collectedConditions = new HashSet(); - - bool capturingSubCondition = false; - bool subConditionIsNot = false; - CompoundCondition subCondition = new AllCondition(); - var collectedSubConditions = new HashSet(); - - bool capturingToken = false; - string currentToken = string.Empty; - - Action captureToken = () => { - if (capturingToken && currentToken != string.Empty) { - if (Condition.FromToken(currentToken) is Condition condition) { - if (condition is ZeroDocCondition) - supportsZeroDoc = true; - collectedSubConditions.Add(condition); - } - currentToken = string.Empty; - } - }; - - Action captureSubConditions = () => { - if (capturingSubCondition) { - if (collectedSubConditions.Count > 0) { - subCondition.Conditions = collectedSubConditions; - subCondition.IsNot = subConditionIsNot; - collectedConditions.Add(subCondition); - } - collectedSubConditions = new HashSet(); - capturingSubCondition = false; - subConditionIsNot = false; - } - }; - - foreach(char c in contextString) { - switch (c) { - // sub conditions - case '(': - if (capturingSubCondition) - captureToken(); - else { - capturingSubCondition = true; - capturingToken = true; - } - continue; - case ')': - captureToken(); - captureSubConditions(); - continue; - - // (sub)condition types - case CONTEXT_CONDITION_ALL_SEP: - captureToken(); - if (capturingSubCondition) subCondition = new AllCondition(); - else ctxFilter.Condition = new AllCondition(); - continue; - case CONTEXT_CONDITION_ANY_SEP: - captureToken(); - if (capturingSubCondition) subCondition = new AnyCondition(); - else ctxFilter.Condition = new AnyCondition(); - continue; - case CONTEXT_CONDITION_EXACT_SEP: - captureToken(); - if (capturingSubCondition) subCondition = new ExactCondition(); - else ctxFilter.Condition = new ExactCondition(); - continue; - - case CONTEXT_CONDITION_NOT: - if (!capturingSubCondition) subConditionIsNot = true; - continue; - - // tokens - default: - if (capturingToken) currentToken += c; continue; - } - } - - - ctxFilter.Condition.Conditions = collectedConditions; - ctxFilter.EnsureActiveDocument = !supportsZeroDoc; - return ctxFilter; - } - - public abstract class Condition { - public bool IsRoot { get; set; } = false; - - public static bool HasDocument(UIApplication uiApp) => uiApp != null && uiApp.ActiveUIDocument != null; - - public static bool HasSelection(UIApplication uiApp, CategorySet selectedCategories) => HasDocument(uiApp) && !selectedCategories.IsEmpty; - - public abstract bool IsMatch(UIApplication uiApp, CategorySet selectedCategories); - - public static Condition FromToken(string token) { - // check for reserved tokens first - switch (token.ToLower()) { - case "zero-doc": - return new ZeroDocCondition(); - - // selection token requires selected elements - case "selection": - return new SelectionCondition(); - - // document type - case "doc-project": - return new DocumentTypeCondition( - DocumentTypeCondition.DocumentType.Project - ); - case "doc-workshared": - return new DocumentTypeCondition( - DocumentTypeCondition.DocumentType.WorksharedProject - ); - case "doc-cloud": - return new DocumentTypeCondition( - DocumentTypeCondition.DocumentType.CloudProject - ); - case "doc-family": - return new DocumentTypeCondition( - DocumentTypeCondition.DocumentType.Family - ); - - // active-* tokens require a certain type of active view - case "active-drafting-view": - return new ViewTypeCondition(ViewType.DraftingView); - case "active-detail-view": - return new ViewTypeCondition(ViewType.Detail); - case "active-plan-view": - return new ViewTypeCondition( - new ViewType[] { - ViewType.FloorPlan, - ViewType.CeilingPlan, - ViewType.AreaPlan, - ViewType.EngineeringPlan - } - ); - case "active-floor-plan": - return new ViewTypeCondition(ViewType.FloorPlan); - case "active-rcp-plan": - return new ViewTypeCondition(ViewType.CeilingPlan); - case "active-structural-plan": - return new ViewTypeCondition(ViewType.EngineeringPlan); - case "active-area-plan": - return new ViewTypeCondition(ViewType.AreaPlan); - case "active-elevation-view": - return new ViewTypeCondition(ViewType.Elevation); - case "active-section-view": - return new ViewTypeCondition(ViewType.Section); - case "active-3d-view": - return new ViewTypeCondition(ViewType.ThreeD); - case "active-sheet": - return new ViewTypeCondition(ViewType.DrawingSheet); - case "active-legend": - return new ViewTypeCondition(ViewType.Legend); - case "active-schedule": - return new ViewTypeCondition( - new ViewType[] { - ViewType.PanelSchedule, - ViewType.ColumnSchedule, - ViewType.Schedule - } - ); - case "active-panel-schedule": - return new ViewTypeCondition(ViewType.PanelSchedule); - case "active-column-schedule": - return new ViewTypeCondition(ViewType.ColumnSchedule); - } - - // check for custom tokens next - // NOTE: - // docs have builtin categories - // docs might have custom categories with non-english names - // the compare mechanism is providing methods to cover both conditions - // compare mechanism stores integer ids for builtin categories - // compare mechanism stores strings for custom category names - // avail methods don't have access to doc object so the category names must be stored as string - BuiltInCategory bic = BuiltInCategory.INVALID; - if (Enum.TryParse(token, true, out bic) && bic != 0 && bic != BuiltInCategory.INVALID) - return new BuiltinCategoryCondition((int)bic); - - // assume the token must be a custom category name - return new CustomCategoryCondition(token); - } - - public abstract override bool Equals(object obj); - public abstract override int GetHashCode(); - public abstract override string ToString(); - } - - public abstract class CompoundCondition: Condition { - public bool IsNot { get; set; } = false; - - public abstract string Separator { get; } - - public HashSet Conditions = new HashSet(); - - public override bool Equals(object obj) { - if (obj is HashSet conditions) - return new HashSet(Conditions.Except(conditions)).Count == 0; - else if (obj is CompoundCondition compCond) - return new HashSet(Conditions.Except(compCond.Conditions)).Count == 0; - else - return false; - } - - public override int GetHashCode() { - return Conditions.GetHashCode(); - } - - public override string ToString() { - if (IsRoot) - return string.Join(Separator, Conditions); - else - return (IsNot ? "!" : "") + "(" + string.Join(Separator, Conditions) + ")"; - } - } - - class DocumentTypeCondition : Condition { - // acceptable document types - public enum DocumentType { - Any, - Project, - WorksharedProject, - CloudProject, - Family - } - - DocumentType _docType = DocumentType.Any; - - public DocumentTypeCondition(DocumentType docType = DocumentType.Any) => _docType = docType; - - public override bool IsMatch(UIApplication uiApp, CategorySet selectedCategories) { - // check document type - if (HasDocument(uiApp)) { - switch (_docType) { - case DocumentType.Project: - if (uiApp.ActiveUIDocument.Document.IsFamilyDocument) - return false; - break; - case DocumentType.WorksharedProject: - if (uiApp.ActiveUIDocument.Document.IsFamilyDocument || !uiApp.ActiveUIDocument.Document.IsWorkshared) - return false; - break; - case DocumentType.CloudProject: -#if !(REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018 || (REVIT2019 && !REVIT2019_1) ) - if (uiApp.ActiveUIDocument.Document.IsFamilyDocument || !uiApp.ActiveUIDocument.Document.IsModelInCloud) - return false; - break; -#else - return false; -#endif - case DocumentType.Family: - if (!uiApp.ActiveUIDocument.Document.IsFamilyDocument) - return false; - break; - } - return true; - } - else - return false; - } - - public override bool Equals(object obj) { - if (obj is DocumentType docType) - return _docType == docType; - else if (obj is DocumentTypeCondition docTypeCond) - return _docType == docTypeCond._docType; - else - return false; - } - - public override int GetHashCode() { - return _docType.GetHashCode(); - } - - public override string ToString() { - return _docType.ToString(); - } - } - - class ViewTypeCondition : Condition { - HashSet _viewTypes; - - public ViewTypeCondition(ViewType viewType) => _viewTypes = new HashSet { viewType }; - public ViewTypeCondition(ViewType[] viewTypes) => _viewTypes = new HashSet (viewTypes); - - public override bool IsMatch(UIApplication uiApp, CategorySet selectedCategories) { - try { - // check active views - if (_viewTypes.Count > 0) { - if (HasDocument(uiApp)) -#if (REVIT2013 || REVIT2014) - return _viewTypes.Contains(uiApp.ActiveUIDocument.ActiveView.ViewType); -#else - return _viewTypes.Contains(uiApp.ActiveUIDocument.ActiveGraphicalView.ViewType); -#endif - } - else - return true; - } - // say no if any errors occured, otherwise Revit will not call this method again if exceptions - // are bubbled up - catch {} - return false; - } - - public override bool Equals(object obj) { - if (obj is HashSet viewTypes) - return new HashSet(_viewTypes.Except(viewTypes)).Count == 0; - else if (obj is ViewTypeCondition viewTypeCond) - return new HashSet(_viewTypes.Except(viewTypeCond._viewTypes)).Count == 0; - else - return false; - } - - public override int GetHashCode() { - return _viewTypes.GetHashCode(); - } - - public override string ToString() { - return string.Join(";", _viewTypes); - } - } - - abstract class CategoryCondition : Condition { - public abstract bool IsMatch(Category category); - } - - class BuiltinCategoryCondition : CategoryCondition { - int _categoryId = -1; - - public BuiltinCategoryCondition(int categoryId) => _categoryId = categoryId; - - public override bool IsMatch(UIApplication uiApp, CategorySet selectedCategories) { - if (HasSelection(uiApp, selectedCategories)) { - try { - foreach (Category category in selectedCategories) - { -#if !(REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021 || REVIT2022 || REVIT2023) - if (category.Id.Value == _categoryId) -#else - if (category.Id.IntegerValue == _categoryId) -#endif - return true; - } - } - catch { } - } - - return false; - } - - public override bool IsMatch(Category category) { - try { -#if !(REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021 || REVIT2022 || REVIT2023) - return category.Id.Value == _categoryId; -#else - return category.Id.IntegerValue == _categoryId; -#endif - } - catch { } - return false; - } - - public override bool Equals(object obj) { - if (obj is int categoryId) - return _categoryId == categoryId; - else if (obj is BuiltinCategoryCondition builtinCatCond) - return _categoryId == builtinCatCond._categoryId; - else - return false; - } - - public override int GetHashCode() { - return _categoryId.GetHashCode(); - } - - public override string ToString() { - return _categoryId.ToString(); - } - } - - class CustomCategoryCondition : CategoryCondition { - string _categoryName = string.Empty; - - public CustomCategoryCondition(string categoryName) => _categoryName = categoryName.ToLower(); - - public override bool IsMatch(UIApplication uiApp, CategorySet selectedCategories) { - if (HasSelection(uiApp, selectedCategories)) { - try { - foreach (Category category in selectedCategories) - if (_categoryName.Equals(category.Name, StringComparison.InvariantCultureIgnoreCase)) - return true; - } - catch { } - } - - return false; - } - - public override bool IsMatch(Category category) { - try { - return _categoryName.Equals(category.Name, StringComparison.InvariantCultureIgnoreCase); - } - catch { } - return false; - } - - public override bool Equals(object obj) { - if (obj is string categoryName) - return _categoryName.Equals(categoryName, StringComparison.InvariantCultureIgnoreCase); - else if (obj is CustomCategoryCondition catCond) - return _categoryName.Equals(catCond._categoryName, StringComparison.InvariantCultureIgnoreCase); - else - return false; - } - - public override int GetHashCode() { - return _categoryName.GetHashCode(); - } - - public override string ToString() { - return _categoryName; - } - } - - abstract class KeywordCondition : Condition { - public abstract string Keyword { get; } - - public override bool Equals(object obj) { - if (obj is KeywordCondition) - return true; - return false; - } - - public override int GetHashCode() { - return Keyword.GetHashCode(); - } - - public override string ToString() { - return Keyword; - } - } - - class ZeroDocCondition : KeywordCondition { - public override string Keyword => "zero-doc"; - - public override bool IsMatch(UIApplication uiApp, CategorySet selectedCategories) { - return true; - } - } - - class SelectionCondition : KeywordCondition { - public override string Keyword => "selection"; - - public override bool IsMatch(UIApplication uiApp, CategorySet selectedCategories) { - return HasSelection(uiApp, selectedCategories); - } - } - - class AllCondition : CompoundCondition { - public override string Separator => new string(new char[] { CONTEXT_CONDITION_ALL_SEP }); - - public override bool IsMatch(UIApplication uiApp, CategorySet selectedCategories) { - bool res = Conditions.All(c => c.IsMatch(uiApp, selectedCategories)); - return IsNot ? !res : res; - } - } - - class AnyCondition: CompoundCondition { - public override string Separator => new string(new char[] { CONTEXT_CONDITION_ANY_SEP }); - - public override bool IsMatch(UIApplication uiApp, CategorySet selectedCategories) { - bool res = Conditions.Any(c => c.IsMatch(uiApp, selectedCategories)); - return IsNot ? !res : res; - } - } - - class ExactCondition: CompoundCondition { - public override string Separator => new string(new char[] { CONTEXT_CONDITION_EXACT_SEP }); - - public override bool IsMatch(UIApplication uiApp, CategorySet selectedCategories) { - var catConditions = Conditions.OfType(); - - // test if all category conditions are ALL in selectedCategories - if (!catConditions.All(c => c.IsMatch(uiApp, selectedCategories))) - return IsNot ? true : false; - - // test if there is no selectedCategories that isnt matching ANY condition - foreach (Category cat in selectedCategories) - if (!catConditions.Any(c => c.IsMatch(cat))) - return IsNot ? true : false; - - return IsNot ? false : true; - } - } - - public class ContextFilter { - public bool EnsureActiveDocument { get; set; } = true; - public CompoundCondition Condition { get; set; } = new AllCondition(); - - public override string ToString() { - return Condition?.ToString(); - } - } - - public ContextFilter CompiledContextFilter = null; - - public bool IsCommandAvailable(UIApplication uiApp, CategorySet selectedCategories) { - if (CompiledContextFilter is ContextFilter ctxFilter) { - if (ctxFilter.EnsureActiveDocument && !Condition.HasDocument(uiApp)) - return false; - return ctxFilter.Condition.IsMatch(uiApp, selectedCategories); - } - return false; - } - } - - - public abstract class ScriptCommandSelectionAvail : IExternalCommandAvailability { - private string _categoryName = ""; - - public ScriptCommandSelectionAvail(string contextString) { - _categoryName = contextString; - } - - public bool IsCommandAvailable(UIApplication uiApp, CategorySet selectedCategories) { - if (selectedCategories.IsEmpty) - return false; - - return true; - } - } - - - public abstract class ScriptCommandZeroDocAvail : IExternalCommandAvailability { - public ScriptCommandZeroDocAvail() { - } - - public bool IsCommandAvailable(UIApplication uiApp, CategorySet selectedCategories) { - return true; - } - } -} - diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ScriptConsole.cs b/dev/pyRevitLabs.PyRevit.Runtime/ScriptConsole.cs deleted file mode 100644 index fdbe239ce..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ScriptConsole.cs +++ /dev/null @@ -1,945 +0,0 @@ -using System; -using System.Windows; -using System.IO; -using System.Linq; -using System.Collections.Generic; -using System.Windows.Controls; -using System.Windows.Markup; -using System.Windows.Media; -using System.Windows.Threading; -using Autodesk.Revit.UI; -using System.Text.RegularExpressions; -using System.Diagnostics; - -using pyRevitLabs.Common; -using pyRevitLabs.CommonWPF.Controls; -using pyRevitLabs.Emojis; - -namespace PyRevitLabs.PyRevit.Runtime { - public struct ScriptConsoleDebugger { - public string Name; - public Regex PromptFinder; - public string DebugContinueKey; - public string DebugStepOverKey; - public string DebugStepInKey; - public string DebugStepOutKey; - public string DebugStopKey; - public List> StopFinders; - } - - public static class ScriptConsoleConfigs { - public static string DOCTYPE = ""; - public static string DOCHead = "" + - "" + - "" + - "" + - "" + - "" + - ""; - public static string DefaultBlock = "
"; - public static string ErrorBlock = "
"; - public static string IPYErrorHeader = "IronPython Traceback:"; - public static string CPYErrorHeader = "CPython Traceback:"; - public static string IRubyErrorHeader = "IronRuby Traceback:"; - public static string CLRErrorHeader = "Script Executor Traceback:"; - public static string CSharpErrorHeader = "C# Traceback:"; - public static string VBErrorHeader = "VB.NET Traceback:"; - public static string ProgressBlock = "
"; - public static string ProgressBlockId = "pbarcontainer"; - public static string ProgressBar = "
"; - public static string ProgressBarId = "pbar"; - public static string InlineWaitBlock = "
\u280b Preparing results...
"; - public static string InlineWaitBlockId = "inlnwait"; - public static List InlineWaitSequence = new List(){ - "\u280b Preparing results...", - "\u2819 Preparing results...", - "\u2838 Preparing results...", - "\u28B0 Preparing results...", - "\u28e0 Preparing results...", - "\u28c4 Preparing results...", - "\u2846 Preparing results...", - "\u2807 Preparing results..." - }; - - public static string ToCustomHtmlTags(string source) { - return source.Replace("<", "&clt;").Replace(">", "&cgt;"); - } - - public static string FromCustomHtmlTags(string source) { - return source.Replace("&clt;", "<").Replace("&cgt;", ">"); - } - - public static string EscapeForHtml(string source) { - return source.Replace("<", "<").Replace(">", ">"); - } - - public static string UnscapeFromHtml(string source) { - return source.Replace("<", "<").Replace(">", ">"); - } - - public static string EscapeForOutput(string source) { - // remove end new line - if (source.EndsWith("\n")) - source = source.Remove(source.Length - 1); - return source.Replace("\n", "
").Replace("\t", "  "); - } - } - - public partial class ScriptConsoleTemplate : pyRevitLabs.CommonWPF.Windows.AppWindow { - public ScriptConsoleTemplate() { - // setup window styles - SetupDynamicResources(); - EnablePyRevitTemplateWindowStyle(); - } - - public void EnablePyRevitTemplateWindowStyle() { - SizeChanged += ScriptOutput_SizeChanged; - - // setup template styles - Background = Brushes.White; - var glowColor = Color.FromArgb(0x66, 0x2c, 0x3e, 0x50); - // activating glow on the window causes an exception in PresentationFramework on Revit 2019 - // when closing Revit with pyRevit windows open. - //GlowBrush = new SolidColorBrush() { Color = glowColor }; - //NonActiveGlowBrush = new SolidColorBrush() { Color = glowColor }; - - ResetIcon(); - - //ResizeBorderThickness = new Thickness(10); - // added thickness after disabling glow brush due to a bug - BorderThickness = new Thickness(1); - WindowStartupLocation = WindowStartupLocation.Manual; - WindowTransitionsEnabled = false; - SaveWindowPosition = false; - } - - private void SetupDynamicResources() { - Resources.MergedDictionaries.Add(new ResourceDictionary() { - Source = new Uri("pack://application:,,,/pyRevitLabs.MahAppsMetro;component/Styles/Controls.xaml") - }); - - Resources.MergedDictionaries.Add(new ResourceDictionary() { - Source = new Uri("pack://application:,,,/pyRevitLabs.MahAppsMetro;component/Styles/Fonts.xaml") - }); - - Resources.MergedDictionaries.Add(new ResourceDictionary() { - Source = new Uri("pack://application:,,,/pyRevitLabs.MahAppsMetro;component/Styles/Themes/Light.Blue.xaml") - }); - - var accentResDict = Resources; - - var pyrevitHighlightColor = Color.FromArgb(0xFF, 0xf3, 0x9c, 0x12); - var pyrevitBackground = new SolidColorBrush() { Color = Color.FromArgb(0xFF, 0x2c, 0x3e, 0x50) }; - var pyrevitHighlight = new SolidColorBrush() { Color = pyrevitHighlightColor }; - accentResDict["MahApps.Brushes.Accent"] = pyrevitBackground; - accentResDict["MahApps.Brushes.WindowTitle"] = pyrevitBackground; - - // overriding colors on the progressbar control - var progressBarOverlay = Color.FromArgb(0x66, 0xFF, 0xFF, 0xFF); - accentResDict["MahApps.Brushes.Progress"] = pyrevitHighlight; - accentResDict["MahApps.Colors.ProgressIndeterminate1"] = progressBarOverlay; - accentResDict["MahApps.Colors.ProgressIndeterminate2"] = progressBarOverlay; - accentResDict["MahApps.Colors.ProgressIndeterminate3"] = pyrevitHighlightColor; - accentResDict["MahApps.Colors.ProgressIndeterminate4"] = pyrevitHighlightColor; - } - - private void ScriptOutput_SizeChanged(object sender, SizeChangedEventArgs e) { - Visibility isVisible = Visibility.Visible; - if (ActualWidth < 400) - isVisible = Visibility.Collapsed; - foreach (Button item in RightWindowCommands.Items) - item.Visibility = isVisible; - - this.TitleForeground = isVisible == Visibility.Visible ? Brushes.White : new SolidColorBrush() { Color = Color.FromArgb(0xFF, 0x2c, 0x3e, 0x50) }; - } - - public void ResetIcon() { - var iconPath = Path.Combine( - Path.GetDirectoryName(typeof(ActivityBar).Assembly.Location), - "pyrevit_outputwindow.png" - ); - SetIcon(iconPath); - } - } - - public partial class ScriptConsole : ScriptConsoleTemplate, IComponentConnector, IDisposable { - private bool _contentLoaded; - private bool _debugMode; - private bool _frozen = false; - private string _lastLine = string.Empty; - private DispatcherTimer _animationTimer; - private System.Windows.Forms.HtmlElement _lastDocumentBody = null; - private UIApplication _uiApp; - - private List _supportedDebuggers = - new List { - new ScriptConsoleDebugger() { - Name = "Pdb (IronPython|CPython)", - PromptFinder = new Regex(@"\(pdb\)"), - DebugContinueKey = "c", - DebugStepOverKey = "n", - DebugStepInKey = "s", - DebugStepOutKey = "r", - DebugStopKey = "q", - StopFinders = new List> { - new Tuple ( - new Regex(@"bdb.BdbQuit|BdbQuit :"), - "Debugger stopped (bdb.BdbQuit exception)" - ), - new Tuple ( - new Regex(@"pdb.Restart|Restart :"), - "Debugger stopped. Restart by running the script again (pdb.Restart exception)" - ) - } - } - }; - - // OutputUniqueId is set in constructor - // OutputUniqueId is unique for every output window - public string OutputUniqueId; - - // OutputId is set by the requesting pyRevit command - // OutputId is the same for all output windows that belong to a single pyRevit command - public string OutputId; - - // to track if user manually closed the window - public bool ClosedByUser = false; - - // is window collapsed? - private double prevHeight = 0; - public bool IsCollapsed = false; - public bool IsAutoCollapseActive = false; - // is window expanded? - public bool IsExpanded = false; - - // Html renderer and its Winforms host, and navigate handler method - public System.Windows.Forms.Integration.WindowsFormsHost host; - public System.Windows.Forms.WebBrowser renderer; - public System.Windows.Forms.WebBrowserNavigatingEventHandler _navigateHandler; - public ActivityBar activityBar; - public InputBar stdinBar; - - public ScriptConsole(bool debugMode = false, UIApplication uiApp = null) : base() { - _debugMode = debugMode; - _uiApp = uiApp; - - // setup unique id for this output window - OutputUniqueId = Guid.NewGuid().ToString(); - - InitializeComponent(); - } - - [System.Diagnostics.DebuggerNonUserCodeAttribute()] - [System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "4.0.0.0")] - public void InitializeComponent() { - if (_contentLoaded) { - return; - } - _contentLoaded = true; - - this.Loaded += Window_Loaded; - this.Closing += Window_Closing; - this.Closed += Window_Closed; - - host = new System.Windows.Forms.Integration.WindowsFormsHost(); - host.SnapsToDevicePixels = true; - - // Create the WebBrowser control. - renderer = new System.Windows.Forms.WebBrowser(); - - _navigateHandler = new System.Windows.Forms.WebBrowserNavigatingEventHandler(renderer_Navigating); - renderer.Navigating += _navigateHandler; - - // setup the default html page - SetupDefaultPage(); - - // Assign the WebBrowser control as the host control's child. - host.Child = renderer; - - #region Window Layout - - Grid baseGrid = new Grid(); - baseGrid.Margin = new Thickness(0, 0, 0, 0); - - // activiy bar - var activityBarRow = new RowDefinition(); - activityBarRow.Height = GridLength.Auto; - baseGrid.RowDefinitions.Add(activityBarRow); - activityBar = new ActivityBar(); - activityBar.Foreground = Brushes.White; - activityBar.Visibility = Visibility.Collapsed; - Grid.SetRow(activityBar, 0); - - // Add the interop host control to the Grid - // control's collection of child controls. - var rendererRow = new RowDefinition(); - baseGrid.RowDefinitions.Add(rendererRow); - Grid.SetRow(host, 1); - - // standard input bar - var stdinRow = new RowDefinition(); - stdinRow.Height = GridLength.Auto; - baseGrid.RowDefinitions.Add(stdinRow); - stdinBar = new InputBar(); - stdinBar.Visibility = Visibility.Collapsed; - Grid.SetRow(stdinBar, 2); - - // set activity bar and host - baseGrid.Children.Add(activityBar); - baseGrid.Children.Add(host); - baseGrid.Children.Add(stdinBar); - this.Content = baseGrid; - - #endregion - - #region Titlebar Buttons - // resize buttons - var expandToggleButton = new Button() { ToolTip = "Expand/Shrink Window", Focusable = false }; - expandToggleButton.Width = 32; - expandToggleButton.Content = GetExpandToggleIcon(IsExpanded); - expandToggleButton.Click += ExpandToggleButton_Click; ; - LeftWindowCommands.Items.Insert(0, expandToggleButton); - - // TODO: add report button, get email from envvars - var pinButton = new Button() { ToolTip = "Keep On Top", Focusable = false }; - pinButton.Width = 32; - pinButton.Content = GetPinIcon(Topmost); - pinButton.Click += PinButton_Click; - RightWindowCommands.Items.Insert(0, pinButton); - - var copyButton = new Button() { ToolTip = "Copy All Text", Focusable = false }; - copyButton.Width = 32; - copyButton.Content = - MakeButtonPath("M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"); - copyButton.Click += CopyButton_Click; - RightWindowCommands.Items.Insert(0, copyButton); - - var saveButton = new Button() { ToolTip = "Save Contents", Focusable = false }; - saveButton.Width = 32; - saveButton.Content = - MakeButtonPath("M15,9H5V5H15M12,19A3,3 0 0,1 9,16A3,3 0 0,1 12,13A3,3 0 0,1 15,16A3,3 0 0,1 12,19M17,3H5C3.89,3 3,3.9 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V7L17,3Z"); - saveButton.Click += Save_Contents_Button_Clicked; - RightWindowCommands.Items.Insert(0, saveButton); - - var printButton = new Button() { ToolTip = "Print Contents", Focusable = false }; - printButton.Width = 32; - printButton.Content = - MakeButtonPath("M18,3H6V7H18M19,12A1,1 0 0,1 18,11A1,1 0 0,1 19,10A1,1 0 0,1 20,11A1,1 0 0,1 19,12M16,19H8V14H16M19,8H5A3,3 0 0,0 2,11V17H6V21H18V17H22V11A3,3 0 0,0 19,8Z"); - printButton.Click += PrintButton_Click; ; - RightWindowCommands.Items.Insert(0, printButton); - - var openButton = new Button() { ToolTip = "Open in Browser", Focusable = false }; - openButton.Width = 32; - openButton.Content = - MakeButtonPath("M14,3V5H17.59L7.76,14.83L9.17,16.24L19,6.41V10H21V3M19,19H5V5H12V3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V12H19V19Z"); - openButton.Click += OpenButton_Click; - RightWindowCommands.Items.Insert(0, openButton); - - #endregion - - this.Width = 900; this.MinWidth = 700; - this.Height = 600; this.MinHeight = this.TitleBarHeight; - this.ResizeMode = ResizeMode.CanResize; - - // setup auto-collapse - this.Activated += ScriptOutput_GotFocus; - this.Deactivated += ScriptOutput_LostFocus; - - this.OutputTitle = PyRevitLabsConsts.ProductName; - } - - [System.Diagnostics.DebuggerNonUserCodeAttribute()] - [System.CodeDom.Compiler.GeneratedCodeAttribute("PresentationBuildTasks", "4.0.0.0")] - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Design", "CA1033:InterfaceMethodsShouldBeCallableByChildTypes")] - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Maintainability", "CA1502:AvoidExcessiveComplexity")] - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1800:DoNotCastUnnecessarily")] - void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) { - this._contentLoaded = true; - } - - public System.Windows.Forms.HtmlDocument ActiveDocument { get { return renderer.Document; } } - - public Version RendererVersion { - get { - return renderer.Version; - } - } - - private string GetStyleSheetFile() { - var env = new EnvDictionary(); - return env.ActiveStyleSheet; - } - - public string GetFullHtml() { - var head = ActiveDocument.GetElementsByTagName("head")[0]; - return ScriptConsoleConfigs.DOCTYPE + head.OuterHtml + ActiveDocument.Body.OuterHtml; - } - - private void SetupDefaultPage(string styleSheetFilePath = null) { - string cssFilePath; - if (styleSheetFilePath != null) - cssFilePath = styleSheetFilePath; - else - cssFilePath = GetStyleSheetFile(); - - // create the head with default styling - var dochead = string.Format( - ScriptConsoleConfigs.DOCTYPE + ScriptConsoleConfigs.DOCHead, - AppVersion, - RendererVersion, - cssFilePath - ); - // create default html - renderer.DocumentText = string.Format("{0}", dochead); - - while (ActiveDocument.Body == null) - System.Windows.Forms.Application.DoEvents(); - } - - public void WaitReadyBrowser() { - System.Windows.Forms.Application.DoEvents(); - } - - public string OutputTitle { - get { - return Title; - } - set { - Title = value; - } - } - - public void LockSize() { - this.ResizeMode = ResizeMode.NoResize; - } - - public void UnlockSize() { - this.ResizeMode = ResizeMode.CanResizeWithGrip; - } - - public void Freeze() { - WaitReadyBrowser(); - _lastDocumentBody = ActiveDocument.CreateElement(""); - _lastDocumentBody.InnerHtml = ActiveDocument.Body.InnerHtml; - _frozen = true; - UpdateInlineWaitAnimation(); - } - - public void Unfreeze() { - if (_frozen) { - WaitReadyBrowser(); - ActiveDocument.Body.InnerHtml = _lastDocumentBody.InnerHtml; - _frozen = false; - _lastDocumentBody = null; - UpdateInlineWaitAnimation(false); - } - } - - public void ScrollToBottom() { - if (ActiveDocument != null) { - ActiveDocument.Window.ScrollTo(0, ActiveDocument.Body.ScrollRectangle.Height); - } - } - - public void FocusOutput() { - renderer.Focus(); - } - - public System.Windows.Forms.HtmlElement ComposeEntry(string contents, string HtmlElementType) { - WaitReadyBrowser(); - - // order is important - // "<" ---> < - contents = ScriptConsoleConfigs.EscapeForHtml(contents); - // &clt; ---> ">" - contents = ScriptConsoleConfigs.FromCustomHtmlTags(contents); - // "\n" --->
- contents = ScriptConsoleConfigs.EscapeForOutput(contents); - // :heart: ---> \uFFFF (emoji unicode) - contents = Emojis.Emojize(contents); - - var htmlElement = ActiveDocument.CreateElement(HtmlElementType); - htmlElement.InnerHtml = contents; - return htmlElement; - } - - public void AppendText(string OutputText, string HtmlElementType, bool record = true) { - if (record) - _lastLine = OutputText; - - if (!_frozen) { - WaitReadyBrowser(); - ActiveDocument.Body.AppendChild(ComposeEntry(OutputText, HtmlElementType)); - ScrollToBottom(); - } - else if (_lastDocumentBody != null) { - _lastDocumentBody.AppendChild(ComposeEntry(OutputText, HtmlElementType)); - } - } - - public void AppendError(string OutputText, ScriptEngineType engineType) { - Unfreeze(); - string errorHeader = string.Empty; - switch (engineType) { - case ScriptEngineType.IronPython: - errorHeader = ScriptConsoleConfigs.ToCustomHtmlTags(ScriptConsoleConfigs.IPYErrorHeader); - break; - case ScriptEngineType.CPython: - errorHeader = ScriptConsoleConfigs.ToCustomHtmlTags(ScriptConsoleConfigs.CPYErrorHeader); - break; - case ScriptEngineType.CSharp: - errorHeader = ScriptConsoleConfigs.ToCustomHtmlTags(ScriptConsoleConfigs.CSharpErrorHeader); - break; - case ScriptEngineType.Invoke: - break; - case ScriptEngineType.VisualBasic: - errorHeader = ScriptConsoleConfigs.ToCustomHtmlTags(ScriptConsoleConfigs.VBErrorHeader); - break; - case ScriptEngineType.IronRuby: - errorHeader = ScriptConsoleConfigs.ToCustomHtmlTags(ScriptConsoleConfigs.IRubyErrorHeader); - break; - case ScriptEngineType.DynamoBIM: - break; - case ScriptEngineType.Grasshopper: - break; - case ScriptEngineType.Content: - break; - } - // add new line to header - if (errorHeader != string.Empty) - errorHeader += "\n"; - - // if this is a know debugger stop error - // make a nice report - foreach (var dbgr in _supportedDebuggers) { - foreach(var stopFinder in dbgr.StopFinders) { - if (stopFinder.Item1.IsMatch(OutputText)) { - AppendText( - errorHeader + stopFinder.Item2, - ScriptConsoleConfigs.ErrorBlock - ); - return; - } - } - } - - // otherwise report the error - AppendText( - errorHeader + OutputText, - ScriptConsoleConfigs.ErrorBlock - ); - } - - public string GetLastLine() { - return _lastLine; - } - - public string GetInput() { - // checkout the last line and configure the input control - string lastLine = GetLastLine().ToLower(); - // determine debugger - bool dbgMode = false; - foreach (var dbgr in _supportedDebuggers) { - if (dbgr.PromptFinder.IsMatch(lastLine)) { - stdinBar.EnableDebug( - dbgCont: dbgr.DebugContinueKey, - dbgStepOver: dbgr.DebugStepOverKey, - dbgStepIn: dbgr.DebugStepInKey, - dbgStepOut: dbgr.DebugStepOutKey, - dbgStop: dbgr.DebugStopKey - ); - dbgMode = true; - } - } - - // if no debugger, find other patterns - if (!dbgMode && - new string[] { "select", "file" }.All(x => lastLine.Contains(x))) - stdinBar.EnableFilePicker(); - - // ask for input - Activate(); Focus(); - - stdinBar.Show(); - // printing an empty line will cause the page to scroll to - // bottom again and not be covered by the input control - AppendText("", ScriptConsoleConfigs.DefaultBlock, record: false); - string inputText = stdinBar.ReadInput(); - stdinBar.Hide(); - - // return input - return inputText; - } - - private void renderer_Navigating(object sender, System.Windows.Forms.WebBrowserNavigatingEventArgs e) { - if (!(e.Url.ToString().Equals("about:blank", StringComparison.InvariantCultureIgnoreCase))) { - var inputUrl = e.Url.ToString(); - - if (inputUrl.StartsWith("http") && !inputUrl.StartsWith("http://localhost")) { - System.Diagnostics.Process.Start(inputUrl); - } - else if (inputUrl.StartsWith("revit")) { - e.Cancel = true; - ScriptConsoleUtils.ProcessUrl(_uiApp, inputUrl); - return; - } - else if (inputUrl.StartsWith("file")) { - e.Cancel = false; - return; - } - - e.Cancel = true; - } - } - - public void SetElementVisibility(bool visibility, string elementId) { - WaitReadyBrowser(); - if (ActiveDocument != null) { - var cssdisplay = visibility ? "" : "display: none;"; - var element = ActiveDocument.GetElementById(elementId); - if (element.Style != null) { - if (element.Style.Contains("display:")) - element.Style = Regex.Replace(element.Style, "display:.+?;", cssdisplay, RegexOptions.IgnoreCase); - else - element.Style += cssdisplay; - } - else - element.Style = cssdisplay; - } - } - - public void SetProgressBarVisibility(bool visibility) { - if (this.TaskbarItemInfo != null) - // taskbar progress object - this.TaskbarItemInfo.ProgressState = visibility ? System.Windows.Shell.TaskbarItemProgressState.Normal : System.Windows.Shell.TaskbarItemProgressState.None; - - WaitReadyBrowser(); - if (ActiveDocument != null) { - var cssdisplay = visibility ? "" : "display: none;"; - var pbarcontainer = ActiveDocument.GetElementById(ScriptConsoleConfigs.ProgressBlockId); - if (pbarcontainer.Style != null) { - if (pbarcontainer.Style.Contains("display:")) - pbarcontainer.Style = Regex.Replace(pbarcontainer.Style, "display:.+?;", - cssdisplay, - RegexOptions.IgnoreCase); - else - pbarcontainer.Style += cssdisplay; - } - else - pbarcontainer.Style = cssdisplay; - } - } - - public void SetActivityBarVisibility(bool visibility) { - activityBar.Visibility = visibility ? Visibility.Visible : Visibility.Collapsed; - } - - public void UpdateTaskBarProgress(float curValue, float maxValue) { - if (this.TaskbarItemInfo == null) { - // taskbar progress object - var taskbarinfo = new System.Windows.Shell.TaskbarItemInfo(); - taskbarinfo.ProgressState = System.Windows.Shell.TaskbarItemProgressState.Normal; - this.TaskbarItemInfo = taskbarinfo; - } - - this.TaskbarItemInfo.ProgressValue = curValue / maxValue; - } - - public void UpdateTaskBarProgress(bool indeterminate) { - if (this.TaskbarItemInfo == null) { - // taskbar progress object - var taskbarinfo = new System.Windows.Shell.TaskbarItemInfo(); - taskbarinfo.ProgressState = System.Windows.Shell.TaskbarItemProgressState.Indeterminate; - this.TaskbarItemInfo = taskbarinfo; - } - } - - public void UpdateActivityBar(float curValue, float maxValue) { - if (this.ClosedByUser) { - return; - } - - UpdateTaskBarProgress(curValue, maxValue); - activityBar.UpdateProgressBar(curValue, maxValue); - SetActivityBarVisibility(true); - } - - public void UpdateActivityBar(bool indeterminate) { - if (this.ClosedByUser) { - return; - } - - UpdateTaskBarProgress(indeterminate); - activityBar.IsActive = indeterminate; - SetActivityBarVisibility(indeterminate); - } - - public void UpdateProgressBar(float curValue, float maxValue) { - if (this.ClosedByUser) { - return; - } - - UpdateTaskBarProgress(curValue, maxValue); - - WaitReadyBrowser(); - if (ActiveDocument != null) { - if (!this.IsVisible) { - try { - this.Show(); - this.Focus(); - } - catch { - return; - } - } - - var pbargraph = ActiveDocument.GetElementById(ScriptConsoleConfigs.ProgressBarId); - if (pbargraph == null) { - if (ActiveDocument != null) { - var pbar = ActiveDocument.CreateElement(ScriptConsoleConfigs.ProgressBlock); - var newpbargraph = ActiveDocument.CreateElement(ScriptConsoleConfigs.ProgressBar); - pbar.AppendChild(newpbargraph); - ActiveDocument.Body.AppendChild(pbar); - } - - pbargraph = ActiveDocument.GetElementById(ScriptConsoleConfigs.ProgressBarId); - } - - SetProgressBarVisibility(true); - - var newWidthStyleProperty = string.Format("width:{0}%;", (curValue / maxValue) * 100); - if (pbargraph.Style == null) - pbargraph.Style = newWidthStyleProperty; - else - pbargraph.Style = Regex.Replace(pbargraph.Style, "width:.+?;", newWidthStyleProperty, RegexOptions.IgnoreCase); - } - } - - public void UpdateInlineWaitAnimation(bool state = true) { - if (state) { - _animationTimer = new DispatcherTimer(); - _animationTimer.Tick += (sender, e) => { - UpdateInlineWait(); - }; - _animationTimer.Interval = new TimeSpan(0, 0, 0, 0, 100); - _animationTimer.Start(); - } - else if (_animationTimer != null) { - _animationTimer.Stop(); - _animationTimer = null; - } - } - - public void UpdateInlineWait() { - if (this.ClosedByUser) { - return; - } - - WaitReadyBrowser(); - if (ActiveDocument != null) { - if (!this.IsVisible) { - try { - this.Show(); - this.Focus(); - } - catch { - return; - } - } - - var inlinewait = ActiveDocument.GetElementById(ScriptConsoleConfigs.InlineWaitBlockId); - if (inlinewait == null) { - if (ActiveDocument != null) { - inlinewait = ActiveDocument.CreateElement(ScriptConsoleConfigs.InlineWaitBlock); - ActiveDocument.Body.AppendChild(inlinewait); - } - - inlinewait = ActiveDocument.GetElementById(ScriptConsoleConfigs.InlineWaitBlockId); - } - - SetElementVisibility(true, ScriptConsoleConfigs.InlineWaitBlockId); - - int idx = ScriptConsoleConfigs.InlineWaitSequence.IndexOf(inlinewait.InnerText); - if (idx + 1 > ScriptConsoleConfigs.InlineWaitSequence.Count - 1) - idx = 0; - inlinewait.InnerText = ScriptConsoleConfigs.InlineWaitSequence[idx + 1]; - ScrollToBottom(); - } - } - - public void SelfDestructTimer(int seconds) { - var dispatcherTimer = new DispatcherTimer(); - dispatcherTimer.Tick += (sender, e) => { - var dt = (DispatcherTimer)sender; - dt.Stop(); - Close(); - }; - dispatcherTimer.Interval = new TimeSpan(0, 0, seconds); - dispatcherTimer.Start(); - } - - private void Window_Loaded(object sender, System.EventArgs e) { - var outputWindow = (ScriptConsole)sender; - ScriptConsoleManager.AppendToOutputWindowList(this); - } - - private void Window_Closing(object sender, System.ComponentModel.CancelEventArgs e) { - var outputWindow = (ScriptConsole)sender; - - outputWindow.stdinBar.CancelRead(); - - ScriptConsoleManager.RemoveFromOutputList(this); - - outputWindow.renderer.Navigating -= _navigateHandler; - outputWindow._navigateHandler = null; - } - - private void Window_Closed(object sender, System.EventArgs e) { - var outputWindow = (ScriptConsole)sender; - - var grid = (Grid)outputWindow.Content; - grid.Children.Remove(host); - grid.Children.Clear(); - - outputWindow.renderer.Dispose(); - outputWindow.renderer = null; - - outputWindow.host = null; - outputWindow.Content = null; - - outputWindow.ClosedByUser = true; - } - - private System.Windows.Shapes.Path MakeButtonPath(string geom, int size = 14) { - var path = new System.Windows.Shapes.Path(); - path.Stretch = Stretch.Uniform; - path.Height = size; - path.Fill = Brushes.White; - path.Data = Geometry.Parse(geom); - return path; - } - - private System.Windows.Shapes.Path GetPinIcon(bool pinned) { - if (pinned) - return MakeButtonPath("M16,12V4H17V2H7V4H8V12L6,14V16H11.2V22H12.8V16H18V14L16,12Z"); - else - return MakeButtonPath("M2,5.27L3.28,4L20,20.72L18.73,22L12.8,16.07V22H11.2V16H6V14L8,12V11.27L2,5.27M16,12L18,14V16H17.82L8,6.18V4H7V2H17V4H16V12Z"); - } - - private System.Windows.Shapes.Path GetAutoCollapseIcon(bool active) { - if (active) - return MakeButtonPath("M4.08,11.92L12,4L19.92,11.92L18.5,13.33L13,7.83V22H11V7.83L5.5,13.33L4.08,11.92M12,4H22V2H2V4H12Z"); - else - return MakeButtonPath("M19.92,12.08L12,20L4.08,12.08L5.5,10.67L11,16.17V2H13V16.17L18.5,10.66L19.92,12.08M12,20H2V22H22V20H12Z"); - } - - private void Save_Contents_Button_Clicked(object sender, RoutedEventArgs e) { - var saveDlg = new System.Windows.Forms.SaveFileDialog() { - Title = "Save Output to:", - Filter = "HTML|*.html" - }; - saveDlg.ShowDialog(); - var f = File.CreateText(saveDlg.FileName); - f.Write(GetFullHtml()); - f.Close(); - } - - private void PinButton_Click(object sender, RoutedEventArgs e) { - var button = e.Source as Button; - if (Topmost) { - if (IsAutoCollapseActive) { - Topmost = false; - IsAutoCollapseActive = false; - button.Content = GetPinIcon(false); - button.ToolTip = "Keep On Top"; - } else { - IsAutoCollapseActive = true; - button.Content = GetAutoCollapseIcon(true); - button.ToolTip = "Release"; - } - } - else { - if (IsAutoCollapseActive) - IsAutoCollapseActive = false; - Topmost = true; - IsAutoCollapseActive = false; - button.Content = GetPinIcon(true); - button.ToolTip = "Activate Auto Collapse"; - } - } - - private System.Windows.Shapes.Path GetExpandToggleIcon(bool expanded) { - if (expanded) - return MakeButtonPath("M19,6.41L17.59,5L7,15.59V9H5V19H15V17H8.41L19,6.41Z", size: 12); - else - return MakeButtonPath("M5,17.59L15.59,7H9V5H19V15H17V8.41L6.41,19L5,17.59Z", size: 12); - } - - private void ExpandToggleButton_Click(object sender, RoutedEventArgs e) { - var button = e.Source as Button; - - if (IsExpanded) { - Width = Width / 2; - IsExpanded = false; - button.Content = GetExpandToggleIcon(IsExpanded); - button.ToolTip = "Expand"; - } - else { - Width = Width * 2; - IsExpanded = true; - button.Content = GetExpandToggleIcon(IsExpanded); - button.ToolTip = "Shrink"; - } - } - - private string SaveContentsToTemp() { - string tempHtml = Path.Combine(UserEnv.UserTemp, string.Format("{0}.html", OutputTitle)); - var f = File.CreateText(tempHtml); - f.Write(GetFullHtml()); - f.Close(); - return tempHtml; - } - - private void OpenButton_Click(object sender, RoutedEventArgs e) { - Process.Start(string.Format("file:///{0}", SaveContentsToTemp())); - } - - private void PrintButton_Click(object sender, RoutedEventArgs e) { - renderer.ShowPrintPreviewDialog(); - } - - private void CopyButton_Click(object sender, RoutedEventArgs e) { - Clipboard.SetText(ActiveDocument.Body.InnerText); - var notif = new ToolTip() { Content = "Copied to Clipboard" }; - notif.StaysOpen = false; - notif.IsOpen = true; - } - - private void CollapseWindow() { - prevHeight = Height; - Height = TitleBarHeight; - //ResizeBorderThickness = new Thickness(0); - IsCollapsed = true; - } - - private void UnCollapseWindow() { - Height = prevHeight; - //ResizeBorderThickness = new Thickness(10); - IsCollapsed = false; - } - - private void ScriptOutput_GotFocus(object sender, EventArgs e) { - if (IsAutoCollapseActive && IsCollapsed) - UnCollapseWindow(); - } - - private void ScriptOutput_LostFocus(object sender, EventArgs e) { - if (IsAutoCollapseActive && !IsCollapsed) - CollapseWindow(); - } - - public void Dispose() { - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ScriptConsoleManager.cs b/dev/pyRevitLabs.PyRevit.Runtime/ScriptConsoleManager.cs deleted file mode 100644 index 77f97bfc9..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ScriptConsoleManager.cs +++ /dev/null @@ -1,124 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Reflection; - - -namespace PyRevitLabs.PyRevit.Runtime { - public static class ScriptConsoleManager - { - public static FieldInfo GetField(Object outputWindow, string fieldName) - { - return outputWindow.GetType().GetField(fieldName); - } - - public static MethodInfo GetMethod(Object outputWindow, string methodName) - { - return outputWindow.GetType().GetMethod(methodName); - } - - public static string GetOutputWindowId(Object outputWindow, string defaultId = "") - { - var outputIdProp = GetField(outputWindow, "OutputId"); - if (outputIdProp != null) - { - var outputId = outputIdProp.GetValue(outputWindow); - if (outputId != null) - return (string)outputId; - } - - return defaultId; - } - - public static string GetOutputWindowUniqueId(Object outputWindow, string defaultId = "") - { - var uniqueIdProp = GetField(outputWindow, "OutputUniqueId"); - if (uniqueIdProp != null) - { - var uniqueId = uniqueIdProp.GetValue(outputWindow); - if (uniqueId != null) - return (string)uniqueId; - } - - return defaultId; - } - - public static void CallCloseMethod(Object outputObj) - { - var closeMethod = GetMethod(outputObj, "Close"); - - if (closeMethod != null) - { - closeMethod.Invoke(outputObj, null); - } - } - - public static List ActiveOutputWindows - { - get - { - var outputWindowList = (List)AppDomain.CurrentDomain.GetData(DomainStorageKeys.OutputWindowsDictKey); - if (outputWindowList == null) - { - var newOutputWindowList = new List(); - AppDomain.CurrentDomain.SetData(DomainStorageKeys.OutputWindowsDictKey, newOutputWindowList); - return newOutputWindowList; - } - else - return outputWindowList; - } - - set - { - AppDomain.CurrentDomain.SetData(DomainStorageKeys.OutputWindowsDictKey, value); - } - } - - public static List GetAllActiveOutputWindows(string outputWindowId = null) - { - if (outputWindowId != null) - { - var newOutputWindowList = new List(); - foreach (Object activeScriptOutput in ActiveOutputWindows) - if (GetOutputWindowId(activeScriptOutput) == outputWindowId) - newOutputWindowList.Add(activeScriptOutput); - return newOutputWindowList; - } - else - return ActiveOutputWindows; - } - - public static void AppendToOutputWindowList(Object outputWindow) - { - ActiveOutputWindows.Add(outputWindow); - } - - public static void RemoveFromOutputList(Object outputWindow) - { - var newOutputWindowList = new List(); - foreach (Object activeOutputWindow in ActiveOutputWindows) - { - if (GetOutputWindowUniqueId(activeOutputWindow) != GetOutputWindowUniqueId(outputWindow)) - newOutputWindowList.Add(activeOutputWindow); - } - - ActiveOutputWindows = newOutputWindowList; - } - - public static void CloseActiveOutputWindows(Object excludeOutputWindow = null, string filterOutputWindowId = null) - { - if (excludeOutputWindow != null) - { - foreach (Object activeOutputWindow in GetAllActiveOutputWindows(filterOutputWindowId)) - if (GetOutputWindowUniqueId(excludeOutputWindow) != GetOutputWindowUniqueId(activeOutputWindow)) - CallCloseMethod(activeOutputWindow); - } - else - { - foreach (Object activeOutputWindow in GetAllActiveOutputWindows()) - CallCloseMethod(activeOutputWindow); - - ActiveOutputWindows = null; - } - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ScriptConsoleUtils.cs b/dev/pyRevitLabs.PyRevit.Runtime/ScriptConsoleUtils.cs deleted file mode 100644 index 78c6735f3..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ScriptConsoleUtils.cs +++ /dev/null @@ -1,124 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Web; -using Autodesk.Revit.DB; -using Autodesk.Revit.UI; - -#if (REVIT2013 || REVIT2014) -using Autodesk.Revit.UI.Selection; -#endif - -namespace PyRevitLabs.PyRevit.Runtime { - public class ScriptConsoleUtils { - public static void ProcessUrl(UIApplication uiApp, string inputUrl) { - var parsedQuery = HttpUtility.ParseQueryString(inputUrl.Split('?')[1]); - - if (parsedQuery["command"] == "select" && parsedQuery["element[]"] != null) { - var idList = new List(); - foreach (string strId in parsedQuery["element[]"].Split(',')) { -#if !(REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021 || REVIT2022 || REVIT2023) - idList.Add(new ElementId(Convert.ToInt64(strId))); -#else - idList.Add(new ElementId(Convert.ToInt32(strId))); -#endif - } - - SelectElements(uiApp, idList, parsedQuery.AllKeys.Contains("show") && parsedQuery["show"] == "true"); - } - } - - public static void SelectElements(UIApplication uiApp, List elementIds, bool show) { - var uidoc = uiApp.ActiveUIDocument; - - if (uidoc != null) { - var doc = uiApp.ActiveUIDocument.Document; - - // is there is only one element and it has owner view - // open the view, isolate the element, zoom fit the view, unisolate - // this would zoom in on that element only - if (doc != null && elementIds.Count >= 1) { - // get all open ui views, to be able to zoom later on - var openUIViews = uidoc.GetOpenUIViews(); - - // get the first one - var el = doc.GetElement(elementIds[0]); - - // if element is a view, open the view - Type elType = el.GetType(); - if (elType == typeof(View) || elType.IsSubclassOf(typeof(View))) { - uidoc.ActiveView = (View)el; - } - // if element is a 2D element and has an owner view - // open the view and zoom to element - else if (el.OwnerViewId != ElementId.InvalidElementId) { - // if all 2D elements are in the same view - bool sameOwnerView = true; - foreach (var elid in elementIds) - if (doc.GetElement(elid).OwnerViewId != el.OwnerViewId) - sameOwnerView = false; - - if (sameOwnerView) { - // get the view and activate - View view = (View)doc.GetElement(el.OwnerViewId); - uidoc.ActiveView = view; - - // islolate the element, deselect, and zoom fit - // add host elements for tags since tags will not be visible without their host - var elementIdsToIsolate = new List(); - foreach (var elid in elementIds) { - var element = doc.GetElement(elid); -#if !(REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020 || REVIT2021 || REVIT2022) - if (element.GetType() == typeof(IndependentTag)) { - var hostId = ((IndependentTag)element).GetTaggedLocalElementIds().FirstOrDefault(); - if (hostId != ElementId.InvalidElementId) - elementIdsToIsolate.Add(hostId); - } -#else - if (element.GetType() == typeof(IndependentTag)) { - var hostId = ((IndependentTag)element).TaggedLocalElementId; - if (hostId != ElementId.InvalidElementId) - elementIdsToIsolate.Add(hostId); - } -#endif - } - - elementIdsToIsolate.AddRange(elementIds); - // islolate the element, deselect, and zoom fit - if (show) - uidoc.ShowElements(elementIdsToIsolate); - } - } - // if element is a 3D element and does not have an owner view - // get the current view and try to zoom the element - else if (el.OwnerViewId == ElementId.InvalidElementId) { - // get the current view - View view = (View)uidoc.ActiveView; - - // islolate the element, deselect, and zoom fit - if (show) - uidoc.ShowElements(elementIds); - } - - } - - // now select the element(s) - -#if (REVIT2013 || REVIT2014) - var elementSet = SelElementSet.Create(); - foreach (ElementId elId in elementIds) { - var element = doc.GetElement(elId); - if (element != null) - elementSet.Add(element); - } - - uidoc.Selection.Elements = elementSet; -#else - uidoc.Selection.SetElementIds(elementIds); -#endif - - } - - } - } -} \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ScriptData.cs b/dev/pyRevitLabs.PyRevit.Runtime/ScriptData.cs deleted file mode 100644 index cddda4a7b..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ScriptData.cs +++ /dev/null @@ -1,15 +0,0 @@ -namespace PyRevitLabs.PyRevit.Runtime { - public class ScriptData { - public string ScriptPath { get; set; } - public string ConfigScriptPath { get; set; } - public string CommandUniqueId { get; set; } - public string CommandControlId { get; set; } - public string CommandName { get; set; } - public string CommandBundle { get; set; } - public string CommandExtension { get; set; } - public string CommandContext { get; set; } - - public string HelpSource { get; set; } - public string Tooltip { get; set; } - } -} \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ScriptEngineManager.cs b/dev/pyRevitLabs.PyRevit.Runtime/ScriptEngineManager.cs deleted file mode 100644 index f4ce0c201..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ScriptEngineManager.cs +++ /dev/null @@ -1,75 +0,0 @@ -using System; -using System.Collections.Generic; - -namespace PyRevitLabs.PyRevit.Runtime { - public static class ScriptEngineManager { - public static T GetEngine(ref ScriptRuntime runtime) where T : ScriptEngine, new() { - T engine = new T(); - engine.Init(ref runtime); - - if (engine.UseNewEngine) { - SetCachedEngine(engine.TypeId, engine); - } - else { - var cachedEngine = GetCachedEngine(engine.TypeId); - if (cachedEngine != null) { - engine = cachedEngine; - engine.RecoveredFromCache = true; - } - else - SetCachedEngine(engine.TypeId, engine); - } - return engine; - } - - // dicts need to be flexible type since multiple signatures of the ScriptEngine - // type could be placed inside this dictionary between pyRevit live reloads - public static Dictionary EngineDict { - get { - Dictionary engineDict; - var exstDict = AppDomain.CurrentDomain.GetData(DomainStorageKeys.EnginesDictKey); - if (exstDict == null) { - engineDict = new Dictionary(); - AppDomain.CurrentDomain.SetData(DomainStorageKeys.EnginesDictKey, engineDict); - } - else - engineDict = (Dictionary)exstDict; - return engineDict; - } - } - - public static Dictionary ClearEngines(string excludeEngine = null) { - // shutdown all existing engines - foreach (KeyValuePair engineRecord in EngineDict) { - if (engineRecord.Key == excludeEngine) - continue; - else - engineRecord.Value.GetType().GetMethod("Shutdown").Invoke(engineRecord.Value, new object[] { }); - } - - // create a new list - var newEngineDict = new Dictionary(); - AppDomain.CurrentDomain.SetData(DomainStorageKeys.EnginesDictKey, newEngineDict); - return newEngineDict; - } - - private static T GetCachedEngine(string engineTypeId) where T : ScriptEngine, new() { - if (EngineDict.ContainsKey(engineTypeId)) { - try { - return (T)EngineDict[engineTypeId]; - } - catch (InvalidCastException) { - return null; - } - } - return null; - } - - private static void SetCachedEngine(string engineTypeId, T engine) where T : ScriptEngine, new() { - var cachedEngine = GetCachedEngine(engine.TypeId); - if (cachedEngine != null) - cachedEngine.Shutdown(); - EngineDict[engineTypeId] = engine; - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ScriptEngines.cs b/dev/pyRevitLabs.PyRevit.Runtime/ScriptEngines.cs deleted file mode 100644 index ccdcb1f41..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ScriptEngines.cs +++ /dev/null @@ -1,46 +0,0 @@ -using pyRevitLabs.Common; - -namespace PyRevitLabs.PyRevit.Runtime { - public enum ScriptEngineType { - Unknown, - IronPython, - CPython, - CSharp, - Invoke, - VisualBasic, - IronRuby, - DynamoBIM, - Grasshopper, - Content, - HyperLink - } - - public class ScriptEngineConfigs { - } - - public class ScriptEngine { - public string Id { get; private set; } - public string TypeId { get; private set; } - - public virtual bool UseNewEngine { get; set; } - public virtual bool RecoveredFromCache { get; set; } - - public virtual void Init(ref ScriptRuntime runtime) { - Id = CommonUtils.NewShortUUID(); - // unqiue typeid of the engine - // based on session_id, engine type, and command extension - TypeId = string.Join(":", - runtime.SessionUUID, - runtime.EngineType.ToString(), - runtime.ScriptData.CommandExtension); - - // default to false since this is a new engine - RecoveredFromCache = false; - } - - public virtual void Start(ref ScriptRuntime runtime) { } - public virtual int Execute(ref ScriptRuntime runtime) { return ScriptExecutorResultCodes.Succeeded; } - public virtual void Stop(ref ScriptRuntime runtime) { } - public virtual void Shutdown() { } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ScriptExecutor.cs b/dev/pyRevitLabs.PyRevit.Runtime/ScriptExecutor.cs deleted file mode 100644 index c25dc23a1..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ScriptExecutor.cs +++ /dev/null @@ -1,199 +0,0 @@ -using System.IO; -using System.Threading; - -using Autodesk.Revit.UI; - -using pyRevitLabs.Common; - -namespace PyRevitLabs.PyRevit.Runtime { - public static class ScriptExecutorResultCodes { - public static int Succeeded = 0; - public static int SysExited = 1; - public static int ExecutionException = 2; - public static int CompileException = 3; - public static int EngineNotImplementedException = 4; - public static int ExternalInterfaceNotImplementedException = 5; - public static int FailedLoadingContent = 6; - public static int BadCommandArguments = 7; - public static int NotSupportedFeatureException = 8; - public static int UnknownException = 9; - public static int MissingTargetScript = 10; - public static int DelayedExecutionRequested = 11; - public static int FailedDelayedExecutionRequest = 12; - public static int DelayedExecutionException = 13; - public static int ExecutorNotInitialized = 14; - } - - public class ScriptExecutorExternalEventHandler : IExternalEventHandler { - public ScriptData ScriptData; - public ScriptRuntimeConfigs ScriptRuntimeConfigs; - public int Result = ScriptExecutorResultCodes.DelayedExecutionException; - - public void Execute(UIApplication uiApp) { - if (ScriptData != null && ScriptRuntimeConfigs != null) { - // provide the given uiapp - ScriptRuntimeConfigs.UIApp = uiApp; - - // request execution and set results - Result = ScriptExecutor.ExecuteScript(ScriptData, ScriptRuntimeConfigs); - } - } - - public string GetName() { - return "ScriptExecutorExternalEventHandler"; - } - } - - public class ScriptExecutorConfigs { - public bool WaitForResult = true; - public bool SendTelemetry = false; - } - - /// Executes a script - public class ScriptExecutor { - private static int mainThreadId; - private static ScriptExecutorExternalEventHandler extExecEventHandler; - private static ExternalEvent extExecEvent; - - public static void Initialize() { - mainThreadId = Thread.CurrentThread.ManagedThreadId; - extExecEventHandler = new ScriptExecutorExternalEventHandler(); - extExecEvent = ExternalEvent.Create(extExecEventHandler); - } - - /// Run the script and print the output to a new output window. - public static int ExecuteScript(ScriptData scriptData, ScriptRuntimeConfigs scriptRuntimeCfg, ScriptExecutorConfigs scriptExecConfigs = null) { - // make sure there is base configs - scriptExecConfigs = scriptExecConfigs == null ? new ScriptExecutorConfigs() : scriptExecConfigs; - - if (mainThreadId != 0) { - if (Thread.CurrentThread.ManagedThreadId == mainThreadId) - return ExecuteScriptNow(scriptData, scriptRuntimeCfg, scriptExecConfigs); - else - return RequestExecuteScript(scriptData, scriptRuntimeCfg, scriptExecConfigs); - } - - return ScriptExecutorResultCodes.ExecutorNotInitialized; - } - - private static int ExecuteScriptNow(ScriptData scriptData, ScriptRuntimeConfigs scriptRuntimeCfg, ScriptExecutorConfigs scriptExecConfigs) { - // create runtime - var runtime = new ScriptRuntime(scriptData, scriptRuntimeCfg); - - // determine which engine to use, and execute - if (EnsureTargetScript(ref runtime)) { - switch (runtime.EngineType) { - case ScriptEngineType.IronPython: - ExecuteManagedScript(ref runtime); - break; - - case ScriptEngineType.CPython: - ExecuteManagedScript(ref runtime); - break; - - case ScriptEngineType.CSharp: - ExecuteManagedScript(ref runtime); - break; - - case ScriptEngineType.Invoke: - ExecuteManagedScript(ref runtime); - break; - - case ScriptEngineType.VisualBasic: - ExecuteManagedScript(ref runtime); - break; - - case ScriptEngineType.IronRuby: - ExecuteManagedScript(ref runtime); - break; - - case ScriptEngineType.DynamoBIM: - ExecuteManagedScript(ref runtime); - break; - - case ScriptEngineType.Grasshopper: - ExecuteManagedScript(ref runtime); - break; - - case ScriptEngineType.Content: - ExecuteManagedScript(ref runtime); - break; - - case ScriptEngineType.HyperLink: - ExecuteManagedScript(ref runtime); - break; - - default: - // should not get here - throw new PyRevitException("Unknown engine type."); - } - } - else - runtime.ExecutionResult = ScriptExecutorResultCodes.MissingTargetScript; - - // Log results - int result = runtime.ExecutionResult; - if (scriptExecConfigs.SendTelemetry) - ScriptTelemetry.LogScriptTelemetryRecord(ref runtime); - - // GC cleanups - var re = runtime.ExecutionResult; - runtime.Dispose(); - runtime = null; - - // return the result - return result; - } - - private static int RequestExecuteScript(ScriptData scriptData, ScriptRuntimeConfigs scriptRuntimeCfg, ScriptExecutorConfigs scriptExecConfigs) { - if (extExecEventHandler != null) { - extExecEventHandler.ScriptData = scriptData; - extExecEventHandler.ScriptRuntimeConfigs = scriptRuntimeCfg; - - // request command exec now - extExecEvent.Raise(); - - // wait until the script is executed - if (scriptExecConfigs.WaitForResult) { - while (extExecEvent.IsPending) ; - return extExecEventHandler.Result; - } - // otherwise - return ScriptExecutorResultCodes.DelayedExecutionRequested; - } - - return ScriptExecutorResultCodes.FailedDelayedExecutionRequest; - } - - public static bool EnsureTargetScript(ref ScriptRuntime runtime) { - if (runtime.ScriptRuntimeConfigs.ConfigMode) - return EnsureTargetScript(runtime.ScriptData.ConfigScriptPath); - else - return EnsureTargetScript(runtime.ScriptData.ScriptPath); - } - - public static bool EnsureTargetScript(string scriptFile) { - if (File.Exists(scriptFile)) - return true; - TaskDialog.Show(PyRevitLabsConsts.ProductName, "Can not find target file. Maybe deleted?"); - return false; - } - - private static void ExecuteManagedScript(ref ScriptRuntime runtime) where T : ScriptEngine, new() { - // 1: ---------------------------------------------------------------------------------------------------- - // get new engine manager (EngineManager manages document-specific engines) - // and ask for an engine (EngineManager return either new engine or an already active one) - T engine = ScriptEngineManager.GetEngine(ref runtime); - - // init the engine - engine.Start(ref runtime); - // execute - var result = engine.Execute(ref runtime); - // stop and cleanup the engine - engine.Stop(ref runtime); - - // set result - runtime.ExecutionResult = result; - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ScriptIO.cs b/dev/pyRevitLabs.PyRevit.Runtime/ScriptIO.cs deleted file mode 100644 index cafae9b76..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ScriptIO.cs +++ /dev/null @@ -1,232 +0,0 @@ -using System; -using System.IO; -using System.Text; -using pyRevitLabs.Common.Extensions; - -namespace PyRevitLabs.PyRevit.Runtime { - /// A stream to write output to... - /// This can be passed into the python interpreter to render all output to. - /// Only a minimal subset is actually implemented - this is all we really expect to use. - public class ScriptIO : Stream, IDisposable { - private WeakReference _runtime; - private WeakReference _gui; - private string _outputBuffer; - private bool _inputReceived = false; - private bool _errored = false; - private ScriptEngineType _erroredEngine; - - public bool PrintDebugInfo = false; - - public ScriptIO(ScriptRuntime runtime) { - _outputBuffer = string.Empty; - _runtime = new WeakReference(runtime); - _gui = new WeakReference(null); - } - - public ScriptIO(ScriptConsole gui) { - _outputBuffer = string.Empty; - _runtime = new WeakReference(null); - _gui = new WeakReference(gui); - } - - public ScriptConsole GetOutput() { - ScriptRuntime runtime; - var re = _runtime.TryGetTarget(out runtime); - if (re && runtime != null) - return runtime.OutputWindow; - - ScriptConsole output; - re = _gui.TryGetTarget(out output); - if (re && output != null) - return output; - - return null; - } - - public Encoding OutputEncoding { - get { - return Encoding.UTF8; - } - } - - // this is for python stream compatibility - public void write(string content) { - var buffer = OutputEncoding.GetBytes(content); - Write(buffer, 0, buffer.Length); - } - - public void WriteError(string error_msg, ScriptEngineType engineType) { - _errored = true; - _erroredEngine = engineType; - foreach (string message_part in error_msg.SplitIntoChunks(1024)) { - var buffer = OutputEncoding.GetBytes(message_part); - Write(buffer, 0, buffer.Length); - } - } - - public override void Write(byte[] buffer, int offset, int count) { - var output = GetOutput(); - if (output != null) { - if (output.ClosedByUser) { - _gui = null; - _outputBuffer = string.Empty; - return; - } - - if (!output.IsVisible) { - try { - output.Show(); - output.Focus(); - } - catch { - return; - } - } - - lock (this) { - - var tempBuffer = new byte[count]; - Array.Copy(buffer, offset, tempBuffer, 0, count); - var outputText = OutputEncoding.GetString(tempBuffer); - - // append output to the buffer - _outputBuffer += outputText; - - // log buffer information in debug mode - if (PrintDebugInfo) - output.AppendText( - string.Format("<---- W offset: {0} count: {1} ---->", offset, count), - ScriptConsoleConfigs.DefaultBlock); - - if (count < 1024) { - // write to output window - if (!_errored) - output.AppendText(_outputBuffer, ScriptConsoleConfigs.DefaultBlock); - else - output.AppendError(_outputBuffer, _erroredEngine); - - // reset buffer and flush state for next time - _outputBuffer = string.Empty; - } - } - } - } - - public override void Flush() { - } - - public override long Seek(long offset, SeekOrigin origin) { - throw new NotImplementedException(); - } - - public override void SetLength(long value) { - throw new NotImplementedException(); - } - - public string read(int size = -1) { - return readline(size); - } - - public string readline(int size=-1) { - var buffer = new byte[1024]; - // we know how read works so don't need to read size until - // zero and make multiple calls - Read(buffer, 0, 1024); - // second call to clear the flag - Read(buffer, 0, 1024); - return OutputEncoding.GetString(buffer); - } - - public override int Read(byte[] buffer, int offset, int count) { - if (buffer == null) - throw new ArgumentNullException("buffer", "buffer is null"); - if (count < 0 || offset < 0) - throw new ArgumentException("offset or count is negative."); - if (offset + count > buffer.Length) - throw new IndexOutOfRangeException("The sum of offset and count is larger than the buffer length."); - - var output = GetOutput(); - if (output != null) { - if (output.ClosedByUser) { - _gui = null; - _outputBuffer = string.Empty; - return 0; - } - - if (!output.IsVisible) { - try { - output.Show(); - output.Focus(); - } - catch { - return 0; - } - } - - lock (this) { - string input = string.Empty; - - // called will call .Read until it gets a 0 - // we don't buffer the input as will copy the complete - // input data on the first call. so we need a way to - // return 0 when caller calls .Read again - if (_inputReceived) { - _inputReceived = false; - return 0; - } - - input = output.GetInput(); - _inputReceived = true; - - // log buffer information in debug mode - if (PrintDebugInfo) - output.AppendText( - string.Format("<---- R offset: {0} count: {1} ---->", offset, count), - ScriptConsoleConfigs.DefaultBlock); - - var inputBytes = OutputEncoding.GetBytes(input); - if (inputBytes.Length > 0) { - int copyCount = Math.Min(inputBytes.Length, count); - Buffer.BlockCopy(inputBytes, 0, buffer, offset, copyCount); - if (PrintDebugInfo) - output.AppendText( - string.Format("<---- R copied: \"{0}\" size: {1} ---->", input, copyCount), - ScriptConsoleConfigs.DefaultBlock); - } - - // return the size of copied data - return inputBytes.Length; - } - } - - return 0; - } - - public override bool CanRead { - get { return true; } - } - - public override bool CanSeek { - get { return false; } - } - - public override bool CanWrite { - get { return true; } - } - - public override long Length { - get { return 0; } - } - - public override long Position { - get { return 0; } - set { } - } - - new public void Dispose() { - _runtime = null; - _gui = null; - Dispose(true); - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/ScriptTelemetry.cs b/dev/pyRevitLabs.PyRevit.Runtime/ScriptTelemetry.cs deleted file mode 100644 index 05490292b..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/ScriptTelemetry.cs +++ /dev/null @@ -1,103 +0,0 @@ -using System.Collections.Generic; -using System.Threading.Tasks; - -using pyRevitLabs.Json; - -namespace PyRevitLabs.PyRevit.Runtime { - public class ScriptTelemetryRecordEngineInfo { - public string type { get; set; } - public string version { get; set; } - public List syspath { get; set; } - public Dictionary configs { get; set; } - } - - public class ScriptTelemetryRecordTraceInfo { - public ScriptTelemetryRecordEngineInfo engine { get; set; } - public string message { get; set; } - } - - public class ScriptTelemetryRecord: TelemetryRecord { - // by who? - public string username { get; set; } - // on what? - public string revit { get; set; } - public string revitbuild { get; set; } - public string sessionid { get; set; } - public string pyrevit { get; set; } - public string clone { get; set; } - // on which document - public string docname { get; set; } - public string docpath { get; set; } - // which mode? - public bool debug { get; set; } - public bool config { get; set; } - public bool from_gui { get; set; } - public string exec_id { get; set; } - public string exec_timestamp { get; set; } - // which script? - public string commandname { get; set; } - public string commandbundle { get; set; } - public string commandextension { get; set; } - public string commanduniquename { get; set; } - public string scriptpath { get; set; } - public string arguments { get; set; } - // returned what? - public int resultcode { get; set; } - public Dictionary commandresults { get; set; } - // any errors? - public ScriptTelemetryRecordTraceInfo trace { get; set; } - - public ScriptTelemetryRecord(): base() {} - } - - public static class ScriptTelemetry { - private static ScriptTelemetryRecord MakeTelemetryRecord(ref ScriptRuntime runtime) { - // setup a new telemetry record - return new ScriptTelemetryRecord { - username = Telemetry.GetRevitUser(runtime.App), - revit = Telemetry.GetRevitVersion(runtime.App), - revitbuild = Telemetry.GetRevitBuild(runtime.App), - sessionid = runtime.SessionUUID, - pyrevit = runtime.PyRevitVersion, - clone = runtime.CloneName, - debug = runtime.ScriptRuntimeConfigs.DebugMode, - config = runtime.ScriptRuntimeConfigs.ConfigMode, - from_gui = runtime.ScriptRuntimeConfigs.ExecutedFromUI, - exec_id = runtime.ExecId, - exec_timestamp = runtime.ExecTimestamp, - commandname = runtime.ScriptData.CommandName, - commandbundle = runtime.ScriptData.CommandBundle, - commandextension = runtime.ScriptData.CommandExtension, - commanduniquename = runtime.ScriptData.CommandUniqueId, - scriptpath = runtime.ScriptSourceFile, - docname = runtime.DocumentName, - docpath = runtime.DocumentPath, - resultcode = runtime.ExecutionResult, - commandresults = runtime.GetResultsDictionary(), - trace = new ScriptTelemetryRecordTraceInfo { - engine = new ScriptTelemetryRecordEngineInfo { - type = runtime.EngineType.ToString().ToLower(), - version = runtime.EngineVersion, - syspath = runtime.ScriptRuntimeConfigs.SearchPaths, - configs = JsonConvert.DeserializeObject>(runtime.ScriptRuntimeConfigs.EngineConfigs), - }, - message = runtime.TraceMessage - } - }; - } - - public static void LogScriptTelemetryRecord(ref ScriptRuntime runtime) { - var env = new EnvDictionary(); - - var record = MakeTelemetryRecord(ref runtime); - - if (env.TelemetryServerUrl != null && !string.IsNullOrEmpty(env.TelemetryServerUrl)) - new Task(() => - Telemetry.PostTelemetryRecord(env.TelemetryServerUrl, record)).Start(); - - if (env.TelemetryFilePath != null && !string.IsNullOrEmpty(env.TelemetryFilePath)) - new Task(() => - Telemetry.WriteTelemetryRecord(env.TelemetryFilePath, record)).Start(); - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/UpdaterListener.cs b/dev/pyRevitLabs.PyRevit.Runtime/UpdaterListener.cs deleted file mode 100644 index ed7c892d8..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/UpdaterListener.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System; - -using Autodesk.Revit.DB; - -using pyRevitLabs.Common; -using pyRevitLabs.PyRevit; - -namespace PyRevitLabs.PyRevit.Runtime { - public class UpdaterListener : IUpdater { - public delegate void UpdaterExecuted(object source, UpdaterData data); - - public event UpdaterExecuted OnUpdaterExecute; - - static AddInId _appId; - static UpdaterId _updaterId; - - public UpdaterListener() { - _appId = new AddInId(new Guid(PyRevitConsts.AddinId)); - _updaterId = new UpdaterId(_appId, new Guid("c2fa20c6-0729-46c5-95f9-f79abfab566e")); - } - - public void Execute(UpdaterData data) { - OnUpdaterExecute?.Invoke(this, data); - } - - public UpdaterId GetUpdaterId() => _updaterId; - public string GetUpdaterName() => PyRevitLabsConsts.ProductName + "Updater"; - public string GetAdditionalInformation() => "Updater interface to execute updater hooks"; - public ChangePriority GetChangePriority() => 0; - } -} \ No newline at end of file diff --git a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.sln b/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.sln index 0a97e2ef5..f720c921c 100644 --- a/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.sln +++ b/dev/pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.sln @@ -3,162 +3,66 @@ Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio Version 17 VisualStudioVersion = 17.1.32421.90 MinimumVisualStudioVersion = 10.0.40219.1 -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2021", "pyRevitLabs.PyRevit.Runtime.2021.csproj", "{479435EA-C820-49E4-942F-1274C151EE71}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2017", "2017/pyRevitLabs.PyRevit.Runtime.2017.csproj", "{1B786F43-6125-42FF-8EA2-C4AEF640AEE4}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2017", "pyRevitLabs.PyRevit.Runtime.2017.csproj", "{1B786F43-6125-42FF-8EA2-C4AEF640AEE4}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2018", "2018/pyRevitLabs.PyRevit.Runtime.2018.csproj", "{8CEA0B80-D74F-411F-A607-DC1599AA934E}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2018", "pyRevitLabs.PyRevit.Runtime.2018.csproj", "{8CEA0B80-D74F-411F-A607-DC1599AA934E}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2019", "2019/pyRevitLabs.PyRevit.Runtime.2019.csproj", "{EFBE5B7E-227A-4122-98D7-D1F353AAF157}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2019", "pyRevitLabs.PyRevit.Runtime.2019.csproj", "{EFBE5B7E-227A-4122-98D7-D1F353AAF157}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2020", "2020/pyRevitLabs.PyRevit.Runtime.2020.csproj", "{F5A23012-880A-4FE6-89EC-6F9DAB148DEF}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2020", "pyRevitLabs.PyRevit.Runtime.2020.csproj", "{F5A23012-880A-4FE6-89EC-6F9DAB148DEF}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2021", "2021/pyRevitLabs.PyRevit.Runtime.2021.csproj", "{479435EA-C820-49E4-942F-1274C151EE71}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2022", "pyRevitLabs.PyRevit.Runtime.2022.csproj", "{DB535262-30DA-404D-A32E-F024FF37935C}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2022", "2022/pyRevitLabs.PyRevit.Runtime.2022.csproj", "{DB535262-30DA-404D-A32E-F024FF37935C}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2023", "pyRevitLabs.PyRevit.Runtime.2023.csproj", "{E05891D9-4833-45B5-84B4-8237D9AF6A4C}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2023", "2023/pyRevitLabs.PyRevit.Runtime.2023.csproj", "{E05891D9-4833-45B5-84B4-8237D9AF6A4C}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2024", "pyRevitLabs.PyRevit.Runtime.2024.csproj", "{E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime.2024", "2024/pyRevitLabs.PyRevit.Runtime.2024.csproj", "{E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "pyRevitLabs.PyRevit.Runtime.2025", "2025/pyRevitLabs.PyRevit.Runtime.2025.csproj", "{E1FC3F88-7E97-49EF-8D03-7F449B6AFB40}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU Debug|x64 = Debug|x64 - Release|Any CPU = Release|Any CPU Release|x64 = Release|x64 - ReleasePY37|Any CPU = ReleasePY37|Any CPU - ReleasePY37|x64 = ReleasePY37|x64 - ReleasePY38|Any CPU = ReleasePY38|Any CPU - ReleasePY38|x64 = ReleasePY38|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {479435EA-C820-49E4-942F-1274C151EE71}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {479435EA-C820-49E4-942F-1274C151EE71}.Debug|Any CPU.Build.0 = Debug|Any CPU - {479435EA-C820-49E4-942F-1274C151EE71}.Debug|x64.ActiveCfg = Debug|Any CPU - {479435EA-C820-49E4-942F-1274C151EE71}.Debug|x64.Build.0 = Debug|Any CPU - {479435EA-C820-49E4-942F-1274C151EE71}.Release|Any CPU.ActiveCfg = Release|Any CPU - {479435EA-C820-49E4-942F-1274C151EE71}.Release|Any CPU.Build.0 = Release|Any CPU + {479435EA-C820-49E4-942F-1274C151EE71}.Debug|x64.ActiveCfg = Debug|x64 + {479435EA-C820-49E4-942F-1274C151EE71}.Debug|x64.Build.0 = Debug|x64 {479435EA-C820-49E4-942F-1274C151EE71}.Release|x64.ActiveCfg = Release|x64 {479435EA-C820-49E4-942F-1274C151EE71}.Release|x64.Build.0 = Release|x64 - {479435EA-C820-49E4-942F-1274C151EE71}.ReleasePY37|Any CPU.ActiveCfg = Release|x64 - {479435EA-C820-49E4-942F-1274C151EE71}.ReleasePY37|Any CPU.Build.0 = Release|x64 - {479435EA-C820-49E4-942F-1274C151EE71}.ReleasePY37|x64.ActiveCfg = Release|x64 - {479435EA-C820-49E4-942F-1274C151EE71}.ReleasePY37|x64.Build.0 = Release|x64 - {479435EA-C820-49E4-942F-1274C151EE71}.ReleasePY38|Any CPU.ActiveCfg = Release|x64 - {479435EA-C820-49E4-942F-1274C151EE71}.ReleasePY38|Any CPU.Build.0 = Release|x64 - {479435EA-C820-49E4-942F-1274C151EE71}.ReleasePY38|x64.ActiveCfg = Release|x64 - {479435EA-C820-49E4-942F-1274C151EE71}.ReleasePY38|x64.Build.0 = Release|x64 - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.Debug|Any CPU.Build.0 = Debug|Any CPU - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.Debug|x64.ActiveCfg = Debug|Any CPU - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.Debug|x64.Build.0 = Debug|Any CPU - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.Release|Any CPU.ActiveCfg = Release|Any CPU - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.Release|Any CPU.Build.0 = Release|Any CPU + {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.Debug|x64.ActiveCfg = Debug|x64 + {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.Debug|x64.Build.0 = Debug|x64 {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.Release|x64.ActiveCfg = Release|x64 {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.Release|x64.Build.0 = Release|x64 - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.ReleasePY37|Any CPU.ActiveCfg = Release|x64 - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.ReleasePY37|Any CPU.Build.0 = Release|x64 - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.ReleasePY37|x64.ActiveCfg = Release|x64 - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.ReleasePY37|x64.Build.0 = Release|x64 - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.ReleasePY38|Any CPU.ActiveCfg = Release|x64 - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.ReleasePY38|Any CPU.Build.0 = Release|x64 - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.ReleasePY38|x64.ActiveCfg = Release|x64 - {1B786F43-6125-42FF-8EA2-C4AEF640AEE4}.ReleasePY38|x64.Build.0 = Release|x64 - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.Debug|Any CPU.Build.0 = Debug|Any CPU - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.Debug|x64.ActiveCfg = Debug|Any CPU - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.Debug|x64.Build.0 = Debug|Any CPU - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.Release|Any CPU.ActiveCfg = Release|Any CPU - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.Release|Any CPU.Build.0 = Release|Any CPU + {8CEA0B80-D74F-411F-A607-DC1599AA934E}.Debug|x64.ActiveCfg = Debug|x64 + {8CEA0B80-D74F-411F-A607-DC1599AA934E}.Debug|x64.Build.0 = Debug|x64 {8CEA0B80-D74F-411F-A607-DC1599AA934E}.Release|x64.ActiveCfg = Release|x64 {8CEA0B80-D74F-411F-A607-DC1599AA934E}.Release|x64.Build.0 = Release|x64 - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.ReleasePY37|Any CPU.ActiveCfg = Release|x64 - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.ReleasePY37|Any CPU.Build.0 = Release|x64 - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.ReleasePY37|x64.ActiveCfg = Release|x64 - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.ReleasePY37|x64.Build.0 = Release|x64 - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.ReleasePY38|Any CPU.ActiveCfg = Release|x64 - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.ReleasePY38|Any CPU.Build.0 = Release|x64 - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.ReleasePY38|x64.ActiveCfg = Release|x64 - {8CEA0B80-D74F-411F-A607-DC1599AA934E}.ReleasePY38|x64.Build.0 = Release|x64 - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.Debug|Any CPU.Build.0 = Debug|Any CPU - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.Debug|x64.ActiveCfg = Debug|Any CPU - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.Debug|x64.Build.0 = Debug|Any CPU - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.Release|Any CPU.ActiveCfg = Release|Any CPU - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.Release|Any CPU.Build.0 = Release|Any CPU + {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.Debug|x64.ActiveCfg = Debug|x64 + {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.Debug|x64.Build.0 = Debug|x64 {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.Release|x64.ActiveCfg = Release|x64 {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.Release|x64.Build.0 = Release|x64 - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.ReleasePY37|Any CPU.ActiveCfg = Release|x64 - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.ReleasePY37|Any CPU.Build.0 = Release|x64 - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.ReleasePY37|x64.ActiveCfg = Release|x64 - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.ReleasePY37|x64.Build.0 = Release|x64 - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.ReleasePY38|Any CPU.ActiveCfg = Release|x64 - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.ReleasePY38|Any CPU.Build.0 = Release|x64 - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.ReleasePY38|x64.ActiveCfg = Release|x64 - {EFBE5B7E-227A-4122-98D7-D1F353AAF157}.ReleasePY38|x64.Build.0 = Release|x64 - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.Debug|Any CPU.Build.0 = Debug|Any CPU - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.Debug|x64.ActiveCfg = Debug|Any CPU - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.Debug|x64.Build.0 = Debug|Any CPU - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.Release|Any CPU.ActiveCfg = Release|Any CPU - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.Release|Any CPU.Build.0 = Release|Any CPU + {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.Debug|x64.ActiveCfg = Debug|x64 + {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.Debug|x64.Build.0 = Debug|x64 {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.Release|x64.ActiveCfg = Release|x64 {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.Release|x64.Build.0 = Release|x64 - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.ReleasePY37|Any CPU.ActiveCfg = Release|x64 - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.ReleasePY37|Any CPU.Build.0 = Release|x64 - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.ReleasePY37|x64.ActiveCfg = Release|x64 - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.ReleasePY37|x64.Build.0 = Release|x64 - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.ReleasePY38|Any CPU.ActiveCfg = Release|x64 - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.ReleasePY38|Any CPU.Build.0 = Release|x64 - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.ReleasePY38|x64.ActiveCfg = Release|x64 - {F5A23012-880A-4FE6-89EC-6F9DAB148DEF}.ReleasePY38|x64.Build.0 = Release|x64 - {DB535262-30DA-404D-A32E-F024FF37935C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.Debug|Any CPU.Build.0 = Debug|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.Debug|x64.ActiveCfg = Debug|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.Debug|x64.Build.0 = Debug|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.Release|Any CPU.ActiveCfg = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.Release|Any CPU.Build.0 = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.Release|x64.ActiveCfg = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.Release|x64.Build.0 = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.ReleasePY37|Any CPU.ActiveCfg = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.ReleasePY37|Any CPU.Build.0 = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.ReleasePY37|x64.ActiveCfg = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.ReleasePY37|x64.Build.0 = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.ReleasePY38|Any CPU.ActiveCfg = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.ReleasePY38|Any CPU.Build.0 = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.ReleasePY38|x64.ActiveCfg = Release|Any CPU - {DB535262-30DA-404D-A32E-F024FF37935C}.ReleasePY38|x64.Build.0 = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Debug|Any CPU.Build.0 = Debug|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Debug|x64.ActiveCfg = Debug|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Debug|x64.Build.0 = Debug|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Release|Any CPU.ActiveCfg = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Release|Any CPU.Build.0 = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Release|x64.ActiveCfg = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Release|x64.Build.0 = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.ReleasePY37|Any CPU.ActiveCfg = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.ReleasePY37|Any CPU.Build.0 = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.ReleasePY37|x64.ActiveCfg = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.ReleasePY37|x64.Build.0 = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.ReleasePY38|Any CPU.ActiveCfg = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.ReleasePY38|Any CPU.Build.0 = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.ReleasePY38|x64.ActiveCfg = Release|Any CPU - {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.ReleasePY38|x64.Build.0 = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Debug|Any CPU.Build.0 = Debug|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Debug|x64.ActiveCfg = Debug|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Debug|x64.Build.0 = Debug|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Release|Any CPU.ActiveCfg = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Release|Any CPU.Build.0 = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Release|x64.ActiveCfg = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Release|x64.Build.0 = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.ReleasePY37|Any CPU.ActiveCfg = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.ReleasePY37|Any CPU.Build.0 = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.ReleasePY37|x64.ActiveCfg = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.ReleasePY37|x64.Build.0 = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.ReleasePY38|Any CPU.ActiveCfg = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.ReleasePY38|Any CPU.Build.0 = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.ReleasePY38|x64.ActiveCfg = Release|Any CPU - {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.ReleasePY38|x64.Build.0 = Release|Any CPU + {DB535262-30DA-404D-A32E-F024FF37935C}.Debug|x64.ActiveCfg = Debug|x64 + {DB535262-30DA-404D-A32E-F024FF37935C}.Debug|x64.Build.0 = Debug|x64 + {DB535262-30DA-404D-A32E-F024FF37935C}.Release|x64.ActiveCfg = Release|x64 + {DB535262-30DA-404D-A32E-F024FF37935C}.Release|x64.Build.0 = Release|x64 + {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Debug|x64.ActiveCfg = Debug|x64 + {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Debug|x64.Build.0 = Debug|x64 + {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Release|x64.ActiveCfg = Release|x64 + {E05891D9-4833-45B5-84B4-8237D9AF6A4C}.Release|x64.Build.0 = Release|x64 + {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Debug|x64.ActiveCfg = Debug|x64 + {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Debug|x64.Build.0 = Debug|x64 + {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Release|x64.ActiveCfg = Release|x64 + {E4C1B0B3-DE42-4D10-A4FB-8A478ED9DDFC}.Release|x64.Build.0 = Release|x64 + {E1FC3F88-7E97-49EF-8D03-7F449B6AFB40}.Debug|x64.ActiveCfg = Debug|x64 + {E1FC3F88-7E97-49EF-8D03-7F449B6AFB40}.Debug|x64.Build.0 = Debug|x64 + {E1FC3F88-7E97-49EF-8D03-7F449B6AFB40}.Release|x64.ActiveCfg = Release|x64 + {E1FC3F88-7E97-49EF-8D03-7F449B6AFB40}.Release|x64.Build.0 = Release|x64 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/dev/pyRevitLabs.PyRevit.Runtime/scriptruntime.cs b/dev/pyRevitLabs.PyRevit.Runtime/scriptruntime.cs deleted file mode 100644 index 75780d853..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/scriptruntime.cs +++ /dev/null @@ -1,379 +0,0 @@ -using System; -using System.Collections.Generic; -using System.IO; - -using Autodesk.Revit.UI; -using Autodesk.Revit.DB; -using Autodesk.Revit.ApplicationServices; - -using pyRevitLabs.Common; -using pyRevitLabs.PyRevit; - -namespace PyRevitLabs.PyRevit.Runtime { - public enum ScriptRuntimeType { - ExternalCommand, - EventHandler, - } - - public class ScriptRuntimeConfigs : IDisposable { - private object _eventSender = null; - - public ControlledApplication ControlledApp { get; set; } - public Application App { get; set; } - public UIControlledApplication UIControlledApp { get; set; } - public UIApplication UIApp { get; set; } - - public ExternalCommandData CommandData { get; set; } - public ElementSet SelectedElements { get; set; } - - public List SearchPaths { get; set; } - public List Arguments { get; set; } - - public object EventSender { - get { return _eventSender; } - set { - if (value != null) { - // detemine sender type - if (value.GetType() == typeof(UIControlledApplication)) - _eventSender = (UIControlledApplication)value; - else if (value.GetType() == typeof(UIApplication)) - _eventSender = (UIApplication)value; - else if (value.GetType() == typeof(ControlledApplication)) - _eventSender = (ControlledApplication)value; - else if (value.GetType() == typeof(Application)) - _eventSender = (Application)value; - } - } - } - public object EventArgs { get; set; } - - public string EngineConfigs; - - public bool RefreshEngine; - public bool ConfigMode; - public bool DebugMode; - public bool ExecutedFromUI; - - public void Dispose() { - CommandData = null; - SelectedElements = null; - SearchPaths = null; - Arguments = null; - EventSender = null; - EventArgs = null; - } - } - - public class ScriptRuntime : IDisposable { - // app handles - private UIApplication _uiApp = null; - private Application _app = null; - - // output window and stream - private WeakReference _scriptOutput = new WeakReference(null); - private WeakReference _outputStream = new WeakReference(null); - - // dict for command result data - private Dictionary _resultsDict = null; - - public ScriptRuntime(ScriptData scriptData, ScriptRuntimeConfigs scriptRuntimeCfg) { - // setup a new id and timestamp - ExecId = CommonUtils.NewShortUUID(); - ExecTimestamp = Telemetry.GetTelemetryTimeStamp(); - - // set data - ScriptData = scriptData; - ScriptRuntimeConfigs = scriptRuntimeCfg; - - //env - // get the state of variables before command execution; the command could potentially change the values - EnvDict = new EnvDictionary(); - - // apply application override hooks if given - if (ScriptRuntimeConfigs.ControlledApp != null) - ControlledApp = ScriptRuntimeConfigs.ControlledApp; - if (ScriptRuntimeConfigs.App != null) - App = ScriptRuntimeConfigs.App; - if (ScriptRuntimeConfigs.UIControlledApp != null) - UIControlledApp = ScriptRuntimeConfigs.UIControlledApp; - if (ScriptRuntimeConfigs.UIApp != null) - UIApp = ScriptRuntimeConfigs.UIApp; - - // determine event sender type - if (ScriptRuntimeConfigs.EventSender != null) { - // detemine sender type - if (ScriptRuntimeConfigs.EventSender.GetType() == typeof(UIControlledApplication)) - UIControlledApp = (UIControlledApplication)ScriptRuntimeConfigs.EventSender; - else if (ScriptRuntimeConfigs.EventSender.GetType() == typeof(UIApplication)) - UIApp = (UIApplication)ScriptRuntimeConfigs.EventSender; - else if (ScriptRuntimeConfigs.EventSender.GetType() == typeof(ControlledApplication)) - ControlledApp = (ControlledApplication)ScriptRuntimeConfigs.EventSender; - else if (ScriptRuntimeConfigs.EventSender.GetType() == typeof(Application)) - App = (Application)ScriptRuntimeConfigs.EventSender; - } - - // prepare results - ExecutionResult = ScriptExecutorResultCodes.Succeeded; - TraceMessage = string.Empty; - } - - public ScriptData ScriptData { get; private set; } - public ScriptRuntimeConfigs ScriptRuntimeConfigs { get; private set; } - - // target script - public string ScriptSourceFile { - get { - if (ScriptRuntimeConfigs.ConfigMode && (ScriptData.ConfigScriptPath != null || ScriptData.ConfigScriptPath != string.Empty)) - return ScriptData.ConfigScriptPath; - else - return ScriptData.ScriptPath; - } - } - - public string ScriptSourceFileSignature { - get { - return CommonUtils.GetFileSignature(ScriptSourceFile); - } - } - - public ScriptRuntimeType RuntimeType { - get { - if (ScriptRuntimeConfigs.EventSender != null || ScriptRuntimeConfigs.EventArgs != null) - return ScriptRuntimeType.EventHandler; - - return ScriptRuntimeType.ExternalCommand; - } - } - - public ScriptEngineType EngineType { - get { - // determine engine necessary to run this script - - if (PyRevitScript.IsType(ScriptSourceFile, PyRevitScriptTypes.Python)) { - string firstLine = ""; - if (File.Exists(ScriptSourceFile)) { - using (StreamReader reader = new StreamReader(ScriptSourceFile)) { - firstLine = reader.ReadLine(); - - if (firstLine != null && (firstLine.Contains("python3") || firstLine.Contains("cpython"))) - return ScriptEngineType.CPython; - else - return ScriptEngineType.IronPython; - } - } - } - - else if (PyRevitScript.IsType(ScriptSourceFile, PyRevitScriptTypes.CSharp)) { - return ScriptEngineType.CSharp; - } - - else if (PyRevitScript.IsType(ScriptSourceFile, PyRevitScriptTypes.VisualBasic)) { - return ScriptEngineType.VisualBasic; - } - - else if (PyRevitScript.IsType(ScriptSourceFile, PyRevitScriptTypes.Ruby)) { - return ScriptEngineType.IronRuby; - } - - else if (PyRevitScript.IsType(ScriptSourceFile, PyRevitScriptTypes.Dynamo)) { - return ScriptEngineType.DynamoBIM; - } - - else if (PyRevitScript.IsType(ScriptSourceFile, PyRevitScriptTypes.Grasshopper)) { - return ScriptEngineType.Grasshopper; - } - - else if (PyRevitScript.IsType(ScriptSourceFile, PyRevitScriptTypes.RevitFamily)) { - return ScriptEngineType.Content; - } - - if (ScriptData.CommandBundle != null) { - if (PyRevitBundle.IsType(ScriptData.CommandBundle, PyRevitBundleTypes.InvokeButton)) { - return ScriptEngineType.Invoke; - } - else if (PyRevitBundle.IsType(ScriptData.CommandBundle, PyRevitBundleTypes.URLButton)) { - return ScriptEngineType.HyperLink; - } - } - - // if the script is deleted during runtime - // ScriptSourceFile with be "" and runtime can not determine - // the engine type - return ScriptEngineType.Unknown; - } - } - - public string EngineVersion { - get { - switch (EngineType) { - case ScriptEngineType.IronPython: return EnvDict.PyRevitIPYVersion; - case ScriptEngineType.CPython: return EnvDict.PyRevitCPYVersion; - case ScriptEngineType.CSharp: return EnvDict.PyRevitVersion; - case ScriptEngineType.Invoke: return EnvDict.PyRevitVersion; - case ScriptEngineType.VisualBasic: return EnvDict.PyRevitVersion; - case ScriptEngineType.IronRuby: return EnvDict.PyRevitVersion; - case ScriptEngineType.DynamoBIM: return EnvDict.PyRevitVersion; - case ScriptEngineType.Grasshopper: return EnvDict.PyRevitVersion; - case ScriptEngineType.Content: return EnvDict.PyRevitVersion; - default: return EnvDict.PyRevitVersion; - } - } - } - - public Autodesk.Windows.RibbonItem UIControl { - get { - return ((UIFramework.RevitRibbonControl)Autodesk.Windows.ComponentManager.Ribbon).findRibbonItem(ScriptData.CommandControlId, false); - } - } - - // environment - // pyrevit - public EnvDictionary EnvDict { get; set; } - - public string PyRevitVersion { - get { - return EnvDict.PyRevitVersion; - } - } - - public string CloneName { - get { - return EnvDict.PyRevitClone; - } - } - - public string SessionUUID { - get { - return EnvDict.SessionUUID; - } - } - - // revit - public string DocumentName { - get { - if (UIApp != null && UIApp.ActiveUIDocument != null) - return UIApp.ActiveUIDocument.Document.Title; - else - return string.Empty; - } - } - - public string DocumentPath { - get { - if (UIApp != null && UIApp.ActiveUIDocument != null) - return UIApp.ActiveUIDocument.Document.PathName; - else - return string.Empty; - } - } - - public ControlledApplication ControlledApp { get; set; } - - public Application App { - get { - if (ScriptRuntimeConfigs.CommandData != null) - return ScriptRuntimeConfigs.CommandData.Application.Application; - else if (UIApp != null) - return UIApp.Application; - else if (_app != null) - return _app; - return null; - } - - set { - _app = value; - } - } - - public UIControlledApplication UIControlledApp { get; set; } - - public UIApplication UIApp { - get { - if (ScriptRuntimeConfigs.CommandData != null) - return ScriptRuntimeConfigs.CommandData.Application; - else if (_uiApp != null) - return _uiApp; - return null; - } - - set { - _uiApp = value; - } - } - - // output - public ScriptConsole OutputWindow { - get { - // get ScriptOutput from the weak reference - ScriptConsole output; - var re = _scriptOutput.TryGetTarget(out output); - if (re && output != null) - return output; - else { - // Stating a new output window - var newOutput = new ScriptConsole(ScriptRuntimeConfigs.DebugMode, UIApp); - - // Set output window title to command name - newOutput.OutputTitle = ScriptData.CommandName; - - // Set window identity to the command unique identifier - newOutput.OutputId = ScriptData.CommandUniqueId; - - // set window app version header - newOutput.AppVersion = string.Format( - "{0}:{1}:{2}", - EnvDict.PyRevitVersion, - EngineType == ScriptEngineType.CPython ? EnvDict.PyRevitCPYVersion : EnvDict.PyRevitIPYVersion, - EnvDict.RevitVersion - ); - - _scriptOutput = new WeakReference(newOutput); - return newOutput; - } - } - } - - public ScriptIO OutputStream { - get { - // get ScriptOutputStream from the weak reference - ScriptIO outputStream; - var re = _outputStream.TryGetTarget(out outputStream); - if (re && outputStream != null) - return outputStream; - else { - // Setup the output stream - ScriptIO newStream = new ScriptIO(this); - _outputStream = new WeakReference(newStream); - return newStream; - } - } - } - - // execution - public string ExecId { get; private set; } - - public string ExecTimestamp { get; private set; } - - public int ExecutionResult { get; set; } - - public string TraceMessage { get; set; } - - public Dictionary GetResultsDictionary() { - if (_resultsDict == null) - _resultsDict = new Dictionary(); - - return _resultsDict; - } - - // disposal - public void Dispose() { - UIControlledApp = null; - ControlledApp = null; - _uiApp = null; - _app = null; - _scriptOutput = new WeakReference(null); - _outputStream = new WeakReference(null);; - _resultsDict = null; - } - } -} diff --git a/dev/pyRevitLabs.PyRevit.Runtime/telemetry.cs b/dev/pyRevitLabs.PyRevit.Runtime/telemetry.cs deleted file mode 100644 index fdb8b16cf..000000000 --- a/dev/pyRevitLabs.PyRevit.Runtime/telemetry.cs +++ /dev/null @@ -1,169 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Net; -using System.IO; -using System.Diagnostics; - -using Autodesk.Revit.UI; -using Autodesk.Revit.ApplicationServices; - -using pyRevitLabs.Json; -using pyRevitLabs.Common; -using pyRevitLabs.TargetApps.Revit; - -namespace PyRevitLabs.PyRevit.Runtime { - public class TelemetryRecord { - // schema - public Dictionary meta { get; private set; } - - // when? - public string timestamp { get; private set; } - // by who? - public string host_user { get; private set; } - - - public TelemetryRecord() { - meta = new Dictionary { - { "schema", "2.0"}, - }; - - timestamp = Telemetry.GetTelemetryTimeStamp(); - host_user = UserEnv.GetLoggedInUserName() ?? UserEnv.GetExecutingUserName(); - } - } - - public static class Telemetry { - private static string _exeBuild = null; - - public static string DefaultUser { get; set; } = string.Empty; - - public static string SerializeTelemetryRecord(object telemetryRecord) { - return JsonConvert.SerializeObject(telemetryRecord); - } - - public static string PostTelemetryRecord(string telemetryServerUrl, object telemetryRecord) { - var httpWebRequest = (HttpWebRequest)WebRequest.Create(telemetryServerUrl); - httpWebRequest.ContentType = "application/json"; - httpWebRequest.Method = "POST"; - httpWebRequest.UserAgent = PyRevitLabsConsts.ProductName; - - using (var streamWriter = new StreamWriter(httpWebRequest.GetRequestStream())) { - // serialize and write - string json = SerializeTelemetryRecord(telemetryRecord); - streamWriter.Write(json); - streamWriter.Flush(); - streamWriter.Close(); - } - - var httpResponse = (HttpWebResponse)httpWebRequest.GetResponse(); - using (var streamReader = new StreamReader(httpResponse.GetResponseStream())) { - return streamReader.ReadToEnd(); - } - } - - public static void WriteTelemetryRecord(string telemetryFilePath, T telemetryRecord) { - string existingTelemetryData = "[]"; - if (File.Exists(telemetryFilePath)) { - existingTelemetryData = File.ReadAllText(telemetryFilePath); - } - else { - File.WriteAllText(telemetryFilePath, existingTelemetryData); - } - - var telemetryData = JsonConvert.DeserializeObject>(existingTelemetryData); - - telemetryData.Add(telemetryRecord); - - existingTelemetryData = JsonConvert.SerializeObject(telemetryData); - File.WriteAllText(telemetryFilePath, existingTelemetryData); - } - - public static string GetTelemetryTimeStamp() { - var env = new EnvDictionary(); - if (env.TelemetryUTCTimeStamps) - return GetISOTimeStamp(DateTime.Now.ToUniversalTime()); // 2019-09-27T23:22:41.1355Z - else - return GetISOTimeStamp(DateTime.Now); // 2019-09-27T16:15:56.9528-07:00 - } - - private static string GetISOTimeStamp(DateTime dtimeValue) { - // higher resolution timestamp for telemetry - - return dtimeValue.ToString("yyyy-MM-ddTHH:mm:ss.ffffK"); - } - - public static string GetRevitUser(object source) { - switch (source) { - case UIApplication uiapp: - return uiapp.Application.Username; - - case Application app: - return app.Username; - } - - return DefaultUser; - } - - public static string GetRevitVersion(object source) { - string revit = string.Empty; - - switch (source) { - case UIControlledApplication uictrlapp: - revit = uictrlapp.ControlledApplication.VersionNumber; - break; - case UIApplication uiapp: - revit = uiapp.Application.VersionNumber; - break; - - case ControlledApplication ctrlapp: - revit = ctrlapp.VersionNumber; - break; - - case Application app: - revit = app.VersionNumber; - break; - } - - return revit; - } - - public static string GetRevitBuild(object source) { - // determine build number - string revitbuild = string.Empty; - -#if (REVIT2013 || REVIT2014 || REVIT2015 || REVIT2016 || REVIT2017 || REVIT2018 || REVIT2019 || REVIT2020) - switch (source) { - case UIControlledApplication uictrlapp: - revitbuild = uictrlapp.ControlledApplication.VersionBuild; - break; - case UIApplication uiapp: - revitbuild = uiapp.Application.VersionBuild; - break; - case ControlledApplication ctrlapp: - revitbuild = ctrlapp.VersionBuild; - break; - case Application app: - revitbuild = app.VersionBuild; - break; - } -#else - // Revit 2021 has a bug on .VersionBuild - // it reports identical value as .VersionNumber - // let's give a invalid, but correctly formatted value to the telemetry server - if (_exeBuild is null) { - string revitExePath = Process.GetCurrentProcess().MainModule.FileName; - if (revitExePath != null && revitExePath != string.Empty) { - HostProductInfo pinfo = RevitProductData.GetBinaryProductInfo(revitExePath); - if (pinfo.build != null && pinfo.build != string.Empty) { - revitbuild = string.Format("{0}({1})", pinfo.build, pinfo.target); - _exeBuild = revitbuild; - } - } - } - else - revitbuild = _exeBuild; -#endif - return revitbuild; - } - } -} diff --git a/dev/pyRevitLabs/Directory.Build.targets b/dev/pyRevitLabs/Directory.Build.targets index 22c3144a4..6c9b1da63 100644 --- a/dev/pyRevitLabs/Directory.Build.targets +++ b/dev/pyRevitLabs/Directory.Build.targets @@ -1,6 +1,6 @@ - + diff --git a/dev/pyRevitLabs/pyRevitCLI/PyRevitCLI.cs b/dev/pyRevitLabs/pyRevitCLI/PyRevitCLI.cs index 910744dc6..0ece364cc 100644 --- a/dev/pyRevitLabs/pyRevitCLI/PyRevitCLI.cs +++ b/dev/pyRevitLabs/pyRevitCLI/PyRevitCLI.cs @@ -1,20 +1,15 @@ using System; -using System.IO; using System.Collections.Generic; +using System.IO; using System.Linq; using System.Reflection; - using DocoptNet; - +using pyRevitCLI.Properties; using pyRevitLabs.Common; using pyRevitLabs.NLog; using pyRevitLabs.NLog.Config; using pyRevitLabs.NLog.Targets; - using pyRevitLabs.PyRevit; -using pyRevitLabs.TargetApps.Revit; -using pyRevitCLI.Properties; - using Console = Colorful.Console; @@ -28,7 +23,8 @@ // 6) Make sure PyRevitCLI.ProcessArguments checks and ask for help print -namespace pyRevitCLI { +namespace pyRevitCLI +{ internal enum PyRevitCLILogLevel { Quiet, @@ -152,12 +148,10 @@ static void Main(string[] args) { try { // now call methods based on inputs ProcessArguments(); - - // process global error codes - ProcessErrorCodes(); } catch (Exception ex) { LogException(ex, logLevel); + Environment.ExitCode = -1; } // Flush and close down internal threads and timers @@ -166,7 +160,7 @@ static void Main(string[] args) { catch (Exception ex) { // when docopt fails, print help logger.Debug("Arg processing failed. | {0}", ex.Message); - PyRevitCLIAppHelps.PrintHelp(PyRevitCLICommandType.Main); + PyRevitCLIAppHelps.PrintHelp(PyRevitCLICommandType.Main, -1); } } @@ -957,9 +951,6 @@ private static void PrintArguments(IDictionary arguments) { Console.WriteLine("{0} = {1}", arg.Key, arg.Value.ToString()); } - private static void ProcessErrorCodes() { - } - private static void LogException(Exception ex, PyRevitCLILogLevel logLevel) { if (logLevel == PyRevitCLILogLevel.Debug) logger.Error(string.Format("{0} ({1})\n{2}", ex.Message, ex.GetType().ToString(), ex.StackTrace)); diff --git a/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIAppCmds.cs b/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIAppCmds.cs index c7db419bb..8e90c58f6 100644 --- a/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIAppCmds.cs +++ b/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIAppCmds.cs @@ -175,7 +175,7 @@ internal static void Console.WriteLine(string.Format("Installed .Net-Core Target Packs: {0}", targetPacks)); } catch { - Console.WriteLine("No .Ne-Core Target Packs are installed."); + Console.WriteLine("No .Net-Core Target Packs are installed."); } Console.WriteLine(string.Format("pyRevit CLI v{0}", PyRevitCLI.CLIInfoVersion)); diff --git a/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIAppHelps.cs b/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIAppHelps.cs index 3d82725d5..acb679e3b 100644 --- a/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIAppHelps.cs +++ b/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIAppHelps.cs @@ -1,15 +1,15 @@ using System; using System.Collections.Generic; - -using pyRevitLabs.Common; using pyRevitLabs.Common.Extensions; -using pyRevitLabs.TargetApps.Revit; -using pyRevitLabs.PyRevit; -namespace pyRevitCLI { +namespace pyRevitCLI +{ internal static class PyRevitCLIAppHelps { - internal static void - PrintHelp(PyRevitCLICommandType commandType) { + internal static void PrintHelp(PyRevitCLICommandType commandType) + { + PrintHelp(commandType, 0); + } + internal static void PrintHelp(PyRevitCLICommandType commandType, int exitCode) { switch (commandType) { case PyRevitCLICommandType.Main: @@ -366,7 +366,7 @@ internal static void } // now exit - Environment.Exit(0); + Environment.Exit(exitCode); } private static void BuildHelp(IEnumerable docoptKeywords, diff --git a/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIReleaseCmds.cs b/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIReleaseCmds.cs index 62cce25c9..962dc14e7 100644 --- a/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIReleaseCmds.cs +++ b/dev/pyRevitLabs/pyRevitCLI/PyRevitCLIReleaseCmds.cs @@ -66,7 +66,7 @@ internal static void } // or find first release matching given pattern else if (searchPattern != null) { - matchedRelease = PyRevitReleases.FindReleases(searchPattern, includePreRelease: listPreReleases).First(); + matchedRelease = PyRevitReleases.FindReleases(searchPattern, includePreRelease: listPreReleases).FirstOrDefault(); if (matchedRelease is null) throw new PyRevitException( string.Format("No release matching \"{0}\" were found.", searchPattern) @@ -106,7 +106,15 @@ internal static void string downloadUrl = null; switch (assetType) { case GithubReleaseAssetType.Archive: downloadUrl = matchedRelease.ArchiveURL; break; - case GithubReleaseAssetType.Installer: downloadUrl = matchedRelease.InstallerURL; break; + case GithubReleaseAssetType.Installer: + { + var rawInstallerUrl = matchedRelease.InstallerURL; + + downloadUrl = rawInstallerUrl.Replace(".nupkg", "_signed.exe").Replace("_CLI_", "_").Replace("-cli.", "_").Replace("_admin_signed.exe", "_signed.exe"); + + } + break; + case GithubReleaseAssetType.Unknown: downloadUrl = null; break; } @@ -119,7 +127,7 @@ internal static void logger.Debug("Saving package to \"{0}\"", destPath); // download file and report - CommonUtils.DownloadFile(downloadUrl, destPath, progressToken: Path.GetFileName(downloadUrl)); + CommonUtils.DownloadFile(downloadUrl, destPath); Console.WriteLine( string.Format("Downloaded package to \"{0}\"", destPath) ); diff --git a/dev/pyRevitLabs/pyRevitCLI/pyRevitCLI.csproj b/dev/pyRevitLabs/pyRevitCLI/pyRevitCLI.csproj index 993022adc..5c12e6273 100644 --- a/dev/pyRevitLabs/pyRevitCLI/pyRevitCLI.csproj +++ b/dev/pyRevitLabs/pyRevitCLI/pyRevitCLI.csproj @@ -5,16 +5,23 @@ pyrevit_cli.ico pyrevit.manifest true + + true + + x64 + net8.0-windows + + true - - + + - - + + @@ -24,18 +31,4 @@ - - - - - - - - - - - - - - \ No newline at end of file diff --git a/dev/pyRevitLabs/pyRevitCLIAutoComplete/pyrevit-autocomplete.go b/dev/pyRevitLabs/pyRevitCLIAutoComplete/pyrevit-autocomplete.go index 08fe2129b..d991c74c7 100644 --- a/dev/pyRevitLabs/pyRevitCLIAutoComplete/pyrevit-autocomplete.go +++ b/dev/pyRevitLabs/pyRevitCLIAutoComplete/pyrevit-autocomplete.go @@ -34,8 +34,8 @@ func main() { "env": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ - "--json": complete.PredictNothing, "--log": complete.PredictNothing, + "--json": complete.PredictNothing, "--help": complete.PredictNothing, }, }, @@ -49,12 +49,12 @@ func main() { Sub: complete.Commands{}, Flags: complete.Flags{ "--branch": complete.PredictNothing, - "--image": complete.PredictNothing, - "--log": complete.PredictNothing, "--help": complete.PredictNothing, - "--dest": complete.PredictNothing, + "--log": complete.PredictNothing, "--password": complete.PredictNothing, "--token": complete.PredictNothing, + "--dest": complete.PredictNothing, + "--image": complete.PredictNothing, }, }, "clones": complete.Command{ @@ -119,16 +119,16 @@ func main() { "origin": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ - "--reset": complete.PredictNothing, "--log": complete.PredictNothing, + "--reset": complete.PredictNothing, }, }, "update": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ + "--log": complete.PredictNothing, "--password": complete.PredictNothing, "--token": complete.PredictNothing, - "--log": complete.PredictNothing, }, }, "deployments": complete.Command{ @@ -149,17 +149,17 @@ func main() { "default": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ - "--allusers": complete.PredictNothing, "--installed": complete.PredictNothing, "--attached": complete.PredictNothing, + "--allusers": complete.PredictNothing, }, }, }, Flags: complete.Flags{ - "--allusers": complete.PredictNothing, - "--help": complete.PredictNothing, "--installed": complete.PredictNothing, + "--help": complete.PredictNothing, "--attached": complete.PredictNothing, + "--allusers": complete.PredictNothing, }, }, "attached": complete.Command{ @@ -177,8 +177,8 @@ func main() { "detach": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--log": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, "extend": complete.Command{ @@ -186,28 +186,28 @@ func main() { "ui": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ + "--dest": complete.PredictNothing, "--password": complete.PredictNothing, - "--log": complete.PredictNothing, "--token": complete.PredictNothing, - "--dest": complete.PredictNothing, + "--log": complete.PredictNothing, }, }, "lib": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ + "--dest": complete.PredictNothing, "--password": complete.PredictNothing, - "--log": complete.PredictNothing, "--token": complete.PredictNothing, - "--dest": complete.PredictNothing, + "--log": complete.PredictNothing, }, }, }, Flags: complete.Flags{ - "--log": complete.PredictNothing, "--help": complete.PredictNothing, + "--log": complete.PredictNothing, "--password": complete.PredictNothing, - "--dest": complete.PredictNothing, "--token": complete.PredictNothing, + "--dest": complete.PredictNothing, }, }, "extensions": complete.Command{ @@ -237,8 +237,8 @@ func main() { "origin": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ - "--reset": complete.PredictNothing, "--log": complete.PredictNothing, + "--reset": complete.PredictNothing, }, }, "paths": complete.Command{ @@ -246,8 +246,8 @@ func main() { "forget": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ - "--all": complete.PredictNothing, "--log": complete.PredictNothing, + "--all": complete.PredictNothing, }, }, "add": complete.Command{ @@ -258,8 +258,8 @@ func main() { }, }, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--log": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, "enable": complete.Command{ @@ -279,8 +279,8 @@ func main() { "forget": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ - "--all": complete.PredictNothing, "--log": complete.PredictNothing, + "--all": complete.PredictNothing, }, }, "add": complete.Command{ @@ -291,22 +291,22 @@ func main() { }, }, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--log": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, "update": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ + "--log": complete.PredictNothing, "--password": complete.PredictNothing, "--token": complete.PredictNothing, - "--log": complete.PredictNothing, }, }, }, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--log": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, "releases": complete.Command{ @@ -351,8 +351,8 @@ func main() { }, }, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--pre": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, "revits": complete.Command{ @@ -367,15 +367,15 @@ func main() { Sub: complete.Commands{}, Flags: complete.Flags{ "--rte": complete.PredictNothing, - "--rft": complete.PredictNothing, "--csv": complete.PredictNothing, + "--rft": complete.PredictNothing, }, }, }, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--installed": complete.PredictNothing, "--supported": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, "run": complete.Command{ @@ -386,9 +386,9 @@ func main() { }, }, Flags: complete.Flags{ - "--purge": complete.PredictNothing, - "--help": complete.PredictNothing, "--models": complete.PredictNothing, + "--help": complete.PredictNothing, + "--purge": complete.PredictNothing, "--import": complete.PredictNothing, "--allowdialogs": complete.PredictNothing, "--revit": complete.PredictNothing, @@ -415,8 +415,8 @@ func main() { "config": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--from": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, "configs": complete.Command{ @@ -708,8 +708,8 @@ func main() { }, }, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--log": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, "telemetry": complete.Command{ @@ -778,8 +778,8 @@ func main() { }, }, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--log": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, "apptelemetry": complete.Command{ @@ -839,25 +839,25 @@ func main() { }, }, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--log": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, "doctor": complete.Command{ Sub: complete.Commands{}, Flags: complete.Flags{ - "--help": complete.PredictNothing, "--dryrun": complete.PredictNothing, "--list": complete.PredictNothing, + "--help": complete.PredictNothing, }, }, }, Flags: complete.Flags{ - "--usage": complete.PredictNothing, + "--version": complete.PredictNothing, "--help": complete.PredictNothing, - "--verbose": complete.PredictNothing, "--debug": complete.PredictNothing, - "--version": complete.PredictNothing, + "--usage": complete.PredictNothing, + "--verbose": complete.PredictNothing, }, } complete.New("pyrevit", pyrevit).Run() diff --git a/dev/pyRevitLabs/pyRevitDoctor/pyRevitDoctor.csproj b/dev/pyRevitLabs/pyRevitDoctor/pyRevitDoctor.csproj index 1e66f8f67..9a3864e08 100644 --- a/dev/pyRevitLabs/pyRevitDoctor/pyRevitDoctor.csproj +++ b/dev/pyRevitLabs/pyRevitDoctor/pyRevitDoctor.csproj @@ -3,5 +3,12 @@ Exe pyrevit-doctor pyrevit-doctor.ico + + true + + x64 + net8.0-windows + + true \ No newline at end of file diff --git a/dev/pyRevitLabs/pyRevitLabs.Common/CommonUtils.cs b/dev/pyRevitLabs/pyRevitLabs.Common/CommonUtils.cs index fa100d943..7f6a55c21 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Common/CommonUtils.cs +++ b/dev/pyRevitLabs/pyRevitLabs.Common/CommonUtils.cs @@ -138,7 +138,7 @@ public static HttpWebRequest GetHttpWebRequest(string url) { throw new pyRevitNoInternetConnectionException(); } - public static string DownloadFile(string url, string destPath, string progressToken = null) { + public static string DownloadFile(string url, string destPath) { try { using (var client = GetWebClient()) { client.Headers.Add("User-Agent", "pyrevit-cli"); @@ -161,7 +161,7 @@ public static string DownloadFile(string url, string destPath, string progressTo } catch (Exception dlEx) { logger.Debug("Error downloading file. | {0}", dlEx.Message); - throw dlEx; + throw; } return destPath; @@ -375,21 +375,6 @@ public static string GenerateRandomName(int len = 16) { public static string GetProcessFileName() => Process.GetCurrentProcess().MainModule.FileName; public static string GetProcessPath() => Path.GetDirectoryName(GetProcessFileName()); public static string GetAssemblyPath() => Path.GetDirectoryName(typeof(T).Assembly.Location); - - public static string GenerateSHA1Hash(string filePath) { - // Use input string to calculate SHA1 hash - using (FileStream fs = new FileStream(filePath, FileMode.Open)) { - using (BufferedStream bs = new BufferedStream(fs)) { - using (var sha1 = new System.Security.Cryptography.SHA1Managed()) { - StringBuilder sb = new StringBuilder(); - foreach (byte b in sha1.ComputeHash(bs)) { - sb.Append(b.ToString("X2")); - } - return sb.ToString(); - } - } - } - } } } diff --git a/dev/pyRevitLabs/pyRevitLabs.Common/Consts.cs b/dev/pyRevitLabs/pyRevitLabs.Common/Consts.cs index be0549f43..6a98001b6 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Common/Consts.cs +++ b/dev/pyRevitLabs/pyRevitLabs.Common/Consts.cs @@ -36,7 +36,7 @@ public class PyRevitLabsConsts { // consts for the official pyRevit repo public const string OriginalRepoName = ProductName; - public static string OriginalRepoId = string.Format(@"eirannejad/{0}", ProductName); + public static string OriginalRepoId = string.Format(@"pyrevitlabs/{0}", ProductName); public static string OriginalRepoBasePath = string.Format(@"https://github.com/{0}", OriginalRepoId); public static string OriginalRepoGitPath = OriginalRepoBasePath + DefaultGitDirName; diff --git a/dev/pyRevitLabs/pyRevitLabs.Common/GitInstaller.cs b/dev/pyRevitLabs/pyRevitLabs.Common/GitInstaller.cs index f41ec25c0..b58ebc4f0 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Common/GitInstaller.cs +++ b/dev/pyRevitLabs/pyRevitLabs.Common/GitInstaller.cs @@ -148,7 +148,7 @@ public static UpdateStatus ForcedUpdate(string repoPath, GitInstallerCredentials // before updating, let's first // forced checkout to overwrite possible local changes - // Re: https://github.com/eirannejad/pyRevit/issues/229 + // Re: https://github.com/pyrevitlabs/pyRevit/issues/229 var checkoutOptions = new CheckoutOptions(); checkoutOptions.CheckoutModifiers = CheckoutModifiers.Force; Commands.Checkout(repo, repo.Head, checkoutOptions); diff --git a/dev/pyRevitLabs/pyRevitLabs.Common/Github.cs b/dev/pyRevitLabs/pyRevitLabs.Common/Github.cs index ffbe8a82e..c55576953 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Common/Github.cs +++ b/dev/pyRevitLabs/pyRevitLabs.Common/Github.cs @@ -76,7 +76,7 @@ public class GithubAPI { private static readonly Logger logger = LogManager.GetCurrentClassLogger(); public const string APIReleasesURL = @"https://api.github.com/repos/{0}/releases"; - + public const string ArchiveFileExtension = ".zip"; public const string ArchiveInternalBranchPath = @"{0}-{1}"; public const string APIArchiveURL = @"https://github.com/{0}/archive/{1}" + ArchiveFileExtension; @@ -87,10 +87,10 @@ public static IEnumerable GetReleasesFromAPI(string endpoint, out string n // make github api call and get a list of releases // https://developer.github.com/v3/repos/releases/ HttpWebRequest request = CommonUtils.GetHttpWebRequest(endpoint); - if (AuthToken is null) - throw new Exception("Missing authorization token. Set on GITHUBTOKEN env var"); + // if (AuthToken is null) + // throw new Exception("Missing authorization token. Set on GITHUBTOKEN env var"); - request.Headers.Add(HttpRequestHeader.Authorization, $"token {AuthToken}"); + // request.Headers.Add(HttpRequestHeader.Authorization, $"token {AuthToken}"); var response = request.GetResponse(); // extract list of PyRevitRelease from json diff --git a/dev/pyRevitLabs/pyRevitLabs.Common/JSONDataSource.cs b/dev/pyRevitLabs/pyRevitLabs.Common/JSONDataSource.cs index 09ec24693..670a1f8eb 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Common/JSONDataSource.cs +++ b/dev/pyRevitLabs/pyRevitLabs.Common/JSONDataSource.cs @@ -114,7 +114,7 @@ public void UpdateData(bool forceUpdate = false) { } logger.Debug("Downloading to \"{0}\"", dataSourceCacheFile); - CommonUtils.DownloadFile(DataSourceURL, dataSourceCacheFile, progressToken: DataFileName); + CommonUtils.DownloadFile(DataSourceURL, dataSourceCacheFile); } catch (Exception dlEx) { logger.Debug("Error downloading host database file. | {0}", dlEx.Message); diff --git a/dev/pyRevitLabs/pyRevitLabs.Common/OSVersionInfo.cs b/dev/pyRevitLabs/pyRevitLabs.Common/OSVersionInfo.cs index 7875716d4..159d6c78c 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Common/OSVersionInfo.cs +++ b/dev/pyRevitLabs/pyRevitLabs.Common/OSVersionInfo.cs @@ -4,7 +4,6 @@ using System.Linq; using System.Text; using System.Threading.Tasks; -using System.Management; using System.Security.Principal; using System.IO; diff --git a/dev/pyRevitLabs/pyRevitLabs.Common/UserEnv.cs b/dev/pyRevitLabs/pyRevitLabs.Common/UserEnv.cs index ccb754bf3..47fea0f4e 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Common/UserEnv.cs +++ b/dev/pyRevitLabs/pyRevitLabs.Common/UserEnv.cs @@ -47,7 +47,7 @@ public static string GetWindowsVersion() { } public static Version GetInstalledDotNetVersion() { - return DotNetVersion.Find(); + return DotNetVersion.GetVersion(); } public static List GetInstalledDotnetTargetPacks() { diff --git a/dev/pyRevitLabs/pyRevitLabs.Common/UserSecurity.cs b/dev/pyRevitLabs/pyRevitLabs.Common/UserSecurity.cs index 8155c45f1..ec0091e2e 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Common/UserSecurity.cs +++ b/dev/pyRevitLabs/pyRevitLabs.Common/UserSecurity.cs @@ -4,7 +4,6 @@ using System.Linq; using System.Text; using System.Threading.Tasks; -using System.Management; using System.Security.Principal; using System.IO; diff --git a/dev/pyRevitLabs/pyRevitLabs.Common/pyRevitLabs.Common.csproj b/dev/pyRevitLabs/pyRevitLabs.Common/pyRevitLabs.Common.csproj index 104d265af..64a7ba8b4 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Common/pyRevitLabs.Common.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.Common/pyRevitLabs.Common.csproj @@ -1,39 +1,63 @@  - - - - - - - - - - - - - - - - - + + x64 + net48;net8.0-windows + + - + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/dev/pyRevitLabs/pyRevitLabs.CommonCLI/pyRevitLabs.CommonCLI.csproj b/dev/pyRevitLabs/pyRevitLabs.CommonCLI/pyRevitLabs.CommonCLI.csproj index a5b9e0e7b..e5926acef 100644 --- a/dev/pyRevitLabs/pyRevitLabs.CommonCLI/pyRevitLabs.CommonCLI.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.CommonCLI/pyRevitLabs.CommonCLI.csproj @@ -1,2 +1,6 @@  + + x64 + net48;net8.0-windows + \ No newline at end of file diff --git a/dev/pyRevitLabs/pyRevitLabs.CommonWPF/pyRevitLabs.CommonWPF.csproj b/dev/pyRevitLabs/pyRevitLabs.CommonWPF/pyRevitLabs.CommonWPF.csproj index 5665160a9..ab493c6f5 100644 --- a/dev/pyRevitLabs/pyRevitLabs.CommonWPF/pyRevitLabs.CommonWPF.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.CommonWPF/pyRevitLabs.CommonWPF.csproj @@ -1,21 +1,16 @@  true + true + + x64 + net48;net8.0-windows + + + - - - - - - - - - - - - \ No newline at end of file diff --git a/dev/pyRevitLabs/pyRevitLabs.DeffrelDB/pyRevitLabs.DeffrelDB.csproj b/dev/pyRevitLabs/pyRevitLabs.DeffrelDB/pyRevitLabs.DeffrelDB.csproj index d311d72ec..c5589e5cd 100644 --- a/dev/pyRevitLabs/pyRevitLabs.DeffrelDB/pyRevitLabs.DeffrelDB.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.DeffrelDB/pyRevitLabs.DeffrelDB.csproj @@ -1,4 +1,9 @@  + + x64 + net48;net8.0-windows + + diff --git a/dev/pyRevitLabs/pyRevitLabs.Emojis/Emojis.cs b/dev/pyRevitLabs/pyRevitLabs.Emojis/Emojis.cs index 7dc5622a2..9234b4efc 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Emojis/Emojis.cs +++ b/dev/pyRevitLabs/pyRevitLabs.Emojis/Emojis.cs @@ -2,6 +2,7 @@ using System.IO; using System.IO.Compression; using System.Drawing; +using System.Linq; using System.Collections.Generic; using System.Text.RegularExpressions; using System.Reflection; @@ -2645,10 +2646,12 @@ public static string Emojize(string input) { if (_emojiZip is null) ExtractEmojis(); - var matches = new Regex(@"\:(?[^\s]+?)\:").Matches(input); + var matches = new Regex(@"\:(?[^\s]+?)\:").Matches(input) + .Cast() + .Select(m => m.Groups["code"].Value) + .Distinct(); // find the emoji shorthands - foreach (Match match in matches) { - var emojiShortCode = match.Groups["code"].Value; + foreach (var emojiShortCode in matches) { if (EmojiDict.ContainsKey(emojiShortCode)) { // find the emoji unicode var shortHand = string.Format(":{0}:", emojiShortCode); diff --git a/dev/pyRevitLabs/pyRevitLabs.Emojis/pyRevitLabs.Emojis.csproj b/dev/pyRevitLabs/pyRevitLabs.Emojis/pyRevitLabs.Emojis.csproj index 321f6759a..00b48c141 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Emojis/pyRevitLabs.Emojis.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.Emojis/pyRevitLabs.Emojis.csproj @@ -1,6 +1,14 @@  + + true + true + + x64 + net48;net8.0-windows + + - + diff --git a/dev/pyRevitLabs/pyRevitLabs.Language/pyRevitLabs.Language.csproj b/dev/pyRevitLabs/pyRevitLabs.Language/pyRevitLabs.Language.csproj index a5b9e0e7b..e5926acef 100644 --- a/dev/pyRevitLabs/pyRevitLabs.Language/pyRevitLabs.Language.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.Language/pyRevitLabs.Language.csproj @@ -1,2 +1,6 @@  + + x64 + net48;net8.0-windows + \ No newline at end of file diff --git a/dev/pyRevitLabs/pyRevitLabs.PyRevit.Runtime.Shared/pyRevitLabs.PyRevit.Runtime.Shared.csproj b/dev/pyRevitLabs/pyRevitLabs.PyRevit.Runtime.Shared/pyRevitLabs.PyRevit.Runtime.Shared.csproj index 4450d6f4c..59ec21186 100644 --- a/dev/pyRevitLabs/pyRevitLabs.PyRevit.Runtime.Shared/pyRevitLabs.PyRevit.Runtime.Shared.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.PyRevit.Runtime.Shared/pyRevitLabs.PyRevit.Runtime.Shared.csproj @@ -1,2 +1,6 @@ + + x64 + net48;net8.0-windows + \ No newline at end of file diff --git a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitAttachments.cs b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitAttachments.cs index 5ed22db2b..a51339782 100644 --- a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitAttachments.cs +++ b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitAttachments.cs @@ -28,7 +28,7 @@ public static void Attach(int revitYear, bool allUsers = false, bool force = false) { // make the addin manifest file - var engine = clone.GetEngine(engineVer); + var engine = clone.GetEngine(revitYear, engineVer); if (engine.Runtime) { logger.Debug(string.Format("Attaching Clone \"{0}\" @ \"{1}\" to Revit {2}", clone.Name, clone.ClonePath, revitYear)); diff --git a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitClone.cs b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitClone.cs index 0716d23c4..eb1b67143 100644 --- a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitClone.cs +++ b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitClone.cs @@ -12,22 +12,27 @@ using Nett; using pyRevitLabs.NLog; -namespace pyRevitLabs.PyRevit { - public struct PyRevitCloneFromImageArgs { +namespace pyRevitLabs.PyRevit +{ + public struct PyRevitCloneFromImageArgs + { public string Url; public string BranchName; public string DeploymentName; - public override string ToString() { + public override string ToString() + { return string.Format("Url: \"{0}\" | Branch: \"{1}\" | Deployment: \"{2}\"", Url, BranchName, DeploymentName); } } - public class PyRevitClone { + public class PyRevitClone + { // private logger and data private static readonly Logger logger = LogManager.GetCurrentClassLogger(); - private static readonly List reservedNames = new List() { + private static readonly List reservedNames = new List() + { "git", "pyrevit", "blog", "docs", "source", "youtube", "support", "env", "clone", "clones", "add", "forget", "rename", "delete", "branch", "commit", "version", @@ -39,11 +44,13 @@ public class PyRevitClone { }; // constructors - public PyRevitClone(string clonePath, string name = null) { + public PyRevitClone(string clonePath, string name = null) + { // clone path could be any path inside or outside the clonePath // find the clone root first var _clonePath = FindValidClonePathAbove(clonePath); - if (_clonePath is null) { + if (_clonePath is null) + { _clonePath = FindValidClonePathBelow(clonePath); if (_clonePath is null) throw new PyRevitException( @@ -53,8 +60,10 @@ public PyRevitClone(string clonePath, string name = null) { ClonePath = _clonePath.NormalizeAsPath(); - if (name != null) { - if (!reservedNames.Contains(name)) { + if (name != null) + { + if (!reservedNames.Contains(name)) + { Name = name; } else @@ -64,7 +73,9 @@ public PyRevitClone(string clonePath, string name = null) { Name = string.Format("Unnamed-{0}", ClonePath.GenerateMD5Hash().GetHashShort()); } - private PyRevitClone(string clonePath) : this(clonePath, null) {} + private PyRevitClone(string clonePath) : this(clonePath, null) + { + } // properties public string Name { get; private set; } @@ -73,37 +84,48 @@ private PyRevitClone(string clonePath) : this(clonePath, null) {} public string ExtensionsPath => GetExtensionsPath(ClonePath); - public override string ToString() { + public override string ToString() + { if (IsRepoDeploy) return string.Format( "{0} | Branch: \"{1}\" | Version: \"{2}\" | Path: \"{3}\"", Name, Branch, string.Format("{0}:{1}", ModuleVersion, ShortCommit), ClonePath); - else { + else + { return string.Format( "{0} | Deploy: \"{1}\" | Branch: \"{2}\" | Version: \"{3}\" | Path: \"{4}\"", Name, Deployment?.Name, Branch, ModuleVersion, ClonePath); } } - public bool IsRepoDeploy { - get { - try { + public bool IsRepoDeploy + { + get + { + try + { return IsDeployedWithRepo(ClonePath); } - catch { return false; } + catch + { + return false; + } } } public bool IsValid => IsCloneValid(ClonePath); - public bool HasDeployments { + public bool HasDeployments + { get { return VerifyHasDeployments(ClonePath); } } public string ModuleVersion => GetDeployedVersion(ClonePath); - public string Branch { - get { + public string Branch + { + get + { if (IsRepoDeploy) return GetBranch(ClonePath); else @@ -122,7 +144,8 @@ public string Branch { public PyRevitDeployment Deployment => GetCurrentDeployment(ClonePath); // equality checks - public override bool Equals(object obj) { + public override bool Equals(object obj) + { var other = obj as PyRevitClone; if (ClonePath != other.ClonePath) @@ -131,33 +154,41 @@ public override bool Equals(object obj) { return true; } - public override int GetHashCode() { + public override int GetHashCode() + { return ClonePath.GetHashCode(); } - public bool Matches(string copyNameOrPath) { + public bool Matches(string copyNameOrPath) + { if (Name.ToLower() == copyNameOrPath.ToLower()) return true; - try { + try + { return ClonePath == copyNameOrPath.NormalizeAsPath(); } - catch { } + catch + { + } return false; } - public void Rename(string newName) { + public void Rename(string newName) + { if (newName != null) Name = newName; } public List GetEngines() => GetEngines(ClonePath); - public PyRevitEngine GetEngine(PyRevitEngineVersion engineVer) => GetEngine(ClonePath, engineVer: engineVer); + public PyRevitEngine GetEngine(int revitYear, PyRevitEngineVersion engineVer) => GetEngine(revitYear, ClonePath, engineVer: engineVer); + + public PyRevitEngine GetCPythonEngine(PyRevitEngineVersion engineVer) => GetCPythonEngine(ClonePath, engineVer); public PyRevitEngine GetConfiguredEngine(string engineId) => GetConfiguredEngine(ClonePath, engineId); - + public List GetConfiguredEngines() => GetConfiguredEngines(ClonePath); public List GetConfiguredDeployments() => GetConfiguredDeployments(ClonePath); @@ -178,7 +209,8 @@ public void Rename(string newName) { // static methods ============================================================================================ // determine if this is a git repo - public static bool IsDeployedWithRepo(string clonePath) { + public static bool IsDeployedWithRepo(string clonePath) + { return CommonUtils.VerifyPath(Path.Combine(clonePath, PyRevitLabsConsts.DefaultGitDirName)); } @@ -199,7 +231,8 @@ public static string GetPyRevitVersionFilePath(string clonePath) => Path.Combine(GetPyRevitPath(clonePath), PyRevitConsts.VersionFilename).NormalizeAsPath(); // get pyRevitFile path - public static string GetPyRevitFilePath(string clonePath) { + public static string GetPyRevitFilePath(string clonePath) + { var prFile = Path.Combine(clonePath, PyRevitConsts.PyRevitfileFilename); if (File.Exists(prFile)) return prFile; @@ -209,16 +242,20 @@ public static string GetPyRevitFilePath(string clonePath) { // check if path is valid pyrevit clone // @handled @logs - public static void VerifyCloneValidity(string clonePath) { - if (clonePath != null && clonePath != string.Empty) { + public static void VerifyCloneValidity(string clonePath) + { + if (clonePath != null && clonePath != string.Empty) + { var normClonePath = clonePath.NormalizeAsPath(); logger.Debug("Checking pyRevit clone validity \"{0}\"", normClonePath); - if (CommonUtils.VerifyPath(normClonePath)) { + if (CommonUtils.VerifyPath(normClonePath)) + { // determine clone validity based on directory availability logger.Debug("Checking clone validity by directory structure..."); var pyrevitDir = GetPyRevitPath(normClonePath); logger.Debug("Checking pyRevit path \"{0}\"", pyrevitDir); - if (!CommonUtils.VerifyPath(pyrevitDir)) { + if (!CommonUtils.VerifyPath(pyrevitDir)) + { throw new pyRevitInvalidPyRevitCloneException(normClonePath); } @@ -230,23 +267,29 @@ public static void VerifyCloneValidity(string clonePath) { logger.Debug("Valid pyRevit clone \"{0}\"", normClonePath); return; } + throw new pyRevitResourceMissingException(normClonePath); } + throw new PyRevitException("Clone path can not be null."); } // get clone from manifest file - public static PyRevitClone GetCloneFromManifest(RevitAddonManifest manifest) { + public static PyRevitClone GetCloneFromManifest(RevitAddonManifest manifest) + { return new PyRevitClone(Path.GetDirectoryName(manifest.Assembly)); } // return true of false for clone validity - public static bool IsCloneValid(string clonePath) { - try { + public static bool IsCloneValid(string clonePath) + { + try + { VerifyCloneValidity(clonePath); return true; } - catch (Exception ex) { + catch (Exception ex) + { logger.Debug("Invalid pyRevit clone. | {0}", ex.Message); return false; } @@ -255,116 +298,183 @@ public static bool IsCloneValid(string clonePath) { // get engine from clone path // returns latest with default engineVer value // @handled @logs - public static PyRevitEngine GetEngine(string clonePath, PyRevitEngineVersion engineVer) { + public static PyRevitEngine GetEngine(int revitYear, string clonePath, PyRevitEngineVersion engineVer) + { + logger.Debug("Finding engine \"{0}\" path in \"{1}\"", engineVer, clonePath); + var isNetCore = revitYear >= 2025; + if (engineVer == PyRevitEngineVersion.Default) + { + return GetDefaultEngine(isNetCore, clonePath); + } + else + { + try + { + return GetEngines(clonePath) + .Single(x => x.Version == engineVer && x.IsNetCore == isNetCore); + } + catch (InvalidOperationException) + { + throw new PyRevitException( + $"Can not find engine or more than one engine found with specified version \"{engineVer.Version}\""); + } + } + } + + public static PyRevitEngine GetCPythonEngine(string clonePath, PyRevitEngineVersion engineVer) + { logger.Debug("Finding engine \"{0}\" path in \"{1}\"", engineVer, clonePath); - if (engineVer == PyRevitEngineVersion.Default) { - var defaultEng = GetDefaultEngine(clonePath); - if (defaultEng is null) - throw new PyRevitException("Can not find default engine"); - return defaultEng; + try + { + return GetEngines(clonePath).Single(x => x.Version == engineVer); } - else { - var engines = GetEngines(clonePath).Where(x => x.Version == engineVer); - var engineCount = engines.Count(); - if (engineCount == 0) - throw new PyRevitException($"Can not find engine with specified version \"{engineVer.Version}\" is found"); - else if (engineCount > 1) - throw new PyRevitException($"More than one engine with specified version \"{engineVer.Version}\" is found"); - - return engines.First(); + catch (InvalidOperationException) + { + throw new PyRevitException( + $"Can not find engine or more than one CPython engine found with specified version \"{engineVer.Version}\""); } } - public static PyRevitEngine GetDefaultEngine(string clonePath) { - foreach (var eng in GetEngines(clonePath)) - if (eng.IsDefault) - return eng; - throw new PyRevitException($"Can not find default engine"); + private static PyRevitEngine GetDefaultEngine(bool isNetCore, string clonePath) + { + var eng = GetEngines(clonePath) + .FirstOrDefault(x => x.IsDefault && x.IsNetCore == isNetCore); + return eng is null ? throw new PyRevitException("Can not find default engine") : eng; } // get all engines from clone path // returns latest with default engineVer value // @handled @logs - public static List GetEngines(string clonePath) { - if (GetPyRevitFilePath(clonePath) != null) { + public static List GetEngines(string clonePath) + { + if (GetPyRevitFilePath(clonePath) != null) + { return GetConfiguredEngines(clonePath); } - else { + else + { logger.Debug("Finding engines in \"{0}\"", clonePath); - var enginesDir = FindEnginesDirectory(clonePath); - return FindEngines(enginesDir); + return FindEngines(false, FindEnginesDirectory(PyRevitConsts.NetFxFolder, clonePath)) + .Union(FindEngines(true, FindEnginesDirectory(PyRevitConsts.NetCoreFolder, clonePath))) + .ToList(); } } - public static PyRevitEngine GetConfiguredEngine(string clonePath, string engineId) { - foreach (var eng in GetEngines(clonePath)) - if (eng.Id.ToLower() == engineId.ToLower()) - return eng; - throw new PyRevitException($"Can not find engine \"{engineId}\""); + public static PyRevitEngine GetConfiguredEngine(string clonePath, string engineId) + { + var engine = GetEngines(clonePath).FirstOrDefault(eng => eng.Id.ToLower() == engineId.ToLower()); + if (engine is null) + { + throw new PyRevitException($"Can not find engine \"{engineId}\""); + } + return engine; } // extract deployment config from pyRevitfile inside the clone - public static List GetConfiguredEngines(string clonePath) { + public static List GetConfiguredEngines(string clonePath) + { var engines = new List(); var prFile = GetPyRevitFilePath(clonePath); - try { + try + { TomlTable table = Toml.ReadFile(prFile); var enginesCfgs = table.Get("engines"); - foreach (var engineCfg in enginesCfgs) { + foreach (var engineCfg in enginesCfgs) + { logger.Debug("Engine configuration found: {0}", engineCfg.Key); var infoTable = engineCfg.Value as TomlTable; foreach (KeyValuePair entry in infoTable) logger.Debug("\"{0}\" : \"{1}\"", entry.Key, entry.Value); - engines.Add( - new PyRevitEngine( - id: engineCfg.Key, - engineVer: new PyRevitEngineVersion(infoTable["version"].Get()), - runtime: infoTable.TryGetValue("runtime") != null ? infoTable["runtime"].Get() : true, // be flexible since its a new feature - enginePath: Path.Combine(clonePath, infoTable["path"].Get()), - assemblyName: infoTable.TryGetValue("assembly") != null? infoTable["assembly"].Get() : PyRevitConsts.LegacyEngineDllName, // be flexible since its a new feature - kernelName: infoTable["kernel"].Get(), - engineDescription: infoTable["description"].Get(), - isDefault: engineCfg.Key.Contains("DEFAULT") - ) - ); + string kernel = infoTable["kernel"].Get(); + if (kernel.Equals("cpython", StringComparison.CurrentCultureIgnoreCase)) + { + var cenginesDir = Path.Combine( + clonePath, + PyRevitConsts.BinDirName, + PyRevitConsts.BinCEnginesDirName); + AddEngine(engines, engineCfg, infoTable, cenginesDir, false); + } + else + { + string enginesDir = Path.Combine( + clonePath, + PyRevitConsts.BinDirName, + PyRevitConsts.NetFxFolder, + PyRevitConsts.BinEnginesDirName); + AddEngine(engines, engineCfg, infoTable, enginesDir, false); + + enginesDir = Path.Combine( + clonePath, + PyRevitConsts.BinDirName, + PyRevitConsts.NetCoreFolder, + PyRevitConsts.BinEnginesDirName); + AddEngine(engines, engineCfg, infoTable, enginesDir, true); + } } } - catch (Exception ex) { + catch (Exception ex) + { logger.Debug(string.Format("Error parsing clone \"{0}\" engines configs from \"{1}\" | {2}", - clonePath, prFile, ex.Message)); + clonePath, prFile, ex.Message)); } return engines; } + private static void AddEngine(List engines, KeyValuePair engineCfg, TomlTable infoTable, string enginesDir, bool netcore) + { + engines.Add( + new PyRevitEngine( + id: engineCfg.Key, + engineVer: new PyRevitEngineVersion(infoTable["version"].Get()), + runtime: infoTable.TryGetValue("runtime") != null + ? infoTable["runtime"].Get() + : true, // be flexible since its a new feature + enginePath: Path.Combine(enginesDir, infoTable["path"].Get()), + assemblyName: infoTable.TryGetValue("assembly") != null + ? infoTable["assembly"].Get() + : PyRevitConsts.LegacyEngineDllName, // be flexible since its a new feature + kernelName: infoTable["kernel"].Get(), + engineDescription: infoTable["description"].Get(), + isDefault: engineCfg.Key.Contains("DEFAULT"), + isNetCore: netcore + ) + ); + } + // extract deployment config from pyRevitfile inside the clone - public static List GetConfiguredDeployments(string clonePath) { + public static List GetConfiguredDeployments(string clonePath) + { var deps = new List(); var prFile = GetPyRevitFilePath(clonePath); - try { + try + { TomlTable table = Toml.ReadFile(prFile); var depCfgs = table.Get("deployments"); - foreach (KeyValuePair entry in depCfgs) { + foreach (KeyValuePair entry in depCfgs) + { logger.Debug("\"{0}\" : \"{1}\"", entry.Key, entry.Value); deps.Add( new PyRevitDeployment(entry.Key, - new List(((TomlArray)entry.Value).To())) - ); + new List(((TomlArray)entry.Value).To())) + ); } } - catch (Exception ex) { + catch (Exception ex) + { logger.Debug(string.Format("Error parsing clone \"{0}\" deployment configs at \"{1}\" | {2}", - clonePath, prFile, ex.Message)); + clonePath, prFile, ex.Message)); } return deps; } // get currently deployed deployment - public static PyRevitDeployment GetCurrentDeployment(string clonePath) { + public static PyRevitDeployment GetCurrentDeployment(string clonePath) + { var cloneArgs = ReadDeploymentArgs(clonePath); foreach (var dep in GetConfiguredDeployments(clonePath)) if (dep.Name == cloneArgs.DeploymentName) @@ -372,13 +482,15 @@ public static PyRevitDeployment GetCurrentDeployment(string clonePath) { return null; } - public static bool VerifyHasDeployments(string clonePath) { + public static bool VerifyHasDeployments(string clonePath) + { return GetConfiguredDeployments(clonePath).Count > 0; } // get pyrevit version from deployed clone // @handled @logs - public static string GetDeployedVersion(string clonePath) { + public static string GetDeployedVersion(string clonePath) + { VerifyCloneValidity(clonePath); var vesionFile = GetPyRevitVersionFilePath(clonePath); if (CommonUtils.VerifyFile(vesionFile)) @@ -389,42 +501,48 @@ public static string GetDeployedVersion(string clonePath) { // get branch from deployed clone // @handled @logs - public static string GetDeployedBranch(string clonePath) { + public static string GetDeployedBranch(string clonePath) + { var cloneArgs = ReadDeploymentArgs(clonePath); return cloneArgs.BranchName; } // get checkedout branch in git repo // @handled @logs - public static string GetBranch(string clonePath) { + public static string GetBranch(string clonePath) + { VerifyCloneValidity(clonePath); return GitInstaller.GetCheckedoutBranch(clonePath); } // get checkedout version in git repo // @handled @logs - public static string GetTag(string clonePath) { + public static string GetTag(string clonePath) + { // TODO: implement get version throw new NotImplementedException(); } // get checkedout branch in git repo // @handled @logs - public static string GetCommit(string clonePath) { + public static string GetCommit(string clonePath) + { VerifyCloneValidity(clonePath); return GitInstaller.GetHeadCommit(clonePath); } // get origin remote url // @handled @logs - public static string GetOrigin(string clonePath) { + public static string GetOrigin(string clonePath) + { VerifyCloneValidity(clonePath); return GitInstaller.GetRemoteUrl(clonePath, PyRevitConsts.DefaultCloneRemoteName); } // checkout branch in git repo // @handled @logs - public static void SetBranch(string clonePath, string branchName) { + public static void SetBranch(string clonePath, string branchName) + { VerifyCloneValidity(clonePath); if (branchName != null) GitInstaller.CheckoutBranch(clonePath, branchName); @@ -432,7 +550,8 @@ public static void SetBranch(string clonePath, string branchName) { // rebase clone to specific tag // @handled @logs - public static void SetTag(string clonePath, string tagName) { + public static void SetTag(string clonePath, string tagName) + { VerifyCloneValidity(clonePath); if (tagName != null) GitInstaller.RebaseToTag(clonePath, tagName); @@ -440,7 +559,8 @@ public static void SetTag(string clonePath, string tagName) { // rebase clone to specific commit // @handled @logs - public static void SetCommit(string clonePath, string commitHash) { + public static void SetCommit(string clonePath, string commitHash) + { VerifyCloneValidity(clonePath); if (commitHash != null) GitInstaller.RebaseToCommit(clonePath, commitHash); @@ -448,7 +568,8 @@ public static void SetCommit(string clonePath, string commitHash) { // set origin url to new url // @handled @logs - public static void SetOrigin(string clonePath, string originUrl) { + public static void SetOrigin(string clonePath, string originUrl) + { VerifyCloneValidity(clonePath); if (originUrl != null) GitInstaller.SetRemoteUrl(clonePath, PyRevitConsts.DefaultCloneRemoteName, originUrl); @@ -456,64 +577,76 @@ public static void SetOrigin(string clonePath, string originUrl) { // get list of builtin extensions // @handled @logs - public static List GetExtensions(string clonePath) { + public static List GetExtensions(string clonePath) + { VerifyCloneValidity(clonePath); return PyRevitExtensions.FindExtensions(PyRevitClone.GetExtensionsPath(clonePath)); } // get a specific builtin extension // @handled @logs - public static PyRevitExtension GetExtension(string clonePath, string searchPattern) { + public static PyRevitExtension GetExtension(string clonePath, string searchPattern) + { VerifyCloneValidity(clonePath); return PyRevitExtensions.FindExtension(PyRevitClone.GetExtensionsPath(clonePath), searchPattern); } // check if given assembly belongs to pyrevit - public static bool IsPyRevitAssembly(Assembly assm) { - try { + public static bool IsPyRevitAssembly(Assembly assm) + { + try + { var clone = new PyRevitClone(Path.GetDirectoryName(assm.Location)); return true; } - catch { + catch + { return false; } } // private: - private static PyRevitCloneFromImageArgs ReadDeploymentArgs(string clonePath) { + private static PyRevitCloneFromImageArgs ReadDeploymentArgs(string clonePath) + { var cloneMemoryFilePath = Path.Combine(clonePath, PyRevitConsts.DeployFromImageConfigsFilename); logger.Debug("Reading image clone parmeters from \"{0}\"", cloneMemoryFilePath); - try { + try + { var contents = File.ReadAllLines(cloneMemoryFilePath); logger.Debug("Image Path: \"{0}\"", contents[0]); logger.Debug("Branch: \"{0}\"", contents[1]); logger.Debug("Deployment: \"{0}\"", contents[2]); - var args = new PyRevitCloneFromImageArgs { + var args = new PyRevitCloneFromImageArgs + { Url = contents[0] == string.Empty ? PyRevitLabsConsts.OriginalRepoGitPath : contents[0], BranchName = contents[1] == string.Empty ? PyRevitLabsConsts.TragetBranch : contents[1], DeploymentName = contents[2] == string.Empty ? null : contents[2] }; logger.Debug(args); - + return args; } - catch (Exception ex) { + catch (Exception ex) + { throw new PyRevitException(string.Format("Error reading deployment arguments from \"{0}\" | {1}", - clonePath, ex.Message)); + clonePath, ex.Message)); } } // find valid clone directory downstream - private static string FindValidClonePathBelow(string startingPath) { + private static string FindValidClonePathBelow(string startingPath) + { logger.Debug("Searching for valid clones below: {0}", startingPath); - if (IsCloneValid(startingPath)) { + if (IsCloneValid(startingPath)) + { logger.Debug("Valid clone found at: {0}", startingPath); return startingPath; } else - foreach(var subFolder in Directory.GetDirectories(startingPath)) { + foreach (var subFolder in Directory.GetDirectories(startingPath)) + { var clonePath = FindValidClonePathBelow(subFolder); if (clonePath != null) return clonePath; @@ -523,10 +656,12 @@ private static string FindValidClonePathBelow(string startingPath) { } // find valid clone directory downstream - private static string FindValidClonePathAbove(string startingPath) { + private static string FindValidClonePathAbove(string startingPath) + { logger.Debug("Searching for valid clones above: {0}", startingPath); string testPath = startingPath; - while (!IsCloneValid(testPath)) { + while (!IsCloneValid(testPath)) + { testPath = Path.GetDirectoryName(testPath); if (testPath is null || testPath == string.Empty) return null; @@ -538,51 +673,63 @@ private static string FindValidClonePathAbove(string startingPath) { // find engine path with given version // @handled @logs - private static PyRevitEngine FindEngine(string enginesDir, int engineVer = 000) { + private static PyRevitEngine FindEngine(bool isNetCore, string enginesDir, int engineVer = 000) + { // engines are stored in directory named XXX based on engine version (e.g. 2711) // return latest if zero - if (engineVer == 000) { + if (engineVer == 000) + { PyRevitEngine latestEngine = null; // FindEngines will throw an error if engine directory is missing - foreach (var engine in FindEngines(enginesDir)) { + foreach (var engine in FindEngines(isNetCore, enginesDir)) + { if (engine.Version > engineVer) latestEngine = engine; } - if (latestEngine != null && latestEngine.Version != engineVer) { + if (latestEngine != null && latestEngine.Version != engineVer) + { logger.Debug("Latest engine path \"{0}\"", latestEngine.Path ?? "NULL"); return latestEngine; } else throw new PyRevitException( string.Format("Error determining latest engine from \"{0}\"", enginesDir) - ); + ); } - else { - foreach (var engine in FindEngines(enginesDir)) { - if (engine.Version == engineVer) { + else + { + foreach (var engine in FindEngines(isNetCore, enginesDir)) + { + if (engine.Version == engineVer) + { logger.Debug("Engine path \"{0}\"", engine.Path ?? "NULL"); return engine; } } } - throw new PyRevitException(string.Format("Engine \"{0}\" is not available at \"{1}\"", engineVer, enginesDir)); + throw new PyRevitException(string.Format("Engine \"{0}\" is not available at \"{1}\"", engineVer, + enginesDir)); } // find all engines under a given engine path // @handled @logs - private static List FindEngines(string enginesDir) { + private static List FindEngines(bool isNetCore, string enginesDir) + { // engines are stored in directory named XXX based on engine version (e.g. 2711) var engines = new List(); var engineFinder = new Regex(@"\d\d\d"); - if (CommonUtils.VerifyPath(enginesDir)) { - foreach (string engineDir in Directory.GetDirectories(enginesDir)) { + if (CommonUtils.VerifyPath(enginesDir)) + { + foreach (string engineDir in Directory.GetDirectories(enginesDir)) + { var engineDirName = Path.GetFileName(engineDir); var m = engineFinder.Match(engineDirName); - if (m.Success) { + if (m.Success) + { logger.Debug("Engine found \"{0}\":\"{1}\"", engineDirName, engineDir); // this method is for legacy repos. since engine configuration file is not available in @@ -598,7 +745,8 @@ private static List FindEngines(string enginesDir) { id: engineDirName, engineVer: (PyRevitEngineVersion)engineVer, runtime: runtime, - enginePath: engineDir) + enginePath: engineDir, + isNetCore: isNetCore) ); } } @@ -611,17 +759,20 @@ private static List FindEngines(string enginesDir) { // find engine path based on repo directory configs // @handled @logs - private static string FindEnginesDirectory(string clonePath) { + private static string FindEnginesDirectory(string netFolder, string clonePath) + { // determine repo version based on directory availability string enginesDir = Path.Combine(clonePath, - PyRevitConsts.BinDirName, - PyRevitConsts.BinEnginesDirName); - if (!CommonUtils.VerifyPath(enginesDir)) { + PyRevitConsts.BinDirName, + netFolder, + PyRevitConsts.BinEnginesDirName); + if (!CommonUtils.VerifyPath(enginesDir)) + { enginesDir = Path.Combine(clonePath, - PyRevitConsts.LibDirName, - PyRevitConsts.ModuleDirName, - PyRevitConsts.ModuleLoaderDirName, - PyRevitConsts.ModuleLegacyAddinDirName); + PyRevitConsts.LibDirName, + PyRevitConsts.ModuleDirName, + PyRevitConsts.ModuleLoaderDirName, + PyRevitConsts.ModuleLegacyAddinDirName); if (!CommonUtils.VerifyPath(enginesDir)) throw new pyRevitInvalidGitCloneException(clonePath); } diff --git a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitClones.cs b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitClones.cs index 83633bcd4..803892391 100644 --- a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitClones.cs +++ b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitClones.cs @@ -239,7 +239,7 @@ public static void DeployFromRepo(string cloneName, } // cleanup completed, now baloon up the exception - throw ex; + throw; } } else @@ -286,7 +286,7 @@ public static void DeployFromImage(string cloneName, logger.Info("Downloading package \"{0}\"", imageSource); logger.Debug("Downloading package \"{0}\" to \"{1}\"", imageSource, pkgDest); imageFilePath = - CommonUtils.DownloadFile(imageSource, pkgDest, progressToken: Path.GetFileName(imageSource)); + CommonUtils.DownloadFile(imageSource, pkgDest); logger.Debug("Downloaded to \"{0}\"", imageFilePath); } catch (Exception ex) { @@ -373,7 +373,7 @@ public static void DeployFromImage(string cloneName, } // cleanup completed, now baloon up the exception - throw ex; + throw; } // register the clone @@ -411,7 +411,7 @@ private static void VerifyAndRegisterClone(string cloneName, string clonePath) { } // cleanup completed, now baloon up the exception - throw ex; + throw; } } diff --git a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitConsts.cs b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitConsts.cs index 1585aeed4..bb5b7ea4c 100644 --- a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitConsts.cs +++ b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitConsts.cs @@ -15,11 +15,11 @@ public static class PyRevitConsts { public const string DefaultCloneRemoteName = PyRevitLabsConsts.DefaultRemoteName; public static string DefaultCopyInstallName = string.Format("{0}Copy", PyRevitLabsConsts.ProductName); - public static string ExtensionsDefinitionFileUri = string.Format(@"https://github.com/eirannejad/pyRevit/raw/{0}/extensions/{1}", PyRevitLabsConsts.TragetBranch, ExtensionsDefFileName); + public static string ExtensionsDefinitionFileUri = string.Format(@"https://github.com/pyrevitlabs/pyRevit/raw/{0}/extensions/{1}", PyRevitLabsConsts.TragetBranch, ExtensionsDefFileName); // cli - public const string CLIHelpUrl = @"https://github.com/eirannejad/pyRevit/blob/cli-v{0}/docs/cli.md"; - public const string CLIHelpUrlDev = @"https://github.com/eirannejad/pyRevit/blob/develop/docs/cli.md"; + public const string CLIHelpUrl = @"https://github.com/pyrevitlabs/pyRevit/blob/cli-v{0}/docs/cli.md"; + public const string CLIHelpUrlDev = @"https://github.com/pyrevitlabs/pyRevit/blob/develop/docs/cli.md"; // api public const string ReleasePrefix = "v"; @@ -28,6 +28,7 @@ public static class PyRevitConsts { // directories and files public const string BinDirName = "bin"; public const string BinEnginesDirName = "engines"; + public const string BinCEnginesDirName = "cengines"; public const string DevDirName = "dev"; public const string DocsDirName = "docs"; public const string ExtensionsDirName = "extensions"; @@ -41,6 +42,9 @@ public static class PyRevitConsts { public const string ReleaseDirName = "release"; public const string SitePackagesDirName = "site-packages"; public const string PyRevitfileFilename = "PyRevitfile"; + + public const string NetFxFolder = "netfx"; + public const string NetCoreFolder = "netcore"; // clones public const string DeployFromImageConfigsFilename = ".pyrevitargs"; diff --git a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitEngine.cs b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitEngine.cs index d281b25a6..d085882a9 100644 --- a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitEngine.cs +++ b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitEngine.cs @@ -38,6 +38,7 @@ public PyRevitEngine(string id, PyRevitEngineVersion engineVer, bool runtime, string enginePath, + bool isNetCore, string assemblyName = PyRevitConsts.LegacyEngineDllName, string kernelName = "", string engineDescription = "", @@ -46,6 +47,7 @@ public PyRevitEngine(string id, Version = engineVer; Runtime = runtime; Path = enginePath; + IsNetCore = isNetCore; AssemblyName = assemblyName; KernelName = kernelName; Description = engineDescription; @@ -65,6 +67,7 @@ public override string ToString() { public string AssemblyName { get; private set; } public string KernelName { get; private set; } public bool IsDefault { get; private set; } + public bool IsNetCore { get; private set; } public string AssemblyPath { get { diff --git a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitReleases.cs b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitReleases.cs index 5f51ccaf8..63f6b104f 100644 --- a/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitReleases.cs +++ b/dev/pyRevitLabs/pyRevitLabs.PyRevit/PyRevitReleases.cs @@ -18,10 +18,10 @@ public static class PyRevitReleases { public static PyRevitRelease GetLatestRelease(bool includePreRelease = false) { if (includePreRelease) return GetReleases().Where(r => r.IsPyRevitRelease) - .OrderByDescending(r => r.Version).ToList().First(); + .OrderByDescending(r => r.Version).ToList().FirstOrDefault(); else return GetReleases().Where(r => r.IsPyRevitRelease && !r.PreRelease) - .OrderByDescending(r => r.Version).ToList().First(); + .OrderByDescending(r => r.Version).ToList().FirstOrDefault(); } // Find releases diff --git a/dev/pyRevitLabs/pyRevitLabs.PyRevit/pyRevitLabs.PyRevit.csproj b/dev/pyRevitLabs/pyRevitLabs.PyRevit/pyRevitLabs.PyRevit.csproj index d40d5264a..5370f8149 100644 --- a/dev/pyRevitLabs/pyRevitLabs.PyRevit/pyRevitLabs.PyRevit.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.PyRevit/pyRevitLabs.PyRevit.csproj @@ -1,20 +1,25 @@  + + true + true + + x64 + net48;net8.0-windows + + + - - - - - - - - + + + + @@ -24,6 +29,6 @@ - + diff --git a/dev/pyRevitLabs/pyRevitLabs.TargetApps.AutoCAD/pyRevitLabs.TargetApps.AutoCAD.csproj b/dev/pyRevitLabs/pyRevitLabs.TargetApps.AutoCAD/pyRevitLabs.TargetApps.AutoCAD.csproj index a5b9e0e7b..e5926acef 100644 --- a/dev/pyRevitLabs/pyRevitLabs.TargetApps.AutoCAD/pyRevitLabs.TargetApps.AutoCAD.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.TargetApps.AutoCAD/pyRevitLabs.TargetApps.AutoCAD.csproj @@ -1,2 +1,6 @@  + + x64 + net48;net8.0-windows + \ No newline at end of file diff --git a/dev/pyRevitLabs/pyRevitLabs.TargetApps.Navisworks/pyRevitLabs.TargetApps.Navisworks.csproj b/dev/pyRevitLabs/pyRevitLabs.TargetApps.Navisworks/pyRevitLabs.TargetApps.Navisworks.csproj index a5b9e0e7b..e5926acef 100644 --- a/dev/pyRevitLabs/pyRevitLabs.TargetApps.Navisworks/pyRevitLabs.TargetApps.Navisworks.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.TargetApps.Navisworks/pyRevitLabs.TargetApps.Navisworks.csproj @@ -1,2 +1,6 @@  + + x64 + net48;net8.0-windows + \ No newline at end of file diff --git a/dev/pyRevitLabs/pyRevitLabs.TargetApps.Revit/RevitModelFile.cs b/dev/pyRevitLabs/pyRevitLabs.TargetApps.Revit/RevitModelFile.cs index 0897e7560..c28ad7625 100644 --- a/dev/pyRevitLabs/pyRevitLabs.TargetApps.Revit/RevitModelFile.cs +++ b/dev/pyRevitLabs/pyRevitLabs.TargetApps.Revit/RevitModelFile.cs @@ -168,7 +168,7 @@ private void ProcessBasicFileInfo(IEnumerable basicInfoDataLines) { RevitProduct = revitProduct; } - // Last Save Path: C:\Users\eirannejad\Desktop\Project1.rvt + // Last Save Path: C:\Users\pyrevitlabs\Desktop\Project1.rvt match = buildFieldRegex("Last Save Path: ", "lastpath").Match(line); if (match.Success) { var path = match.Groups["lastpath"].Value; diff --git a/dev/pyRevitLabs/pyRevitLabs.TargetApps.Revit/pyRevitLabs.TargetApps.Revit.csproj b/dev/pyRevitLabs/pyRevitLabs.TargetApps.Revit/pyRevitLabs.TargetApps.Revit.csproj index 92598022b..aa84edfe8 100644 --- a/dev/pyRevitLabs/pyRevitLabs.TargetApps.Revit/pyRevitLabs.TargetApps.Revit.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.TargetApps.Revit/pyRevitLabs.TargetApps.Revit.csproj @@ -1,11 +1,16 @@  + + x64 + net48;net8.0-windows + + - + diff --git a/dev/pyRevitLabs/pyRevitLabs.UnitTests/pyRevitLabs.UnitTests.csproj b/dev/pyRevitLabs/pyRevitLabs.UnitTests/pyRevitLabs.UnitTests.csproj index a51f39436..b6275ef2c 100644 --- a/dev/pyRevitLabs/pyRevitLabs.UnitTests/pyRevitLabs.UnitTests.csproj +++ b/dev/pyRevitLabs/pyRevitLabs.UnitTests/pyRevitLabs.UnitTests.csproj @@ -1,6 +1,8 @@  + x64 UnitTest + net48;net8.0-windows @@ -9,8 +11,8 @@ - - + + diff --git a/dev/pyRevitLabs/pyRevitLabs.sln b/dev/pyRevitLabs/pyRevitLabs.sln index b837b2168..8a90951a0 100644 --- a/dev/pyRevitLabs/pyRevitLabs.sln +++ b/dev/pyRevitLabs/pyRevitLabs.sln @@ -53,66 +53,66 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLabs.PyRevit.Runtime EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU + Debug|x64 = Debug|x64 + Release|x64 = Release|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {C5A03112-6EE1-415F-B53D-5D732D9F47AD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {C5A03112-6EE1-415F-B53D-5D732D9F47AD}.Debug|Any CPU.Build.0 = Debug|Any CPU - {C5A03112-6EE1-415F-B53D-5D732D9F47AD}.Release|Any CPU.ActiveCfg = Release|Any CPU - {C5A03112-6EE1-415F-B53D-5D732D9F47AD}.Release|Any CPU.Build.0 = Release|Any CPU - {15E9A99D-11E3-4D46-B333-79A10427F682}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {15E9A99D-11E3-4D46-B333-79A10427F682}.Debug|Any CPU.Build.0 = Debug|Any CPU - {15E9A99D-11E3-4D46-B333-79A10427F682}.Release|Any CPU.ActiveCfg = Release|Any CPU - {15E9A99D-11E3-4D46-B333-79A10427F682}.Release|Any CPU.Build.0 = Release|Any CPU - {614720BA-C0E3-4199-9A5E-D2468FFCBFE5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {614720BA-C0E3-4199-9A5E-D2468FFCBFE5}.Debug|Any CPU.Build.0 = Debug|Any CPU - {614720BA-C0E3-4199-9A5E-D2468FFCBFE5}.Release|Any CPU.ActiveCfg = Release|Any CPU - {614720BA-C0E3-4199-9A5E-D2468FFCBFE5}.Release|Any CPU.Build.0 = Release|Any CPU - {ED0FB7A2-E4A8-4490-A020-73140BFBCE0B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {ED0FB7A2-E4A8-4490-A020-73140BFBCE0B}.Debug|Any CPU.Build.0 = Debug|Any CPU - {ED0FB7A2-E4A8-4490-A020-73140BFBCE0B}.Release|Any CPU.ActiveCfg = Release|Any CPU - {ED0FB7A2-E4A8-4490-A020-73140BFBCE0B}.Release|Any CPU.Build.0 = Release|Any CPU - {57323698-75AF-4345-827D-2E625A56CBF2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {57323698-75AF-4345-827D-2E625A56CBF2}.Debug|Any CPU.Build.0 = Debug|Any CPU - {57323698-75AF-4345-827D-2E625A56CBF2}.Release|Any CPU.ActiveCfg = Release|Any CPU - {57323698-75AF-4345-827D-2E625A56CBF2}.Release|Any CPU.Build.0 = Release|Any CPU - {0C382E44-C594-4F08-9469-20C0D25BA581}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {0C382E44-C594-4F08-9469-20C0D25BA581}.Debug|Any CPU.Build.0 = Debug|Any CPU - {0C382E44-C594-4F08-9469-20C0D25BA581}.Release|Any CPU.ActiveCfg = Release|Any CPU - {0C382E44-C594-4F08-9469-20C0D25BA581}.Release|Any CPU.Build.0 = Release|Any CPU - {9561311E-A02A-4D5F-BD22-64258941BF2E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {9561311E-A02A-4D5F-BD22-64258941BF2E}.Debug|Any CPU.Build.0 = Debug|Any CPU - {9561311E-A02A-4D5F-BD22-64258941BF2E}.Release|Any CPU.ActiveCfg = Release|Any CPU - {9561311E-A02A-4D5F-BD22-64258941BF2E}.Release|Any CPU.Build.0 = Release|Any CPU - {269FE01F-093A-4774-8017-FEFC2342ABF5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {269FE01F-093A-4774-8017-FEFC2342ABF5}.Debug|Any CPU.Build.0 = Debug|Any CPU - {269FE01F-093A-4774-8017-FEFC2342ABF5}.Release|Any CPU.ActiveCfg = Release|Any CPU - {269FE01F-093A-4774-8017-FEFC2342ABF5}.Release|Any CPU.Build.0 = Release|Any CPU - {4672A022-5855-4C70-B81E-9E1109BD7B6D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {4672A022-5855-4C70-B81E-9E1109BD7B6D}.Debug|Any CPU.Build.0 = Debug|Any CPU - {4672A022-5855-4C70-B81E-9E1109BD7B6D}.Release|Any CPU.ActiveCfg = Release|Any CPU - {4672A022-5855-4C70-B81E-9E1109BD7B6D}.Release|Any CPU.Build.0 = Release|Any CPU - {595C5FC1-EA26-47A6-B78F-3A04D222963D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {595C5FC1-EA26-47A6-B78F-3A04D222963D}.Debug|Any CPU.Build.0 = Debug|Any CPU - {595C5FC1-EA26-47A6-B78F-3A04D222963D}.Release|Any CPU.ActiveCfg = Release|Any CPU - {595C5FC1-EA26-47A6-B78F-3A04D222963D}.Release|Any CPU.Build.0 = Release|Any CPU - {495994B5-044C-4B59-BD1D-D05683B443E5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {495994B5-044C-4B59-BD1D-D05683B443E5}.Debug|Any CPU.Build.0 = Debug|Any CPU - {495994B5-044C-4B59-BD1D-D05683B443E5}.Release|Any CPU.ActiveCfg = Release|Any CPU - {495994B5-044C-4B59-BD1D-D05683B443E5}.Release|Any CPU.Build.0 = Release|Any CPU - {D4BAD33B-FAEE-4D57-A3F6-E2BBDCDE8AE6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {D4BAD33B-FAEE-4D57-A3F6-E2BBDCDE8AE6}.Debug|Any CPU.Build.0 = Debug|Any CPU - {D4BAD33B-FAEE-4D57-A3F6-E2BBDCDE8AE6}.Release|Any CPU.ActiveCfg = Release|Any CPU - {D4BAD33B-FAEE-4D57-A3F6-E2BBDCDE8AE6}.Release|Any CPU.Build.0 = Release|Any CPU - {E33FE30C-7DA3-4A8C-B7B9-C7B1A8F73E6A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {E33FE30C-7DA3-4A8C-B7B9-C7B1A8F73E6A}.Debug|Any CPU.Build.0 = Debug|Any CPU - {E33FE30C-7DA3-4A8C-B7B9-C7B1A8F73E6A}.Release|Any CPU.ActiveCfg = Release|Any CPU - {E33FE30C-7DA3-4A8C-B7B9-C7B1A8F73E6A}.Release|Any CPU.Build.0 = Release|Any CPU - {B239FF1F-F32A-4828-87B8-E5DAC6809567}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {B239FF1F-F32A-4828-87B8-E5DAC6809567}.Debug|Any CPU.Build.0 = Debug|Any CPU - {B239FF1F-F32A-4828-87B8-E5DAC6809567}.Release|Any CPU.ActiveCfg = Release|Any CPU - {B239FF1F-F32A-4828-87B8-E5DAC6809567}.Release|Any CPU.Build.0 = Release|Any CPU + {C5A03112-6EE1-415F-B53D-5D732D9F47AD}.Debug|x64.ActiveCfg = Debug|x64 + {C5A03112-6EE1-415F-B53D-5D732D9F47AD}.Debug|x64.Build.0 = Debug|x64 + {C5A03112-6EE1-415F-B53D-5D732D9F47AD}.Release|x64.ActiveCfg = Release|x64 + {C5A03112-6EE1-415F-B53D-5D732D9F47AD}.Release|x64.Build.0 = Release|x64 + {15E9A99D-11E3-4D46-B333-79A10427F682}.Debug|x64.ActiveCfg = Debug|x64 + {15E9A99D-11E3-4D46-B333-79A10427F682}.Debug|x64.Build.0 = Debug|x64 + {15E9A99D-11E3-4D46-B333-79A10427F682}.Release|x64.ActiveCfg = Release|x64 + {15E9A99D-11E3-4D46-B333-79A10427F682}.Release|x64.Build.0 = Release|x64 + {614720BA-C0E3-4199-9A5E-D2468FFCBFE5}.Debug|x64.ActiveCfg = Debug|x64 + {614720BA-C0E3-4199-9A5E-D2468FFCBFE5}.Debug|x64.Build.0 = Debug|x64 + {614720BA-C0E3-4199-9A5E-D2468FFCBFE5}.Release|x64.ActiveCfg = Release|x64 + {614720BA-C0E3-4199-9A5E-D2468FFCBFE5}.Release|x64.Build.0 = Release|x64 + {ED0FB7A2-E4A8-4490-A020-73140BFBCE0B}.Debug|x64.ActiveCfg = Debug|x64 + {ED0FB7A2-E4A8-4490-A020-73140BFBCE0B}.Debug|x64.Build.0 = Debug|x64 + {ED0FB7A2-E4A8-4490-A020-73140BFBCE0B}.Release|x64.ActiveCfg = Release|x64 + {ED0FB7A2-E4A8-4490-A020-73140BFBCE0B}.Release|x64.Build.0 = Release|x64 + {57323698-75AF-4345-827D-2E625A56CBF2}.Debug|x64.ActiveCfg = Debug|x64 + {57323698-75AF-4345-827D-2E625A56CBF2}.Debug|x64.Build.0 = Debug|x64 + {57323698-75AF-4345-827D-2E625A56CBF2}.Release|x64.ActiveCfg = Release|x64 + {57323698-75AF-4345-827D-2E625A56CBF2}.Release|x64.Build.0 = Release|x64 + {0C382E44-C594-4F08-9469-20C0D25BA581}.Debug|x64.ActiveCfg = Debug|x64 + {0C382E44-C594-4F08-9469-20C0D25BA581}.Debug|x64.Build.0 = Debug|x64 + {0C382E44-C594-4F08-9469-20C0D25BA581}.Release|x64.ActiveCfg = Release|x64 + {0C382E44-C594-4F08-9469-20C0D25BA581}.Release|x64.Build.0 = Release|x64 + {9561311E-A02A-4D5F-BD22-64258941BF2E}.Debug|x64.ActiveCfg = Debug|x64 + {9561311E-A02A-4D5F-BD22-64258941BF2E}.Debug|x64.Build.0 = Debug|x64 + {9561311E-A02A-4D5F-BD22-64258941BF2E}.Release|x64.ActiveCfg = Release|x64 + {9561311E-A02A-4D5F-BD22-64258941BF2E}.Release|x64.Build.0 = Release|x64 + {269FE01F-093A-4774-8017-FEFC2342ABF5}.Debug|x64.ActiveCfg = Debug|x64 + {269FE01F-093A-4774-8017-FEFC2342ABF5}.Debug|x64.Build.0 = Debug|x64 + {269FE01F-093A-4774-8017-FEFC2342ABF5}.Release|x64.ActiveCfg = Release|x64 + {269FE01F-093A-4774-8017-FEFC2342ABF5}.Release|x64.Build.0 = Release|x64 + {4672A022-5855-4C70-B81E-9E1109BD7B6D}.Debug|x64.ActiveCfg = Debug|x64 + {4672A022-5855-4C70-B81E-9E1109BD7B6D}.Debug|x64.Build.0 = Debug|x64 + {4672A022-5855-4C70-B81E-9E1109BD7B6D}.Release|x64.ActiveCfg = Release|x64 + {4672A022-5855-4C70-B81E-9E1109BD7B6D}.Release|x64.Build.0 = Release|x64 + {595C5FC1-EA26-47A6-B78F-3A04D222963D}.Debug|x64.ActiveCfg = Debug|x64 + {595C5FC1-EA26-47A6-B78F-3A04D222963D}.Debug|x64.Build.0 = Debug|x64 + {595C5FC1-EA26-47A6-B78F-3A04D222963D}.Release|x64.ActiveCfg = Release|x64 + {595C5FC1-EA26-47A6-B78F-3A04D222963D}.Release|x64.Build.0 = Release|x64 + {495994B5-044C-4B59-BD1D-D05683B443E5}.Debug|x64.ActiveCfg = Debug|x64 + {495994B5-044C-4B59-BD1D-D05683B443E5}.Debug|x64.Build.0 = Debug|x64 + {495994B5-044C-4B59-BD1D-D05683B443E5}.Release|x64.ActiveCfg = Release|x64 + {495994B5-044C-4B59-BD1D-D05683B443E5}.Release|x64.Build.0 = Release|x64 + {D4BAD33B-FAEE-4D57-A3F6-E2BBDCDE8AE6}.Debug|x64.ActiveCfg = Debug|x64 + {D4BAD33B-FAEE-4D57-A3F6-E2BBDCDE8AE6}.Debug|x64.Build.0 = Debug|x64 + {D4BAD33B-FAEE-4D57-A3F6-E2BBDCDE8AE6}.Release|x64.ActiveCfg = Release|x64 + {D4BAD33B-FAEE-4D57-A3F6-E2BBDCDE8AE6}.Release|x64.Build.0 = Release|x64 + {E33FE30C-7DA3-4A8C-B7B9-C7B1A8F73E6A}.Debug|x64.ActiveCfg = Debug|x64 + {E33FE30C-7DA3-4A8C-B7B9-C7B1A8F73E6A}.Debug|x64.Build.0 = Debug|x64 + {E33FE30C-7DA3-4A8C-B7B9-C7B1A8F73E6A}.Release|x64.ActiveCfg = Release|x64 + {E33FE30C-7DA3-4A8C-B7B9-C7B1A8F73E6A}.Release|x64.Build.0 = Release|x64 + {B239FF1F-F32A-4828-87B8-E5DAC6809567}.Debug|x64.ActiveCfg = Debug|x64 + {B239FF1F-F32A-4828-87B8-E5DAC6809567}.Debug|x64.Build.0 = Debug|x64 + {B239FF1F-F32A-4828-87B8-E5DAC6809567}.Release|x64.ActiveCfg = Release|x64 + {B239FF1F-F32A-4828-87B8-E5DAC6809567}.Release|x64.Build.0 = Release|x64 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/dev/pyRevitLoader/Directory.Build.props b/dev/pyRevitLoader/Directory.Build.props index 480d7fb5b..324f3faea 100644 --- a/dev/pyRevitLoader/Directory.Build.props +++ b/dev/pyRevitLoader/Directory.Build.props @@ -1,10 +1,13 @@ - - - 2022 - $(PyRevitDevLibsDir)\IronPython\ + true + true + true + net48;net8.0-windows + false + + \ No newline at end of file diff --git a/dev/pyRevitLoader/Directory.Build.targets b/dev/pyRevitLoader/Directory.Build.targets index f95d40e97..d4de06201 100644 --- a/dev/pyRevitLoader/Directory.Build.targets +++ b/dev/pyRevitLoader/Directory.Build.targets @@ -1,50 +1,45 @@ + + + + $(PyRevitEnginesDir)\$(IronPythonVersion)\$(AssemblyName).dll + + + + + + - - + + - - - - - - - - - - - - + + + - - - - - - - + + + + + + + - + - - - - - - + - + - + + - - \ No newline at end of file diff --git a/dev/pyRevitLoader/Loader.Common.props b/dev/pyRevitLoader/Loader.Common.props deleted file mode 100644 index 0d9d53162..000000000 --- a/dev/pyRevitLoader/Loader.Common.props +++ /dev/null @@ -1,18 +0,0 @@ - - - - pyRevitLoader - pyRevitLoader - bin\$(Configuration)\$(IronPythonVersion)\Loader - obj\$(Configuration)\$(IronPythonVersion)\Loader - $(ProjectDir)$(OutputPath) - - - - pyRevitRunner - pyRevitRunner - bin\$(Configuration)\$(IronPythonVersion)\Runner - obj\$(Configuration)\$(IronPythonVersion)\Runner - $(ProjectDir)$(OutputPath) - - \ No newline at end of file diff --git a/dev/pyRevitLoader/Source/PyRevitLoaderApplication.cs b/dev/pyRevitLoader/Source/PyRevitLoaderApplication.cs index 2d270bbc4..76fe50d95 100644 --- a/dev/pyRevitLoader/Source/PyRevitLoaderApplication.cs +++ b/dev/pyRevitLoader/Source/PyRevitLoaderApplication.cs @@ -22,7 +22,17 @@ Result IExternalApplication.OnStartup(UIControlledApplication application) { // load all engine assemblies // this is to ensure pyRevit is loaded on its own assemblies foreach (var engineDll in Directory.GetFiles(LoaderPath, "*.dll")) - Assembly.LoadFrom(engineDll); + { + try + { + Assembly.LoadFrom(engineDll); + } + catch + { + //// + } + } + return ExecuteStartupScript(application); } diff --git a/dev/pyRevitLoader/Source/ScriptExecutor.cs b/dev/pyRevitLoader/Source/ScriptExecutor.cs index 0ffaae98f..10ecc9248 100644 --- a/dev/pyRevitLoader/Source/ScriptExecutor.cs +++ b/dev/pyRevitLoader/Source/ScriptExecutor.cs @@ -9,6 +9,7 @@ using Autodesk.Revit.UI; using System.Collections.Generic; using System.Reflection; +using System.Windows.Forms; using IronPython.Runtime.Operations; namespace PyRevitLoader { @@ -36,7 +37,7 @@ public ScriptExecutor(UIApplication uiApplication, bool fullFrame = false) { public static string EngineVersion { get { var assmVersion = Assembly.GetAssembly(typeof(ScriptExecutor)).GetName().Version; - return string.Format("{0}{1}{2}", assmVersion.Minor, assmVersion.Build, assmVersion.Revision); + return string.Format("{0}{1}{2}", assmVersion.Major, assmVersion.Minor, assmVersion.Build); } } @@ -148,6 +149,7 @@ public void AddEmbeddedLib(ScriptEngine engine) { #else string resName = string.Format("python_{0}_lib.zip", EngineVersion); #endif + var resQuery = from name in asm.GetManifestResourceNames() where name.ToLowerInvariant().EndsWith(resName) select name; diff --git a/dev/pyRevitLoader/pyRevitLoader.2711PR.csproj b/dev/pyRevitLoader/pyRevitLoader.2711PR.csproj deleted file mode 100644 index 234adaa58..000000000 --- a/dev/pyRevitLoader/pyRevitLoader.2711PR.csproj +++ /dev/null @@ -1,11 +0,0 @@ - - - $(DefineConstants);PYREVITLABS_ENGINE - IPY2711PR - true - python_2711pr_lib.zip - $(RevitVersion).2.7.11 - - - - \ No newline at end of file diff --git a/dev/pyRevitLoader/pyRevitLoader.2712PR/pyRevitLoader.2712PR.csproj b/dev/pyRevitLoader/pyRevitLoader.2712PR/pyRevitLoader.2712PR.csproj new file mode 100644 index 000000000..c3eb3cbcc --- /dev/null +++ b/dev/pyRevitLoader/pyRevitLoader.2712PR/pyRevitLoader.2712PR.csproj @@ -0,0 +1,11 @@ + + + pyRevitLoader + pyRevitLoader + + $(DefineConstants);PYREVITLABS_ENGINE + IPY2712PR + python_2712pr_lib.zip + 2.7.12 + + \ No newline at end of file diff --git a/dev/pyRevitLoader/pyRevitLoader.340PR.csproj b/dev/pyRevitLoader/pyRevitLoader.340PR/pyRevitLoader.340PR.csproj similarity index 65% rename from dev/pyRevitLoader/pyRevitLoader.340PR.csproj rename to dev/pyRevitLoader/pyRevitLoader.340PR/pyRevitLoader.340PR.csproj index 70f99454b..36a17b307 100644 --- a/dev/pyRevitLoader/pyRevitLoader.340PR.csproj +++ b/dev/pyRevitLoader/pyRevitLoader.340PR/pyRevitLoader.340PR.csproj @@ -1,11 +1,11 @@  + pyRevitLoader + pyRevitLoader + $(DefineConstants);PYREVITLABS_ENGINE IPY340PR - true python_340pr_lib.zip - $(RevitVersion).3.4.0 + 3.4.0 - - \ No newline at end of file diff --git a/dev/pyRevitLoader/pyRevitLoader.sln b/dev/pyRevitLoader/pyRevitLoader.sln index b688dcece..6291b3c82 100644 --- a/dev/pyRevitLoader/pyRevitLoader.sln +++ b/dev/pyRevitLoader/pyRevitLoader.sln @@ -7,36 +7,36 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Loaders", "Loaders", "{5D24 EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Runners", "Runners", "{74C50D6F-68E5-411B-A781-800BC60C9ECF}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLoader.2711PR", "pyRevitLoader.2711PR.csproj", "{B4999A6B-E890-4514-9FEF-4FC5C0332C89}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLoader.2712PR", "pyRevitLoader.2712PR\pyRevitLoader.2712PR.csproj", "{B4999A6B-E890-4514-9FEF-4FC5C0332C89}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitRunner.2711PR", "pyRevitRunner.2711PR.csproj", "{9DB5A32B-7C8A-463B-8DB5-DFD992ADED8A}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitRunner.2712PR", "pyRevitRunner.2712PR\pyRevitRunner.2712PR.csproj", "{9DB5A32B-7C8A-463B-8DB5-DFD992ADED8A}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLoader.340PR", "pyRevitLoader.340PR.csproj", "{6FF6322E-2DC3-4D58-B7C7-078704358916}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitLoader.340PR", "pyRevitLoader.340PR/pyRevitLoader.340PR.csproj", "{6FF6322E-2DC3-4D58-B7C7-078704358916}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitRunner340PR", "pyRevitRunner340PR.csproj", "{2961C0FE-C1BC-4FC5-AC31-137C59A0E436}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "pyRevitRunner.340PR", "pyRevitRunner.340PR/pyRevitRunner.340PR.csproj", "{2961C0FE-C1BC-4FC5-AC31-137C59A0E436}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU + Debug|x64 = Debug|x64 + Release|x64 = Release|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution - {B4999A6B-E890-4514-9FEF-4FC5C0332C89}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {B4999A6B-E890-4514-9FEF-4FC5C0332C89}.Debug|Any CPU.Build.0 = Debug|Any CPU - {B4999A6B-E890-4514-9FEF-4FC5C0332C89}.Release|Any CPU.ActiveCfg = Release|Any CPU - {B4999A6B-E890-4514-9FEF-4FC5C0332C89}.Release|Any CPU.Build.0 = Release|Any CPU - {9DB5A32B-7C8A-463B-8DB5-DFD992ADED8A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {9DB5A32B-7C8A-463B-8DB5-DFD992ADED8A}.Debug|Any CPU.Build.0 = Debug|Any CPU - {9DB5A32B-7C8A-463B-8DB5-DFD992ADED8A}.Release|Any CPU.ActiveCfg = Release|Any CPU - {9DB5A32B-7C8A-463B-8DB5-DFD992ADED8A}.Release|Any CPU.Build.0 = Release|Any CPU - {6FF6322E-2DC3-4D58-B7C7-078704358916}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {6FF6322E-2DC3-4D58-B7C7-078704358916}.Debug|Any CPU.Build.0 = Debug|Any CPU - {6FF6322E-2DC3-4D58-B7C7-078704358916}.Release|Any CPU.ActiveCfg = Release|Any CPU - {6FF6322E-2DC3-4D58-B7C7-078704358916}.Release|Any CPU.Build.0 = Release|Any CPU - {2961C0FE-C1BC-4FC5-AC31-137C59A0E436}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {2961C0FE-C1BC-4FC5-AC31-137C59A0E436}.Debug|Any CPU.Build.0 = Debug|Any CPU - {2961C0FE-C1BC-4FC5-AC31-137C59A0E436}.Release|Any CPU.ActiveCfg = Release|Any CPU - {2961C0FE-C1BC-4FC5-AC31-137C59A0E436}.Release|Any CPU.Build.0 = Release|Any CPU + {B4999A6B-E890-4514-9FEF-4FC5C0332C89}.Debug|x64.ActiveCfg = Debug|x64 + {B4999A6B-E890-4514-9FEF-4FC5C0332C89}.Debug|x64.Build.0 = Debug|x64 + {B4999A6B-E890-4514-9FEF-4FC5C0332C89}.Release|x64.ActiveCfg = Release|x64 + {B4999A6B-E890-4514-9FEF-4FC5C0332C89}.Release|x64.Build.0 = Release|x64 + {9DB5A32B-7C8A-463B-8DB5-DFD992ADED8A}.Debug|x64.ActiveCfg = Debug|x64 + {9DB5A32B-7C8A-463B-8DB5-DFD992ADED8A}.Debug|x64.Build.0 = Debug|x64 + {9DB5A32B-7C8A-463B-8DB5-DFD992ADED8A}.Release|x64.ActiveCfg = Release|x64 + {9DB5A32B-7C8A-463B-8DB5-DFD992ADED8A}.Release|x64.Build.0 = Release|x64 + {6FF6322E-2DC3-4D58-B7C7-078704358916}.Debug|x64.ActiveCfg = Debug|x64 + {6FF6322E-2DC3-4D58-B7C7-078704358916}.Debug|x64.Build.0 = Debug|x64 + {6FF6322E-2DC3-4D58-B7C7-078704358916}.Release|x64.ActiveCfg = Release|x64 + {6FF6322E-2DC3-4D58-B7C7-078704358916}.Release|x64.Build.0 = Release|x64 + {2961C0FE-C1BC-4FC5-AC31-137C59A0E436}.Debug|x64.ActiveCfg = Debug|x64 + {2961C0FE-C1BC-4FC5-AC31-137C59A0E436}.Debug|x64.Build.0 = Debug|x64 + {2961C0FE-C1BC-4FC5-AC31-137C59A0E436}.Release|x64.ActiveCfg = Release|x64 + {2961C0FE-C1BC-4FC5-AC31-137C59A0E436}.Release|x64.Build.0 = Release|x64 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/dev/pyRevitLoader/pyRevitRunner.2711PR.csproj b/dev/pyRevitLoader/pyRevitRunner.2711PR.csproj deleted file mode 100644 index 9d5014519..000000000 --- a/dev/pyRevitLoader/pyRevitRunner.2711PR.csproj +++ /dev/null @@ -1,12 +0,0 @@ - - - $(DefineConstants);PYREVITLABS_ENGINE - true - IPY2711PR - true - python_2711pr_lib.zip - $(RevitVersion).2.7.11 - - - - \ No newline at end of file diff --git a/dev/pyRevitLoader/pyRevitRunner.2712PR/pyRevitRunner.2712PR.csproj b/dev/pyRevitLoader/pyRevitRunner.2712PR/pyRevitRunner.2712PR.csproj new file mode 100644 index 000000000..2915e01a3 --- /dev/null +++ b/dev/pyRevitLoader/pyRevitRunner.2712PR/pyRevitRunner.2712PR.csproj @@ -0,0 +1,12 @@ + + + pyRevitRunner + pyRevitRunner + + $(DefineConstants);PYREVITLABS_ENGINE + true + IPY2712PR + python_2712pr_lib.zip + 2.7.12 + + \ No newline at end of file diff --git a/dev/pyRevitLoader/pyRevitRunner340PR.csproj b/dev/pyRevitLoader/pyRevitRunner.340PR/pyRevitRunner.340PR.csproj similarity index 67% rename from dev/pyRevitLoader/pyRevitRunner340PR.csproj rename to dev/pyRevitLoader/pyRevitRunner.340PR/pyRevitRunner.340PR.csproj index c2502c11d..836ed641c 100644 --- a/dev/pyRevitLoader/pyRevitRunner340PR.csproj +++ b/dev/pyRevitLoader/pyRevitRunner.340PR/pyRevitRunner.340PR.csproj @@ -1,12 +1,12 @@ + pyRevitRunner + pyRevitRunner + $(DefineConstants);PYREVITLABS_ENGINE true IPY340PR - true python_340pr_lib.zip - $(RevitVersion).3.4.0 + 3.4.0 - - \ No newline at end of file diff --git a/dev/pyRevitTelemetryServer/go.mod b/dev/pyRevitTelemetryServer/go.mod index 6c125275d..4edb993ee 100644 --- a/dev/pyRevitTelemetryServer/go.mod +++ b/dev/pyRevitTelemetryServer/go.mod @@ -7,20 +7,29 @@ require ( github.com/denisenkom/go-mssqldb v0.11.0 github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815 github.com/go-sql-driver/mysql v1.6.0 - github.com/gofrs/uuid v4.1.0+incompatible + github.com/gofrs/uuid v4.3.1+incompatible github.com/gorilla/mux v1.8.0 github.com/lib/pq v1.10.3 github.com/mattn/go-sqlite3 v1.14.8 github.com/pkg/errors v0.9.1 github.com/satori/go.uuid v1.2.0 - gopkg.in/mgo.v2 v2.0.0-20190816093944-a6b53ec6cb22 + go.mongodb.org/mongo-driver v1.11.1 pkg.re/essentialkaos/ek.v10 v12.32.0+incompatible ) require ( github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe // indirect - golang.org/x/crypto v0.17.0 // indirect + github.com/golang/snappy v0.0.1 // indirect + github.com/klauspost/compress v1.13.6 // indirect + github.com/kr/pretty v0.2.1 // indirect + github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe // indirect + github.com/xdg-go/pbkdf2 v1.0.0 // indirect + github.com/xdg-go/scram v1.1.1 // indirect + github.com/xdg-go/stringprep v1.0.3 // indirect + github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d // indirect + golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d // indirect + golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect + golang.org/x/text v0.3.8 // indirect gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect - gopkg.in/yaml.v2 v2.4.0 // indirect pkg.re/essentialkaos/check.v1 v1.0.0 // indirect ) diff --git a/dev/pyRevitTelemetryServer/go.sum b/dev/pyRevitTelemetryServer/go.sum index a4b997ac3..c73a3022b 100644 --- a/dev/pyRevitTelemetryServer/go.sum +++ b/dev/pyRevitTelemetryServer/go.sum @@ -1,17 +1,27 @@ github.com/asaskevich/govalidator v0.0.0-20210307081110-f21760c49a8d h1:Byv0BzEl3/e6D5CLfI0j/7hiIEtvGVFPCZ7Ei2oq8iQ= github.com/asaskevich/govalidator v0.0.0-20210307081110-f21760c49a8d/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw= +github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= +github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/denisenkom/go-mssqldb v0.11.0 h1:9rHa233rhdOyrz2GcP9NM+gi2psgJZ4GWDpL/7ND8HI= github.com/denisenkom/go-mssqldb v0.11.0/go.mod h1:xbL0rPBG9cCiLr28tMa8zpbdarY27NDyej4t/EjAShU= github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815 h1:bWDMxwH3px2JBh6AyO7hdCn/PkvCZXii8TGj7sbtEbQ= github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE= github.com/go-sql-driver/mysql v1.6.0 h1:BCTh4TKNUYmOmMUcQ3IipzF5prigylS7XXjEkfCHuOE= github.com/go-sql-driver/mysql v1.6.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= -github.com/gofrs/uuid v4.1.0+incompatible h1:sIa2eCvUTwgjbqXrPLfNwUf9S3i3mpH1O1atV+iL/Wk= -github.com/gofrs/uuid v4.1.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= +github.com/gofrs/uuid v4.3.1+incompatible h1:0/KbAdpx3UXAx1kEOWHJeOkpbgRFGHVgv+CFIY7dBJI= +github.com/gofrs/uuid v4.3.1+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe h1:lXe2qZdvpiX5WZkZR4hgp4KJVfY3nMkvmwbVkpv1rVY= github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe/go.mod h1:8vg3r2VgvsThLBIFL93Qb5yWzgyZWhEmBwUJWevAkK0= +github.com/golang/snappy v0.0.1 h1:Qgr9rKW7uDUkrbSmQeiDsGa8SjGyCOGtuasMWwvp2P4= +github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= +github.com/google/go-cmp v0.5.2 h1:X2ev0eStA3AbceY54o37/0PQ/UWqKEiiO2dKL5OPaFM= +github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= +github.com/klauspost/compress v1.13.6 h1:P76CopJELS0TiO2mebmnzgWaajssP/EszplttgQxcgc= +github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk= +github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pretty v0.2.1 h1:Fmg33tUaq4/8ym9TJN1x7sLJnHVwhP33CNkpYV/7rwI= github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= @@ -21,57 +31,72 @@ github.com/lib/pq v1.10.3 h1:v9QZf2Sn6AmjXtQeFpdoq/eaNtYP6IN+7lcrygsIAtg= github.com/lib/pq v1.10.3/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/mattn/go-sqlite3 v1.14.8 h1:gDp86IdQsN/xWjIEmr9MF6o9mpksUgh0fu+9ByFxzIU= github.com/mattn/go-sqlite3 v1.14.8/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU= +github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe h1:iruDEfMl2E6fbMZ9s0scYfZQ84/6SPL6zC8ACM2oIL0= +github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe/go.mod h1:wL8QJuTMNUDYhXwkmfOly8iTdp5TEcJFWZD2D7SIkUc= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= +github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= +github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/satori/go.uuid v1.2.0 h1:0uYX9dsZ2yD7q2RtLRtPSdGDWzjeM3TbMJP9utgA0ww= github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= +github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +github.com/stretchr/testify v1.6.1 h1:hDPOHmpOpP40lSULcqw7IrRb/u7w6RpDC9399XyoNd0= +github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/tidwall/pretty v1.0.0 h1:HsD+QiTn7sK6flMKIvNmpqz1qrpP3Ps6jOKIKMooyg4= +github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk= +github.com/xdg-go/pbkdf2 v1.0.0 h1:Su7DPu48wXMwC3bs7MCNG+z4FhcyEuz5dlvchbq0B0c= +github.com/xdg-go/pbkdf2 v1.0.0/go.mod h1:jrpuAogTd400dnrH08LKmI/xc1MbPOebTwRqcT5RDeI= +github.com/xdg-go/scram v1.1.1 h1:VOMT+81stJgXW3CpHyqHN3AXDYIMsx56mEFrB37Mb/E= +github.com/xdg-go/scram v1.1.1/go.mod h1:RaEWvsqvNKKvBPvcKeFjrG2cJqOkHTiyTpzz23ni57g= +github.com/xdg-go/stringprep v1.0.3 h1:kdwGpVNwPFtjs98xCGkHjQtGKh86rDcRZN17QEMCOIs= +github.com/xdg-go/stringprep v1.0.3/go.mod h1:W3f5j4i+9rC0kuIEJL0ky1VpHXQU3ocBgklLGvcBnW8= +github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d h1:splanxYIlg+5LfHAM6xpdFEAYOk8iySO56hMFq6uLyA= +github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d/go.mod h1:rHwXgn7JulP+udvsHwJoVG1YGAP6VLg4y9I5dyZdqmA= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= +go.mongodb.org/mongo-driver v1.11.1 h1:QP0znIRTuL0jf1oBQoAoM0C6ZJfBK4kx0Uumtv1A7w8= +go.mongodb.org/mongo-driver v1.11.1/go.mod h1:s7p5vEtfbeR1gYi6pnj3c3/urpbLv2T5Sfd6Rp2HBB8= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190325154230-a5d413f7728c/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d h1:sK3txAijHtOK88l68nt020reeT1ZdKLIYetKl95FzVY= +golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= -golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= +golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= -golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= -golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20210220032951-036812b2e83c h1:5KslGYwFpkhGh+Q16bwMP3cOontH8FOep7tGV86Y7SQ= +golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 h1:uVc8UZUe6tr40fFVnUP5Oj+veunVezqYl9z7DYw9xzw= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.15.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= -golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= -golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= +golang.org/x/text v0.3.8 h1:nAL+RVCQ9uMn3vJZbV+MRnydTJFPf8qqY42YiA6MrqY= +golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= -golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= +golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= -gopkg.in/mgo.v2 v2.0.0-20190816093944-a6b53ec6cb22 h1:VpOs+IwYnYBaFnrNAeB8UUWtL3vEUnzSCL1nVjPhqrw= -gopkg.in/mgo.v2 v2.0.0-20190816093944-a6b53ec6cb22/go.mod h1:yeKp02qBN3iKW1OzL3MGk2IdtZzaj7SFntXj72NppTA= -gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= -gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= +gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= pkg.re/essentialkaos/check.v1 v1.0.0 h1:2V++mhtm9yHqvW7gtXqcU1D+98vTICGnXmaZloLsZVY= pkg.re/essentialkaos/check.v1 v1.0.0/go.mod h1:B7CoMnGFRnruw7X2Z45kWNvoCW+5OhUsLUm1EBM1aJs= pkg.re/essentialkaos/ek.v10 v12.32.0+incompatible h1:MSnAZgf9WxV/kBpmPpD7md3ajOSXrugvbGIqRd9AWTI= diff --git a/dev/pyRevitTelemetryServer/persistence/mongo.go b/dev/pyRevitTelemetryServer/persistence/mongo.go index 1a076f942..ddbcd93af 100644 --- a/dev/pyRevitTelemetryServer/persistence/mongo.go +++ b/dev/pyRevitTelemetryServer/persistence/mongo.go @@ -1,10 +1,17 @@ package persistence import ( + "context" + "fmt" "pyrevittelemetryserver/cli" + "time" _ "github.com/lib/pq" - "gopkg.in/mgo.v2" + "go.mongodb.org/mongo-driver/bson" + "go.mongodb.org/mongo-driver/mongo" + "go.mongodb.org/mongo-driver/mongo/options" + "go.mongodb.org/mongo-driver/mongo/readpref" + "go.mongodb.org/mongo-driver/x/mongo/driver/connstring" ) type MongoDBConnection struct { @@ -18,25 +25,40 @@ func (w MongoDBConnection) GetType() DBBackend { func (w MongoDBConnection) GetVersion(logger *cli.Logger) string { // parse and grab database name from uri logger.Debug("grabbing db name from connection string") - dialinfo, err := mgo.ParseURL(w.Config.ConnString) - if err != nil { - return "" - } + ctx, cancel := context.WithTimeout(context.Background(), 10*time.Second) + defer cancel() logger.Debug("opening mongodb session") - session, cErr := mgo.DialWithInfo(dialinfo) - if cErr != nil { + client, err := mongo.Connect(ctx, options.Client().ApplyURI(w.Config.ConnString)) + + defer func() { + if err = client.Disconnect(ctx); err != nil { + panic(err) + } + }() + + ctx, cancel = context.WithTimeout(context.Background(), 2*time.Second) + defer cancel() + pErr := client.Ping(ctx, readpref.Primary()) + + if pErr != nil { return "" } - defer session.Close() + // get version from admin DB + // is this the best way of doing this? logger.Debug("getting mongodb version") - buildInfo, vErr := session.BuildInfo() + var commandResult bson.M + command := bson.D{{"buildInfo", 1}} + vErr := client.Database("admin").RunCommand(ctx, command).Decode(&commandResult) + if vErr != nil { return "" } - return buildInfo.Version + // parse version field to get version information + ver := fmt.Sprintf("%+v", commandResult["version"]) + return ver } func (w MongoDBConnection) GetStatus(logger *cli.Logger) ConnectionStatus { @@ -60,38 +82,44 @@ func (w MongoDBConnection) WriteEventTelemetryV2(logrec *EventTelemetryRecordV2, func commitMongo(connStr string, targetCollection string, logrec interface{}, logger *cli.Logger) (*Result, error) { // parse and grab database name from uri - logger.Debug("grabbing db name from connection string") - dialinfo, err := mgo.ParseURL(connStr) + logger.Debug("check connection string") + connStringInfo, err := connstring.ParseAndValidate(connStr) + if err != nil { return nil, err } - logger.Debug("opening mongodb session") - session, cErr := mgo.DialWithInfo(dialinfo) - if cErr != nil { - return nil, cErr + ctx, cancel := context.WithTimeout(context.Background(), 10*time.Second) + defer cancel() + + logger.Debug("opening mongodb session using connection string") + client, err := mongo.Connect(ctx, options.Client().ApplyURI(connStr)) + + if err != nil { + return nil, err } - defer session.Close() - // Optional. Switch the session to a monotonic behavior. - logger.Debug("setting session properties") - session.SetMode(mgo.Monotonic, true) - logger.Trace(session) + logger.Trace(client) logger.Debug("getting target collection") - db := session.DB(dialinfo.Database) - c := db.C(targetCollection) + // db := session.DB(dialinfo.Database) + db := client.Database(connStringInfo.Database) + // c := db.C(targetCollection) + c := db.Collection(targetCollection) logger.Trace(c) logger.Debug("opening bulk operation") - bulkop := c.Bulk() + // bulkop := c.Bulk() // build sql data info logger.Debug("building documents") - bulkop.Insert(logrec) - logger.Debug("running bulk operation") - _, txnErr := bulkop.Run() + iCtx, cancel := context.WithTimeout(context.Background(), 2*time.Second) + defer cancel() + + logger.Debug("inserting new document") + _, txnErr := c.InsertOne(iCtx, logrec) + if txnErr != nil { return nil, txnErr } diff --git a/dev/pyrevit.py b/dev/pyrevit.py index b8c4265ca..442532f55 100644 --- a/dev/pyrevit.py +++ b/dev/pyrevit.py @@ -113,9 +113,9 @@ def print_help(_: Dict[str, str]): Command(name="sign", target="products", args=[], run=release.sign_binaries), Command(name="sign", target="installers", args=[], run=release.sign_installers), # build - Command(name="build", target="products", args=[], run=build.build_binaries), - Command(name="build", target="labs", args=[], run=labs.build_labs), - Command(name="build", target="engines", args=[], run=labs.build_engines), + Command(name="build", target="products", args=["[]"], run=build.build_binaries), + Command(name="build", target="labs", args=["[]"], run=labs.build_labs), + Command(name="build", target="engines", args=["[]"], run=labs.build_engines), Command(name="build", target="autocmp", args=[], run=autoc.build_autocmp), Command(name="build", target="telem", args=[], run=telem.build_telem), Command(name="build", target="installers", args=[], run=release.build_installers), diff --git a/dev/scripts/configs.py b/dev/scripts/configs.py index e52d82e41..c1dff6a5c 100644 --- a/dev/scripts/configs.py +++ b/dev/scripts/configs.py @@ -11,15 +11,46 @@ # binaries BINPATH = op.join(ROOT, "bin") +BINPATH_NETFX = op.join(BINPATH, "netfx") +BINPATH_NETCORE = op.join(BINPATH, "netcore") + +LIBSPATH_NETFX = op.join(ROOT, "dev", "libs", "netfx") +LIBSPATH_NETCORE = op.join(ROOT, "dev", "libs", "netcore") + +ENGINES2PATH_NETFX = op.join(ROOT, "bin", "netfx", "engines", "IPY2712PR") +ENGINES2PATH_NETCORE = op.join(ROOT, "bin", "netcore", "engines", "IPY2712PR") + +ENGINES3PATH_NETFX = op.join(ROOT, "bin", "netfx", "engines", "IPY340PR") +ENGINES3PATH_NETCORE = op.join(ROOT, "bin", "netcore", "engines", "IPY340PR") # root path for non-deployable source files DEVPATH = op.join(ROOT, "dev") +RUNTIME = op.join(DEVPATH, "pyRevitLabs.PyRevit.Runtime/pyRevitLabs.PyRevit.Runtime.sln") LABS = op.join(DEVPATH, "pyRevitLabs/pyRevitLabs.sln") +LABS_CLI = op.join(DEVPATH, "pyRevitLabs/pyRevitClI/pyRevitCLI.csproj") +LABS_DOCTOR = op.join(DEVPATH, "pyRevitLabs/pyRevitDoctor/pyRevitDoctor.csproj") DEFAULT_IPY = op.join(DEVPATH, "modules/pyRevitLabs.IronPython2.sln") LOADERS = op.join(DEVPATH, "pyRevitLoader/pyRevitLoader.sln") CPYTHONRUNTIME = op.join(DEVPATH, "modules/pyRevitLabs.Python.Net.sln") DIRECTORY_BUILD_PROPS = op.join(DEVPATH, "Directory.Build.props") +# pyRevit deps +MAHAPPS = op.join(DEVPATH, "modules/pyRevitLabs.MahApps.Metro/src/MahApps.Metro/MahApps.Metro.csproj") +NEWTONSOFTJSON = op.join(DEVPATH, "modules/pyRevitLabs.Newtonsoft.Json/Src/Newtonsoft.Json/Newtonsoft.Json.csproj") +NLOG = op.join(DEVPATH, "modules/pyRevitLabs.NLog/src/NLog/NLog.csproj") + +IRONPYTHON2 = op.join(DEVPATH, "modules/pyRevitLabs.IronPython2.sln") +IRONPYTHON2_LIB = op.join(DEVPATH, "modules/pyRevitLabs.IronPython2/Src/IronPython/IronPython.csproj") +IRONPYTHON2_MODULES = op.join(DEVPATH, "modules/pyRevitLabs.IronPython2/Src/IronPython.Modules/IronPython.Modules.csproj") +IRONPYTHON2_SQLITE = op.join(DEVPATH, "modules/pyRevitLabs.IronPython2/Src/IronPython.SQLite/IronPython.SQLite.csproj") +IRONPYTHON2_WPF = op.join(DEVPATH, "modules/pyRevitLabs.IronPython2/Src/IronPython.Wpf/IronPython.Wpf.csproj") + +IRONPYTHON3 = op.join(DEVPATH, "modules/pyRevitLabs.IronPython3.sln") +IRONPYTHON3_LIB = op.join(DEVPATH, "modules/pyRevitLabs.IronPython3/Src/IronPython/IronPython.csproj") +IRONPYTHON3_MODULES = op.join(DEVPATH, "modules/pyRevitLabs.IronPython3/Src/IronPython.Modules/IronPython.Modules.csproj") +IRONPYTHON3_SQLITE = op.join(DEVPATH, "modules/pyRevitLabs.IronPython3/Src/IronPython.SQLite/IronPython.SQLite.csproj") +IRONPYTHON3_WPF = op.join(DEVPATH, "modules/pyRevitLabs.IronPython3/Src/IronPython.Wpf/IronPython.Wpf.csproj") + # cli autocomplete files USAGEPATTERNS = op.join( DEVPATH, "pyRevitLabs/pyRevitCLI/Resources/UsagePatterns.txt" diff --git a/dev/scripts/github.py b/dev/scripts/github.py index c8d62a3bb..3225869ef 100644 --- a/dev/scripts/github.py +++ b/dev/scripts/github.py @@ -10,7 +10,7 @@ AUTH_TOKEN = os.environ.get("GITHUB_TOKEN", "") -API_ROOT = "https://api.github.com/repos/eirannejad/pyRevit/" +API_ROOT = "https://api.github.com/repos/pyrevitlabs/pyRevit/" API_ISSUES = API_ROOT + "issues/{ticket}" API_ISSUE_COMMENTS = API_ROOT + "issues/{ticket}/comments" diff --git a/dev/scripts/utils.py b/dev/scripts/utils.py index bde682ff8..91b6245d7 100644 --- a/dev/scripts/utils.py +++ b/dev/scripts/utils.py @@ -34,15 +34,17 @@ def system( cwd: Optional[str] = None, dump_stdout: Optional[bool] = False, ): + print(f"> {' '.join(args)}") + """Run a command and return the stdout""" if dump_stdout: res = subprocess.run( args, stderr=subprocess.STDOUT, check=False, cwd=cwd ) - return "" + return "", res.returncode else: res = subprocess.run(args, capture_output=True, check=False, cwd=cwd) - return res.stdout.decode().strip() + return res.stdout.decode().strip(), res.returncode def where(program_name): @@ -73,22 +75,20 @@ def format_help(helpstring): def run_command(commands: List[Command], args: Dict[str, str]): """Process cli args and run the appropriate commands""" - for cmd in [x for x in commands if args[x.name]]: - if cmd.target: - if not args[cmd.target]: - continue - logger.debug("Running %s", cmd) + for cmd in commands: + if not args[cmd.name] or (cmd.target and not args[cmd.target]): + continue + logger.debug("Running %s with args %s", cmd, args[cmd.name]) cmd.run(args) def parse_dotnet_build_output(output): """Parse dotnet build output to find the result and error reports""" - result = True build_finder = re.compile(r"^Build (success.*|FAIL.*)$") time_finder = re.compile(r"^Time Elapsed (.+)$") capture = False report = "" - for oline in output.split("\n"): + for oline in output[0].split("\n"): if time_finder.match(oline): break if capture: @@ -97,7 +97,7 @@ def parse_dotnet_build_output(output): if "fail" in match.groups()[0].lower(): result = False capture = True - return result, report + return output[1] == 0, output[0] def ensure_windows(): diff --git a/docs/images/favicon.ico b/docs/images/favicon.ico new file mode 100644 index 000000000..c8fcab817 Binary files /dev/null and b/docs/images/favicon.ico differ diff --git a/docs/static/favicon.ico b/docs/static/favicon.ico new file mode 100644 index 000000000..c8fcab817 Binary files /dev/null and b/docs/static/favicon.ico differ diff --git a/docs/static/favicon.png b/docs/static/favicon.png new file mode 100644 index 000000000..d3f5a12fa --- /dev/null +++ b/docs/static/favicon.png @@ -0,0 +1 @@ + diff --git a/extensions/pyRevitBundlesCreatorExtension.extension/extension.json b/extensions/pyRevitBundlesCreatorExtension.extension/extension.json index ac5c7474b..bbd1214e4 100644 --- a/extensions/pyRevitBundlesCreatorExtension.extension/extension.json +++ b/extensions/pyRevitBundlesCreatorExtension.extension/extension.json @@ -7,8 +7,8 @@ "description": "Button to create buttons and panels for pyRevit", "author": "Jean-Marc Couffin", "author_profile": "https://www.linkedin.com/in/jmcouffin/", - "url": "https://github.com/eirannejad/pyRevit.git", - "website": "http://eirannejad.github.io/pyRevit/", + "url": "https://github.com/pyrevitlabs/pyRevit.git", + "website": "http://pyrevitlabs.github.io/pyRevit/", "image": "", "dependencies": [] } \ No newline at end of file diff --git a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/Button Creator.pushbutton/bundle.yaml b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/Button Creator.pushbutton/bundle.yaml index 2455fc30c..30098f4ce 100644 --- a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/Button Creator.pushbutton/bundle.yaml +++ b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/Button Creator.pushbutton/bundle.yaml @@ -2,8 +2,10 @@ title: fr_fr: Créer des boutons en_us: Create Buttons ru: Создать кнопки + es_es: Creador de botones tooltip: fr_fr: Créer des boutons en_us: Create Buttons ru: Создает кнопки. + es_es: Creador de botones context: zero-doc \ No newline at end of file diff --git a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/content_button/bundle.yaml b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/content_button/bundle.yaml index b11e30d50..8a0739ba4 100644 --- a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/content_button/bundle.yaml +++ b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/content_button/bundle.yaml @@ -1,7 +1,9 @@ title: en_us: english title fr_fr: french title + es_es: spanish title tooltip: en_us: english tooltip fr_fr: french tooltip + es_es: spanish tooltip # highlight: new \ No newline at end of file diff --git a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/invoke_dll_button/bundle.yaml b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/invoke_dll_button/bundle.yaml index cf0d17335..91a8c250b 100644 --- a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/invoke_dll_button/bundle.yaml +++ b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/invoke_dll_button/bundle.yaml @@ -1,9 +1,11 @@ title: en_us: english title fr_fr: french title + es_es: spanish title tooltip: en_us: english tooltip fr_fr: french tooltip + es_es: spanish tooltip # highlight: new context: zero-doc assembly: AliTpyRevitConcepts.dll diff --git a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton/bundle.yaml b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton/bundle.yaml index b11e30d50..8a0739ba4 100644 --- a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton/bundle.yaml +++ b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton/bundle.yaml @@ -1,7 +1,9 @@ title: en_us: english title fr_fr: french title + es_es: spanish title tooltip: en_us: english tooltip fr_fr: french tooltip + es_es: spanish tooltip # highlight: new \ No newline at end of file diff --git a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton_for_dynamo_script/bundle.yaml b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton_for_dynamo_script/bundle.yaml index 9d660ee2f..435e7e341 100644 --- a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton_for_dynamo_script/bundle.yaml +++ b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton_for_dynamo_script/bundle.yaml @@ -3,6 +3,8 @@ engine: title: en_us: english title fr_fr: french title + es_es: spanish title tooltip: en_us: english tooltip - fr_fr: french tooltip \ No newline at end of file + fr_fr: french tooltip + es_es: spanish tooltip \ No newline at end of file diff --git a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton_with_config/bundle.yaml b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton_with_config/bundle.yaml index 6c88c66d1..001cb6260 100644 --- a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton_with_config/bundle.yaml +++ b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/pushbutton_with_config/bundle.yaml @@ -1,6 +1,8 @@ title: en_us: english title fr_fr: french title + es_es: spanish title tooltip: fr_fr: "Contrôle qualité, utilisez shift click pour configurer les tests" - en_us: Quality control use shift+click to configure the tests \ No newline at end of file + en_us: Quality control use shift+click to configure the tests + es_es: "Control de calidad, usa shift+click para configurar las pruebas" \ No newline at end of file diff --git a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/url_button/bundle.yaml b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/url_button/bundle.yaml index db49077d7..07f69e79d 100644 --- a/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/url_button/bundle.yaml +++ b/extensions/pyRevitBundlesCreatorExtension.extension/pyRevit Bundles Creator.tab/Button creation.panel/button_types/url_button/bundle.yaml @@ -1,7 +1,9 @@ title: en_us: english title fr_fr: french title + es_es: spanish title tooltip: en_us: english tooltip fr_fr: french tooltip + es_es: spanish tooltip hyperlink: https://www.notion.so/Developer-Docs-2c88f3ecccde422d9504e20b6b9e04f8 diff --git a/extensions/pyRevitCore.extension/extension.json b/extensions/pyRevitCore.extension/extension.json index 20820521e..558f1959d 100644 --- a/extensions/pyRevitCore.extension/extension.json +++ b/extensions/pyRevitCore.extension/extension.json @@ -7,8 +7,8 @@ "description": "Core Scripts for Autodesk Revit", "author": "Ehsan Iran-Nejad", "author_profile": "https://keybase.io/ein", - "url": "https://github.com/eirannejad/pyRevit.git", - "website": "http://eirannejad.github.io/pyRevit/", + "url": "https://github.com/pyrevitlabs/pyRevit.git", + "website": "http://pyrevitlabs.github.io/pyRevit/", "image": "", "templates": { "author": "Ehsan Iran-Nejad", diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/AboutWindow.ResourceDictionary.es_es.xaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/AboutWindow.ResourceDictionary.es_es.xaml new file mode 100644 index 000000000..c94b4a326 --- /dev/null +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/AboutWindow.ResourceDictionary.es_es.xaml @@ -0,0 +1,20 @@ + + + pyRevit + Funcionando en IronPython {} (cpython {}) + modo Cohete activo + modo Cohete inactivo + + Wiki + Twitter + Blog + GitHub + YouTube + Licencia + Soporte + Creditos + Notas de Versión + diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/aboutscript.py b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/aboutscript.py index 20b2624c7..d0524d036 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/aboutscript.py +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/aboutscript.py @@ -56,8 +56,7 @@ def __init__(self, xaml_file_name): if cpyver: self.pyrevit_engine.Text = \ self.get_locale_string("pyRevit.Engine")\ - .format(sys.version.split('(')[0].strip(), - '.'.join(list(str(cpyver.Version)))) + .format(sys.version.split('(')[0].strip(), cpyver.Version) if __cachedengine__: self.pyrevit_rmode.Text = self.get_locale_string("pyRevit.RocketMode.Enabled") diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/bundle.yaml index c5b480d9a..84b466d7d 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/About.pushbutton/bundle.yaml @@ -6,6 +6,7 @@ title: de_de: Über nl_nl: Over pt_br: Sobre pyRevit + es_es: Sobre fa: درباره tooltip: ru: >- @@ -29,4 +30,7 @@ tooltip: À propos de pyRevit. Ouvre le site web du blog pyRevit. Vous pouvez y trouver des informations détaillées sur le fonctionnement de pyRevit, des mises à jour sur les nouveaux outils et les changements, et beaucoup d'autres informations. + es_es: >- + Sobre pyRevit. Abre el blog online de pyRevit. Puedes encontrar información detallada del + funcionamiento de pyRevit, actualizaciones y cambios de las herramientas, y mucha otra información. context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Extensions.smartbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Extensions.smartbutton/bundle.yaml index 32c3cae74..f94b5d2e5 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Extensions.smartbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Extensions.smartbutton/bundle.yaml @@ -1,7 +1,9 @@ title: ru: Расширения en_us: Extensions + es_es: Extensiones tooltip: ru: Добавляет или удаляет pyRevit расширения. en_us: Add or remove pyRevit extensions + es_es: Agrega o quita extensiones de pyRevit context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Settings.smartbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Settings.smartbutton/bundle.yaml index 0f70c7e93..3ba9cc50c 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Settings.smartbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Settings.smartbutton/bundle.yaml @@ -2,6 +2,7 @@ title: ru: Настройки en_us: Settings fr_fr: Paramètres + es_es: 'Configuración' tooltip: ru: >- Показывает окно настроек pyRevit. Вы можете настраивать как pyRevit загружает и устанавливает некоторые параметры. @@ -21,4 +22,12 @@ tooltip: Shift-Click: Affiche le fichier de configuration dans l'explorateur. + es_es: >- + Muestra la ventana de preferencias de pyRevit. Puedes personalizar la forma en carga pyRevit así como definir configuraciones base. + + Shift-Click: + + Muestra el archivo de configuración en el explorador. + + Muestra la ventana de preferencias de pyRevit. Puedes personalizar la forma en carga pyRevit así como definir configuraciones base context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Update.smartbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Update.smartbutton/bundle.yaml index 860c24619..96bbf6fe4 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Update.smartbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/Update.smartbutton/bundle.yaml @@ -1,7 +1,9 @@ title: ru: Обновить en_us: Update + es_es: Actualizar tooltip: ru: Скачивает обновления из удаленного git репозитория (пример github, bitbucket). en_us: Downloads updates from the remote git repositories (e.g github, bitbucket) + es_es: Descarga las actualizaciones desde los repositorios remotos de git (ej. github, bitbucket) context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/Icons8.urlbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/Icons8.urlbutton/bundle.yaml index 648361dc3..9e148d4c2 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/Icons8.urlbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/Icons8.urlbutton/bundle.yaml @@ -1,8 +1,10 @@ title: ru: Icons8 en_us: Icons8 + es_es: Icons8 tooltip: ru: Открывает сайт, который предоставляет иконки для инструментов. en_us: Opens the website that is providing the icons for the tools + es_es: Abre la página web que provee los iconos para las herramientas hyperlink: "https://icons8.com/icon/set/revit/windows" context: zero-doc \ No newline at end of file diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/RegEx Tool.urlbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/RegEx Tool.urlbutton/bundle.yaml index 88987543e..aeb55d5fe 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/RegEx Tool.urlbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/RegEx Tool.urlbutton/bundle.yaml @@ -1,8 +1,10 @@ title: ru: RegEx Tool en_us: RegEx Tool + es_es: Herramiento RegEx tooltip: ru: Открывает сайт RegExr, которы используется для создания и тестирования регулярных выражений. en_us: Opens RegExr website that is used to create and test regular expressions + es_es: Abre la página web de RegExr que se usa para crear y probar expresiones regulares hyperlink: "http://regexr.com/" context: zero-doc \ No newline at end of file diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/Report Bugs.pushbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/Report Bugs.pushbutton/bundle.yaml index 9a4cb0b3c..fad241193 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/Report Bugs.pushbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/links.stack/Report Bugs.pushbutton/bundle.yaml @@ -1,7 +1,9 @@ title: ru: Сообщить об ошибках en_us: Report Bugs + es_es: Reportar Errores tooltip: ru: Открывает issue на github, чтобы сообщать о багах и ошибках. en_us: Opens the issue tracker on github to report bugs and issues + es_es: Abre el seguimiento de incidencias en github para reportar problemas y errores context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Blog.pushbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Blog.pushbutton/bundle.yaml index 00b7d0a30..97e51a79b 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Blog.pushbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Blog.pushbutton/bundle.yaml @@ -3,7 +3,9 @@ title: en_us: "Blog" fa: "وبلاگ" ar: "بلاگ" + es_es: 'Blog' tooltip: ru: Открывает блог pyRevit. en_us: Opens the pyRevit blog. + es_es: Abre el blog de pyRevit. context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Repo.pushbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Repo.pushbutton/bundle.yaml index bfadda372..4e7cd9e0c 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Repo.pushbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Repo.pushbutton/bundle.yaml @@ -1,7 +1,9 @@ title: ru: Репо en_us: Repo + es_es: Repo tooltip: ru: Открывает страницу git репозитория. en_us: Opens the git repository page + es_es: 'Abre la página del repositorio de git' context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Wiki.pushbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Wiki.pushbutton/bundle.yaml index 108e3aa78..5b6436e5b 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Wiki.pushbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/prlinks.stack/Wiki.pushbutton/bundle.yaml @@ -1,7 +1,9 @@ title: ru: Wiki en_us: Wiki + es_es: Wiki tooltip: ru: Открывает страницу wiki. en_us: Opens the wiki page + es_es: 'Abre la página de wiki.' context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/apidocs.urlbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/apidocs.urlbutton/bundle.yaml index 64c38fee5..0331b8df8 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/apidocs.urlbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/apidocs.urlbutton/bundle.yaml @@ -1,8 +1,10 @@ title: ru: apidocs en_us: apidocs + es_es: apidocs tooltip: ru: Открывает последнюю версию документации Revit на apidocs.co. en_us: Opens the latest version of Revit on apidocs.co + es_es: Abre la última version de Revit en apidocs.so hyperlink: "https://apidocs.co/apps/revit/latest" context: zero-doc \ No newline at end of file diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/emojis.pushbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/emojis.pushbutton/bundle.yaml index a94a827cb..e7b4e2159 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/emojis.pushbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/emojis.pushbutton/bundle.yaml @@ -1,7 +1,9 @@ title: ru: emojis en_us: emojis + es_es: emojis tooltip: ru: Печатает все доступные эмоджи с сокращенными кодами. en_us: Prints all available emojis with shorthand codes + es_es: Imprime todos los emojis disponibles con codigo de caracteres context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/rpw Docs.urlbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/rpw Docs.urlbutton/bundle.yaml index b9d7df2ac..127a8ce83 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/rpw Docs.urlbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/rpwlinks.stack/rpw Docs.urlbutton/bundle.yaml @@ -1,8 +1,10 @@ title: ru: rpw en_us: rpw + es_es: rpw tooltip: ru: Открывает страницу документации для RevitPythonWrapper. en_us: Opens the documentation page for RevitPythonWrapper + es_es: Abre la pagina de documentacion para RevitPythonWrapper hyperlink: "http://revitpythonwrapper.readthedocs.io/en/latest/" context: zero-doc \ No newline at end of file diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Reload.pushbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Reload.pushbutton/bundle.yaml index e97253d5a..635ecb913 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Reload.pushbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Reload.pushbutton/bundle.yaml @@ -2,6 +2,7 @@ tooltip: ru: Находит папки со скриптами и создает кнопки новых криптов или новых устанновленных расширений. en_us: Searches the script folders and create buttons for the new script or newly installed extensions fr_fr: Recherche de nouveaux scripts dans le dossier de scripts et crée de nouveau bouton ou ajoute une nouvelle extension + es_es: 'Busca las carpetas de código y crea botones para los nuevos códigos o nuevas extensiones instaladas' engine: clean: true title: @@ -11,4 +12,5 @@ title: bg: 'Презареди' nl_nl: 'Herladen' fr_fr: 'Recharger' + es_es: 'Recargar' context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Search.pushbutton/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Search.pushbutton/bundle.yaml index 1cd5daffa..51fb988e5 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Search.pushbutton/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Search.pushbutton/bundle.yaml @@ -1,6 +1,7 @@ tooltip: ru: Самый лучший интерфейс! en_us: The best interface ever! + es_es: Lo mejor que hay! title: ru: Поиск en_us: 'Search' @@ -9,4 +10,5 @@ title: nl_nl: 'Zoek' fr_fr: 'Rechercher' de_de: 'Suche' + es_es: "Buscar" context: zero-doc diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Spy.pulldown/List Elements.pushbutton/script.py b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Spy.pulldown/List Elements.pushbutton/script.py index 0b7d4051b..57da3f3d3 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Spy.pulldown/List Elements.pushbutton/script.py +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Spy.pulldown/List Elements.pushbutton/script.py @@ -50,7 +50,7 @@ forms.CommandSwitchWindow.show(sorted(switches), message='List elements of type:') - +output.freeze() if selected_switch == 'Graphic Styles': cl = DB.FilteredElementCollector(revit.doc) gstyles = [i for i in cl.OfClass(DB.GraphicsStyle).ToElements()] @@ -488,3 +488,4 @@ def isline(line): dbcat = revit.query.get_category(bic) if not dbcat: print(bic) +output.unfreeze() diff --git a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Spy.pulldown/bundle.yaml b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Spy.pulldown/bundle.yaml index 2e607492b..17f4c0e84 100644 --- a/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Spy.pulldown/bundle.yaml +++ b/extensions/pyRevitCore.extension/pyRevit.tab/pyRevit.panel/tools.stack/Spy.pulldown/bundle.yaml @@ -2,4 +2,5 @@ title: ru: Шпион en_us: Spy fr_fr: Espionner + es_es: Espia diff --git a/extensions/pyRevitDevHooks.extension/extension.json b/extensions/pyRevitDevHooks.extension/extension.json index 41efd11b5..0f4361d7a 100644 --- a/extensions/pyRevitDevHooks.extension/extension.json +++ b/extensions/pyRevitDevHooks.extension/extension.json @@ -7,8 +7,8 @@ "description": "Development Hooks for pyRevit", "author": "Ehsan Iran-Nejad", "author_profile": "https://keybase.io/ein", - "url": "https://github.com/eirannejad/pyRevit.git", - "website": "http://eirannejad.github.io/pyRevit/", + "url": "https://github.com/pyrevitlabs/pyRevit.git", + "website": "http://pyrevitlabs.github.io/pyRevit/", "image": "", "templates": { "author": "Ehsan Iran-Nejad", diff --git a/extensions/pyRevitDevTools.extension/extension.json b/extensions/pyRevitDevTools.extension/extension.json index 5d1b269c8..b72328cf9 100644 --- a/extensions/pyRevitDevTools.extension/extension.json +++ b/extensions/pyRevitDevTools.extension/extension.json @@ -7,8 +7,8 @@ "description": "Development Tools for pyRevit", "author": "Ehsan Iran-Nejad", "author_profile": "https://keybase.io/ein", - "url": "https://github.com/eirannejad/pyRevit.git", - "website": "http://eirannejad.github.io/pyRevit/", + "url": "https://github.com/pyrevitlabs/pyRevit.git", + "website": "http://pyrevitlabs.github.io/pyRevit/", "image": "", "templates": { "author": "Ehsan Iran-Nejad", diff --git a/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Engine Tests.pulldown/Test CPython Command.pushbutton/script.py b/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Engine Tests.pulldown/Test CPython Command.pushbutton/script.py index 77c27fd63..1b23a4f25 100644 --- a/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Engine Tests.pulldown/Test CPython Command.pushbutton/script.py +++ b/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Engine Tests.pulldown/Test CPython Command.pushbutton/script.py @@ -45,7 +45,7 @@ def print_html(output_str): print('\n## Module Tests:') import os -pythonpath=os.environ['PYTHONPATH'] +pythonpath=os.environ.get('PYTHONPATH') # this fails on cpy 3.7 (= was added on 3.8) print(f'{pythonpath=}') diff --git a/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Engine Tests.pulldown/Test CPython Engine.pushbutton/script.py b/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Engine Tests.pulldown/Test CPython Engine.pushbutton/script.py index 6753072c4..a946b1224 100644 --- a/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Engine Tests.pulldown/Test CPython Engine.pushbutton/script.py +++ b/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Engine Tests.pulldown/Test CPython Engine.pushbutton/script.py @@ -7,14 +7,13 @@ __context__ = 'zero-doc' import clr -# add path of active pyRevitLabs.PythonNet.dll to the sys.path -from pyrevit.userconfig import user_config -sys.path.append(op.dirname(user_config.get_active_cpython_engine().AssemblyPath)) +# add path of pyRevitLabs.PythonNet.dll to the sys.path +from pyrevit import BIN_DIR +sys.path.append(BIN_DIR) print('\n'.join(sys.path)) # now load the cpython assembly -# clr.AddReference('pyRevitLabs.PythonNet') clr.AddReferenceToFile('pyRevitLabs.PythonNet.dll') -import Python.Runtime as py +from Python.Runtime import PythonEngine, PyModule TEST_CODE = """import sys print('\\n'.join(sys.path)) @@ -23,19 +22,18 @@ print(System) """ -pe = py.PythonEngine +pe = PythonEngine if not pe.IsInitialized: pe.Initialize() try: - # with py.Py.GIL(): # print version print(pe.Version) # import - print(pe.ImportModule("os")) - csys = pe.ImportModule("sys") + print(PyModule.Import("os")) + csys = PyModule.Import("sys") # set stdout to output stream for this command csys.stdout = sys.stdout @@ -44,8 +42,8 @@ pe.Exec(TEST_CODE) # test adsk modules - print(pe.ImportModule("Autodesk.Revit.DB")) - print(pe.ImportModule("Autodesk.Revit.UI")) + print(PyModule.Import("Autodesk.Revit.DB")) + print(PyModule.Import("Autodesk.Revit.UI")) # eval print(pe.Eval("{1:2, 3:4}").GetPythonType()) @@ -56,4 +54,4 @@ # somehow shutting down thru ironpython doesn't crash revit # button shutting it down mid session with break the next runs # pe.Shutdown() - pass \ No newline at end of file + pass diff --git a/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Unit Tests.pulldown/Test Toast.pushbutton/script.py b/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Unit Tests.pulldown/Test Toast.pushbutton/script.py index 044146682..514fb2d0d 100644 --- a/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Unit Tests.pulldown/Test Toast.pushbutton/script.py +++ b/extensions/pyRevitDevTools.extension/pyRevitDev.tab/Debug.panel/Unit Tests.pulldown/Test Toast.pushbutton/script.py @@ -5,7 +5,7 @@ "Hello World!", title="My Script", appid="MyAPP", - click="https://eirannejad.github.io/pyRevit/", + click="https://pyrevitlabs.github.io/pyRevit/", actions={ "Open Google":"https://google.com", "Open Toast64":"https://github.com/go-toast/toast" diff --git a/extensions/pyRevitTags.extension/extension.json b/extensions/pyRevitTags.extension/extension.json index 318944ddd..5fb637597 100644 --- a/extensions/pyRevitTags.extension/extension.json +++ b/extensions/pyRevitTags.extension/extension.json @@ -7,8 +7,8 @@ "description": "Tag & Package Management for Projects", "author": "Ehsan Iran-Nejad", "author_profile": "https://keybase.io/ein", - "url": "https://github.com/eirannejad/pyRevit.git", - "website": "http://eirannejad.github.io/pyRevit/", + "url": "https://github.com/pyrevitlabs/pyRevit.git", + "website": "http://pyrevitlabs.github.io/pyRevit/", "image": "", "templates": { "author": "Ehsan Iran-Nejad", diff --git a/extensions/pyRevitTemplates.extension/extension.json b/extensions/pyRevitTemplates.extension/extension.json index 994547555..bfbaa46d1 100644 --- a/extensions/pyRevitTemplates.extension/extension.json +++ b/extensions/pyRevitTemplates.extension/extension.json @@ -7,8 +7,8 @@ "description": "Tools for maintaining Revit Templates", "author": "Ehsan Iran-Nejad", "author_profile": "https://keybase.io/ein", - "url": "https://github.com/eirannejad/pyRevit.git", - "website": "http://eirannejad.github.io/pyRevit/", + "url": "https://github.com/pyrevitlabs/pyRevit.git", + "website": "http://pyrevitlabs.github.io/pyRevit/", "image": "", "dependencies": [] } \ No newline at end of file diff --git a/extensions/pyRevitTools.extension/checks/modelchecker_check.py b/extensions/pyRevitTools.extension/checks/modelchecker_check.py index 721b85e67..10156f6a2 100644 --- a/extensions/pyRevitTools.extension/checks/modelchecker_check.py +++ b/extensions/pyRevitTools.extension/checks/modelchecker_check.py @@ -1158,52 +1158,52 @@ def DocPhases(doc, links = []): .WhereElementIsNotElementType() .ToElements() ) - worksetTable = doc.GetWorksetTable() - for element in elcollector: - worksetId = element.WorksetId - worksetKind = str(worksetTable.GetWorkset(worksetId).Kind) - if worksetKind == "UserWorkset": - worksetName = worksetTable.GetWorkset(worksetId).Name - if element.Name not in ('DefaultLocation', '', None) or element.Category.Name not in ('', None): - # Removes the location objects from the list as well as empty elements or proxies - if worksetName not in worksetNames: - worksetNames.append(worksetName) - graphWorksetsData.append(worksetName) - # print worksetNames - # sorting results in chart legend - worksetNames.sort() - - worksetsSet = [] - for i in worksetNames: - count = graphWorksetsData.count(i) - worksetsSet.append(count) - worksetNames = [x.encode("utf8") for x in worksetNames] - - # Worksets OUTPUT print chart only when file is workshared - if len(worksetNames) > 0: - chartWorksets = output.make_doughnut_chart() - chartWorksets.options.title = { - "display": True, - "text": "Element Count by Workset", - "fontSize": 25, - "fontColor": "#000", - "fontStyle": "bold", - } - chartWorksets.data.labels = worksetNames - set_a = chartWorksets.data.new_dataset("Not Standard") - set_a.data = worksetsSet - - set_a.backgroundColor = COLORS - - worksetsCount = len(worksetNames) - if worksetsCount < 15: - chartWorksets.set_height(100) - elif worksetsCount < 30: - chartWorksets.set_height(160) - else: - chartWorksets.set_height(200) + if doc.IsWorkshared: + worksetTable = doc.GetWorksetTable() + for element in elcollector: + worksetId = element.WorksetId + worksetKind = str(worksetTable.GetWorkset(worksetId).Kind) + if worksetKind == "UserWorkset": + worksetName = worksetTable.GetWorkset(worksetId).Name + if element.Name not in ('DefaultLocation', '', None) or element.Category.Name not in ('', None): + # Removes the location objects from the list as well as empty elements or proxies + if worksetName not in worksetNames: + worksetNames.append(worksetName) + graphWorksetsData.append(worksetName) + # sorting results in chart legend + worksetNames.sort() + + worksetsSet = [] + for i in worksetNames: + count = graphWorksetsData.count(i) + worksetsSet.append(count) + worksetNames = [x.encode("utf8") for x in worksetNames] + + # Worksets OUTPUT print chart only when file is workshared + if len(worksetNames) > 0: + chartWorksets = output.make_doughnut_chart() + chartWorksets.options.title = { + "display": True, + "text": "Element Count by Workset", + "fontSize": 25, + "fontColor": "#000", + "fontStyle": "bold", + } + chartWorksets.data.labels = worksetNames + set_a = chartWorksets.data.new_dataset("Not Standard") + set_a.data = worksetsSet + + set_a.backgroundColor = COLORS + + worksetsCount = len(worksetNames) + if worksetsCount < 15: + chartWorksets.set_height(100) + elif worksetsCount < 30: + chartWorksets.set_height(160) + else: + chartWorksets.set_height(200) - chartWorksets.draw() + chartWorksets.draw() class ModelChecker(PreflightTestCase): """ diff --git a/extensions/pyRevitTools.extension/extension.json b/extensions/pyRevitTools.extension/extension.json index 7e81c3255..985989526 100644 --- a/extensions/pyRevitTools.extension/extension.json +++ b/extensions/pyRevitTools.extension/extension.json @@ -7,8 +7,8 @@ "description": "IronPython Scripts for Autodesk Revit", "author": "Ehsan Iran-Nejad", "author_profile": "https://keybase.io/ein", - "url": "https://github.com/eirannejad/pyRevit.git", - "website": "http://eirannejad.github.io/pyRevit/", + "url": "https://github.com/pyrevitlabs/pyRevit.git", + "website": "http://pyrevitlabs.github.io/pyRevit/", "image": "", "templates": { "author": "Ehsan Iran-Nejad", diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/ColorSplasher.pushbutton/icon.ico b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/ColorSplasher.pushbutton/icon.ico deleted file mode 100644 index 5101f7804..000000000 Binary files a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/ColorSplasher.pushbutton/icon.ico and /dev/null differ diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/ColorSplasher.pushbutton/script.py b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/ColorSplasher.pushbutton/script.py index ff645c606..4c0a27b27 100644 --- a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/ColorSplasher.pushbutton/script.py +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/ColorSplasher.pushbutton/script.py @@ -1,168 +1,54 @@ # encoding: utf-8 -""" -This script is based on ColorSplasher by BIMOne. -All original code from BIMOne is licensed under MIT License, however all modifications and improvements are licensed under a different license agreement included below: +import sys +import clr +clr.AddReference('ProtoGeometry') +from Autodesk.DesignScript.Geometry import * -################################ +import re -MIT License -Copyright (c) 2021 BIM One Inc. -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: +import math -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +from random import randint -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +import os.path -################################ +import inspect -Nonica - License Agreement -For the use of this script -This License Agreement (this “Agreement” of this “License Agreement”) is made and effective as of the current date (the “Commencement Date”) by and between Nonica by Estudio Alonso Candau SLP a company organized and existing in Spain with a registered address at Avd.Chafarinas 16 Puerto Rey Vera, Almeria (“Licensor”) and yourself (“Licensee”). -WHEREAS: -1. Licensee wishes to obtain access and use this script (hereinafter, the “Asset”), and -2. Licensor is willing to grant to the Licensee a non-exclusive, non-transferable License to use the Asset for the term and specific purpose set forth in this Agreement, -NOW, THEREFORE, your access to and use of the Service is conditioned on your acceptance of and compliance with these Terms and Conditions. These Terms and Conditions apply to all visitors, users and others who access or use this script. -1. Definitions -1.1 “Agreement” means this License Agreement including the attached Schedule. -1.2 “Confidential Information” means information that: -a. is by its nature confidential; -b. is designated in writing by Licensor as confidential; -c. the Licensee knows or reasonably ought to know is confidential; -d. Information comprised in or relating to any Intellectual Property Rights of Licensor. -1.3 “Asset” means the Asset provided by Licensor as specified in Item 6 of the Schedule in the form as stated in Item 7 of the Schedule. -1.4 “Intellectual Property Rights” means all rights in and to any copyright, trademark, trading name, design, patent, know how (trade secrets) and all other rights resulting from intellectual activity in the industrial, scientific, literary or artistic field and any application or right to apply for registration of any of these rights and any right to protect or enforce any of these rights, as further specified in clause 5. -1.5 “Party” means a person or business entity who has executed this Agreement; details of the Parties are specified in Item 2 of the Schedule. -1.6 “Term” means the term of this Agreement commencing on the Commencement Date as specified in Item 4 of the Schedule and expiring on the Expiry Date specified in Item 5 of the Schedule. -2. License Grant -2.1 Licensor grants to the Licensee a non-exclusive, non-transferable License for the Term to use the Asset for the specific purpose specified in this Agreement, subject to the terms and conditions set out in this Agreement. -3. Charges -3.1 In consideration of the Licensor providing the License under clause 2 of this License Agreement, the Licensee agrees to pay Licensor the amount of the License Charge as specified in Item 9 of the Schedule. -4. Licensee's Obligations -4.1 The Licensee cannot use the Asset, for purposes other than as specified in this Agreement and in Item 8 of the Schedule. -4.2 The Licensee may permit its employees to use the Asset for the purposes described in Item 8, provided that the Licensee takes all necessary steps and imposes the necessary conditions to ensure that all employees using the Asset do not commercialise or disclose the contents of it to any third person, or use it other than in accordance with the terms of this Agreement. -4.3 The Licensee will not distribute, sell, License or sub-License, let, trade or expose for sale the Asset to a third party. -4.4 No copies of the Asset are to be made other than as expressly approved by Licensor. -4.5 No changes to the Asset or its content may be made by Licensee. -4.6 The Licensee will provide technological and security measures to ensure that the Asset which the Licensee is responsible for is physically and electronically secure from unauthorised use or access. -4.7 Licensee shall ensure that the Asset retains all Licensor copyright notices and other proprietary legends and all trademarks or service marks of Licensor. -5. Intellectual Property Rights -5.1 All Intellectual Property Rights over and in respect of the Asset are owned by Licensor. The Licensee does not acquire any rights of ownership in the Asset. -6. Limitation of Liability -6.1 The Licensee acknowledges and agrees that neither Licensor nor its board members, officers, employees or agents, will be liable for any loss or damage arising out of or resulting from Licensor's provision of the Asset under this Agreement, or any use of the Asset by the Licensee or its employees; and Licensee hereby releases Licensor to the fullest extent from any such liability, loss, damage or claim. -7. Confidentiality -7.1 Neither Party may use, disclose or make available to any third party the other Party's Confidential Information, unless such use or disclosure is done in accordance with the terms of this Agreement. -7.2 Each Party must hold the other Party's Confidential Information secure and in confidence, except to the extent that such Confidential Information: -a. is required to be disclosed according to the requirements of any law, judicial or legislative body or government agency; or -b. was approved for release in writing by the other Party, but only to the extent of and subject to such conditions as may be imposed in such written authorisation. -7.3 This clause 7 will survive termination of this Agreement. -8. Disclaimers & Release -8.1 To the extent permitted by law, Licensor will in no way be liable to the Licensee or any third party for any loss or damage, however caused (including through negligence) which may be directly or indirectly suffered in connection with any use of the Asset. -8.2 The Asset is provided by Licensor on an “as is” basis. -8.3 Licensor will not be held liable by the Licensee in any way, for any loss, damage or injury suffered by the Licensee or by any other person related to any use of the Asset or any part thereof. -8.4 Notwithstanding anything contained in this Agreement, in no event shall Licensor be liable for any claims, damages or loss which may arise from the modification, combination, operation or use of the Asset with Licensee computer programs. -8.5 Licensor does not warrant that the Asset will function in any environment. -8.6 The Licensee acknowledges that: a. The Asset has not been prepared to meet any specific requirements of any party, including any requirements of Licensee; and b. it is therefore the responsibility of the Licensee to ensure that the Asset meets its own individual requirements. -8.7 To the extent permitted by law, no express or implied warranty, term, condition or undertaking is given or assumed by Licensor, including any implied warranty of merchantability or fitness for a particular purpose. -9. Indemnification -9.1 The Licensee must indemnify, defend and hold harmless Licensor, its board members, officers, employees and agents from and against any and all claims (including third party claims), demands, actions, suits, expenses (including attorney's fees) and damages (including indirect or consequential loss) resulting in any way from: -a. Licensee's and Licensee's employee's use or reliance on the Asset, -b. any breach of the terms of this License Agreement by the Licensee or any Licensee employee, and -c. any other act of Licensee. -9.2 This clause 9 will survive termination of this Agreement. -10. Waiver -10.1 Any failure or delay by either Party to exercise any right, power or privilege hereunder or to insist upon observance or performance by the other of the provisions of this License Agreement shall not operate or be construed as a waiver thereof. -11. Governing Law -11.1 This Agreement will be construed by and governed in accordance with the laws of Spain. The Parties submit to exclusive jurisdiction of the courts of Spain. -12. Termination -12.1 This Agreement and the License granted herein commences upon the Commencement Date and is granted for the Term, unless otherwise terminated by Licensor in the event of any of the following: -a. if the Licensee is in breach of any term of this License Agreement and has not corrected such breach to Licensor's reasonable satisfaction within 7 days of Licensor's notice of the same; -b. if the Licensee becomes insolvent, or institutes (or there is instituted against it) proceedings in bankruptcy, insolvency, reorganization or dissolution, or makes an assignment for the benefit of creditors; or -c. the Licensee is in breach of clause 5 or 7 of this Agreement. -12.2 Termination under this clause shall not affect any other rights or remedies Licensor may have. -14. Assignment -14.1 Licensee shall not assign any rights of this License Agreement, without the prior written consent of Licensor. -15. Notices -15.1 All notices required under this Agreement shall be in writing and shall be deemed given (i) when delivered personally; (ii) five (5) days after mailing, when sent certified mail, return receipt requested and postage prepaid; or (iii) one (1) business day after dispatch, when sent via a commercial overnight carrier, fees prepaid. All notices given by either Party must be sent to the address of the other as first written above (unless otherwise changed by written notice). -16. Counterparts -16.1 This Agreement may be executed in any number of counterparts, each of which shall be deemed to be an original and all of which taken together shall constitute one instrument. -17. Severability -17.1 The Parties recognize the uncertainty of the law with respect to certain provisions of this Agreement and expressly stipulate that this Agreement will be construed in a manner that renders its provisions valid and enforceable to the maximum extent possible under applicable law. To the extent that any provisions of this Agreement are determined by a court of competent jurisdiction to be invalid or unenforceable, such provisions will be deleted from this Agreement or modified so as to make them enforceable and the validity and enforceability of the remainder of such provisions and of this Agreement will be unaffected. -18. Entire Agreement -18.1 This Agreement contains the entire agreement between the Parties and supersedes any previous understanding, commitments or agreements, oral or written. Further, this Agreement may not be modified, changed, or otherwise altered in any respect except by a written agreement signed by both Parties. -IN WITNESS WHEREOF, this Agreement, including the attached Schedule, was signed by the Parties under the hands of their duly authorized representatives and made effective as of the current date. -Nonica by Estudio Alonso Candau SLP, -Signature -02/05/2021 -Jaime Alonso Candau -Please contact hello@nonica.io with any further doubt/request. +import unicodedata -################################ - -Dynamo to pyRevit adaptation by Jean-Marc Couffin, BIMOne inc., 2023/12/11 -""" +clr.AddReference("RevitServices") +import RevitServices +from RevitServices.Persistence import DocumentManager +from RevitServices.Transactions import TransactionManager +from System.Collections.Generic import* -import os.path -from random import randint -from unicodedata import normalize, category -import clr +clr.AddReference("RevitAPIUI") +import Autodesk +from Autodesk.Revit.UI import TaskDialog, IExternalEventHandler, ExternalEvent -clr.AddReference("System") -clr.AddReference("System.Drawing") -clr.AddReference("System.Windows.Forms") -clr.AddReference("System.Data") -import System -from System import String, Enum, Object -from System.Data import DataTable -from System.Drawing import Color, Font, FontStyle, Icon, SolidBrush, Point, Size -from System.Windows.Forms import ( - CheckState, - ColorDialog, - ComboBoxStyle, - DialogResult, - DrawMode, - Form, - FormBorderStyle, - TextRenderer, - ComboBox, - CheckedListBox, - ListBox, - Button, - Label, - AnchorStyles, -) +clr.AddReference('RevitAPI') +import Autodesk +from Autodesk.Revit.DB import * +from Autodesk.Revit.DB import BuiltInCategory +clr.AddReference('System.Drawing') +clr.AddReference('System.Windows.Forms') +import System.Drawing +import System.Windows.Forms -from pyrevit import DB, HOST_APP, UI, revit, script -from pyrevit.forms import alert -from pyrevit.framework import List -from re import sub +from System.Drawing import * +from System.Reflection import Assembly +from System.Windows.Forms import * +clr.AddReference('System.Data') +from System.Data import * -def solid_fill_pattern_id(new_doc): - solid_fill_id = None - fillpatterns = DB.FilteredElementCollector(new_doc).OfClass( - DB.FillPatternElement - ) - for pat in fillpatterns: - if pat.GetFillPattern().IsSolidFill: - solid_fill_id = pat.Id - break - return solid_fill_id +from System import Array +from System.Collections.Generic import * +from pyrevit import HOST_APP, revit -class SubscribeView(UI.IExternalEventHandler): +class subscribeView(IExternalEventHandler): def __init__(self): self.registered = 1 @@ -170,14 +56,14 @@ def Execute(self, uiapp): try: if self.registered == 1: self.registered = 0 - uiapp.ViewActivated += self.view_changed + uiapp.ViewActivated += self.viewChanged else: self.registered = 1 - uiapp.ViewActivated -= self.view_changed - except Exception: + uiapp.ViewActivated -= self.viewChanged + except Exception as e: pass - - def view_changed(self, sender, e): + + def viewChanged(self, sender, e): if wndw.IsOpen == 1: if self.registered == 0: new_doc = e.Document @@ -186,444 +72,423 @@ def view_changed(self, sender, e): if wndw: if not new_doc.Equals(doc): wndw.Close() - # Update categories in dropdown - new_view = get_active_view(e.Document) + #Update categories in dropdown + new_view = getActiveView(e.Document) if new_view != 0: - # Unsubcribe - wndw._list_box2.SelectedIndexChanged -= ( - wndw.list_selected_index_changed - ) - # Update categories for new view + #Unsubcribe + wndw._listBox2.SelectedIndexChanged -= wndw.lstselectedIndexChanged + #Update categories for new view wndw.crt_view = new_view - categ_inf_used_up = get_used_categories_and_parameters( - cat_excluded, wndw.crt_view - ) - wndw._categories_table_data = DataTable("Data") - wndw._categories_table_data.Columns.Add("Key", String) - wndw._categories_table_data.Columns.Add("Value", Object) + categ_inf_used_up = getCategoriesAndParametersInUsed(cat_excluded, wndw.crt_view) + wndw._tableData = DataTable("Data") + wndw._tableData.Columns.Add("Key", System.String) + wndw._tableData.Columns.Add("Value", System.Object) names = [x._name for x in categ_inf_used_up] - wndw._categories_table_data.Rows.Add("Select a Category Here!", 0) - [ - wndw._categories_table_data.Rows.Add(key_, value_) - for key_, value_ in zip(names, categ_inf_used_up) - ] - wndw._categories.DataSource = wndw._categories_table_data + wndw._tableData.Rows.Add("Select a Category Here!", 0) + [wndw._tableData.Rows.Add(key_, value_ ) for key_, value_ in zip(names, categ_inf_used_up)] + wndw._categories.DataSource = wndw._tableData wndw._categories.DisplayMember = "Key" - # Vaciar range of values - wndw._table_data3 = DataTable("Data") - wndw._table_data3.Columns.Add("Key", String) - wndw._table_data3.Columns.Add("Value", Object) - wndw._list_box2.DataSource = wndw._table_data3 - wndw._list_box2.DisplayMember = "Key" - + #Vaciar range of values + wndw._tableData3 = DataTable("Data") + wndw._tableData3.Columns.Add("Key", System.String) + wndw._tableData3.Columns.Add("Value", System.Object) + wndw._listBox2.DataSource = wndw._tableData3 + wndw._listBox2.DisplayMember = "Key" + def GetName(self): return "Subscribe View Changed Event" - -class ApplyColors(UI.IExternalEventHandler): +class applyColors(IExternalEventHandler): def __init__(self): pass - + def Execute(self, uiapp): try: - new_doc = revit.DOCS.doc - view = get_active_view(new_doc) + new_doc = uiapp.ActiveUIDocument.Document + view = getActiveView(new_doc) if view != 0: - sf = solid_fill_pattern_id(new_doc) - t = DB.Transaction(new_doc, "Apply colors to elements") + solidFillId = None + fElementCollector = FilteredElementCollector(new_doc).OfClass(FillPatternElement) + for pat in fElementCollector: + if pat.GetFillPattern().IsSolidFill: + solidFillId = pat.Id + break + t = Transaction(new_doc, "Apply colors to elements") t.Start() - sel_cat = wndw._categories.SelectedItem["Value"] - if ( - sel_cat._cat.Id.IntegerValue == int(DB.BuiltInCategory.OST_Rooms) - or sel_cat._cat.Id.IntegerValue - == int(DB.BuiltInCategory.OST_MEPSpaces) - or sel_cat._cat.Id.IntegerValue == int(DB.BuiltInCategory.OST_Areas) - ): - # In case of rooms, spaces and areas. Check Color scheme is applied and if not + sel_cat = wndw._categories.SelectedItem['Value'] + if sel_cat._cat.Id.IntegerValue == int(BuiltInCategory.OST_Rooms) or sel_cat._cat.Id.IntegerValue == int(BuiltInCategory.OST_MEPSpaces) or sel_cat._cat.Id.IntegerValue == int(BuiltInCategory.OST_Areas): + #In case of rooms, spaces and areas. Check Color scheme is applied and if not if version > 2021: - if ( - str(wndw.crt_view.GetColorFillSchemeId(sel_cat._cat.Id)) - == "-1" - ): - fColorScheme = ( - DB.FilteredElementCollector(new_doc) - .OfClass(DB.ColorFillScheme) - .ToElements() - ) + if str(wndw.crt_view.GetColorFillSchemeId(sel_cat._cat.Id)) == "-1": + fColorScheme = FilteredElementCollector(new_doc).OfClass(ColorFillScheme).ToElements() if len(fColorScheme) > 0: for sch in fColorScheme: - if ( - sch.CategoryId.IntegerValue - == sel_cat._cat.Id.IntegerValue - ): + if sch.CategoryId.IntegerValue == sel_cat._cat.Id.IntegerValue: if len(sch.GetEntries()) > 0: - wndw.crt_view.SetColorFillSchemeId( - sel_cat._cat.Id, sch.Id - ) + wndw.crt_view.SetColorFillSchemeId(sel_cat._cat.Id, sch.Id) break else: - wndw._txt_block5.Visible = True + wndw._txtBlock5.Visible = True else: - wndw._txt_block5.Visible = False - - for indx in range(wndw._list_box2.Items.Count): - ogs = DB.OverrideGraphicSettings().Dispose() - ogs = DB.OverrideGraphicSettings() - color = DB.Color( - wndw._list_box2.Items[indx]["Value"]._n1, - wndw._list_box2.Items[indx]["Value"]._n2, - wndw._list_box2.Items[indx]["Value"]._n3, - ) - # ogs.SetProjectionLineColor(color) - ogs.SetSurfaceForegroundPatternColor(color) - ogs.SetCutForegroundPatternColor(color) - if sf is not None: - ogs.SetSurfaceForegroundPatternId(sf) - ogs.SetCutForegroundPatternId(sf) - ogs.SetProjectionLinePatternId(DB.ElementId(-1)) - for id in wndw._list_box2.Items[indx]["Value"]._eleId: + wndw._txtBlock5.Visible = False + + for indx in range(wndw._listBox2.Items.Count): + ogs = OverrideGraphicSettings().Dispose() + ogs = OverrideGraphicSettings() + color = Autodesk.Revit.DB.Color(wndw._listBox2.Items[indx]['Value']._n1, wndw._listBox2.Items[indx]['Value']._n2, wndw._listBox2.Items[indx]['Value']._n3) + ogs.SetProjectionLineColor(color) + ogs.SetSurfaceForegroundPatternColor(color); + ogs.SetCutForegroundPatternColor(color); + if solidFillId != None: + ogs.SetSurfaceForegroundPatternId(solidFillId); + ogs.SetCutForegroundPatternId(solidFillId) + ogs.SetProjectionLinePatternId(ElementId(-1)); + for id in wndw._listBox2.Items[indx]['Value']._eleId: view.SetElementOverrides(id, ogs) t.Commit() - except Exception: + except Exception as e: pass - + def GetName(self): - return "Apply colors to elements" - - -class ResetColors(UI.IExternalEventHandler): + return "Set colors to elements" + +class resetColors(IExternalEventHandler): def __init__(self): pass - + def Execute(self, uiapp): try: - new_doc = revit.DOCS.doc - view = get_active_view(new_doc) + new_doc = uiapp.ActiveUIDocument.Document + view = getActiveView(new_doc) if view != 0: - ogs = DB.OverrideGraphicSettings().Dispose() - ogs = DB.OverrideGraphicSettings() - collector = ( - DB.FilteredElementCollector(new_doc, view.Id) - .WhereElementIsNotElementType() - .WhereElementIsViewIndependent() - .ToElements() - ) - with revit.Transaction(doc=new_doc, name="Reset colors in elements"): - for ele in collector: - view.SetElementOverrides(ele.Id, ogs) - except Exception: - pass - - def GetName(self): - return "Reset colors in elements" - - -class CreateFilters(UI.IExternalEventHandler): - def __init__(self): - pass - - def Execute(self, uiapp): - try: - new_doc = revit.DOCS.doc - view = get_active_view(new_doc) - with revit.Transaction(doc=new_doc, name="Create View Filters"): - sel_cat = wndw._categories.SelectedItem["Value"] - sel_par = wndw._list_box1.SelectedItem["Value"] - categories = List[DB.ElementId]() - categories.Add(sel_cat._cat.Id) - sf = solid_fill_pattern_id(new_doc) - for i, element in enumerate(wndw._list_box2.Items): - item = wndw._list_box2.Items[i]["Value"] - - # Assign color filled region - ogs = DB.OverrideGraphicSettings().Dispose() - ogs = DB.OverrideGraphicSettings() - color = DB.Color(item._n1, item._n2, item._n3) - ogs.SetSurfaceForegroundPatternColor(color) - ogs.SetCutForegroundPatternColor(color) - ogs.SetSurfaceForegroundPatternId(sf) - ogs.SetCutForegroundPatternId(sf) - - # filter naming - filter_name = (sel_cat._name + " / " + sel_par._name + " - " + item._value) - filter_name = filter_name.strip("{}[]:\|?/<>*") - - # Create filter - parameter_id = DB.ElementId(sel_par._rl_par.Id.IntegerValue) - param_storage_type = sel_par._rl_par.StorageType - if param_storage_type == DB.StorageType.Double: - value = float(sub("[^-\d|.]", "", item._value)) - if version > 2021: - value_to_internal = DB.UnitUtils.ConvertToInternalUnits( - value, sel_par._rl_par.GetUnitTypeId() - ) - else: - value_to_internal = DB.UnitUtils.ConvertToInternalUnits( - value, sel_par._rl_par.DisplayUnitType - ) - equals_rule = DB.ParameterFilterRuleFactory.CreateEqualsRule( - parameter_id, value_to_internal, 0.5 - ) - elif param_storage_type == DB.StorageType.ElementId: - equals_rule = DB.ParameterFilterRuleFactory.CreateEqualsRule( - parameter_id, item._value - ) - elif param_storage_type == DB.StorageType.Integer: - value = int(sub("[^0-9]", "", item._value)) - equals_rule = DB.ParameterFilterRuleFactory.CreateEqualsRule( - parameter_id, value - ) - elif param_storage_type == DB.StorageType.String: - try: - equals_rule = ( - DB.ParameterFilterRuleFactory.CreateEqualsRule( - parameter_id, item._value - ) - ) - except TypeError: # different method in versions earlier than R2023 - equals_rule = ( - DB.ParameterFilterRuleFactory.CreateEqualsRule( - parameter_id, item._value, True - ) - ) - else: - alert(msg="Filter Creation for this Parameter type is not supported: {}".format(sel_par._rl_par.StorageType), title="Error") - break - elem_filter = DB.ElementParameterFilter(equals_rule) - fltr = DB.ParameterFilterElement.Create( - new_doc, filter_name, categories, elem_filter - ) - view.AddFilter(fltr.Id) - view.SetFilterOverrides(fltr.Id, ogs) + ogs = OverrideGraphicSettings().Dispose() + ogs = OverrideGraphicSettings() + collector = FilteredElementCollector(new_doc, view.Id).WhereElementIsNotElementType().WhereElementIsViewIndependent().ToElementIds() + t = Transaction(new_doc, "Reset colors in elements") + t.Start() + try: + #Get and ResetView Filters + sel_cat = wndw._categories.SelectedItem['Value'] + sel_par = wndw._listBox1.SelectedItem['Value'] + filter_name = sel_cat._name + "/" + filters = view.GetFilters() + if len(filters) != 0: + for filt_id in filters: + filt_ele = new_doc.GetElement(filt_id) + if filt_ele.Name.StartsWith(filter_name): + view.RemoveFilter(filt_id) + try: + new_doc.Delete(filt_id) + except: + pass + except Exception as e: + pass + #Reset visibility + for id in collector: + view.SetElementOverrides(id, ogs) + t.Commit() except Exception as e: - alert(msg="{}\nFilter Creation for this Parameter type is not supported: {}".format(e, sel_par._rl_par.StorageType), title="Error") pass - + def GetName(self): - return "Create Filters" - + return "Reset colors in elements" -class CreateLegend(UI.IExternalEventHandler): +class createLegend(IExternalEventHandler): def __init__(self): pass - + def Execute(self, uiapp): try: - new_doc = revit.DOCS.doc - # Get legend view - collector = ( - DB.FilteredElementCollector(new_doc).OfClass(DB.View).ToElements() - ) - - legends = [] + new_doc = uiapp.ActiveUIDocument.Document + #Get legend view + collector = FilteredElementCollector(new_doc).OfClass(Autodesk.Revit.DB.View).ToElements() + legends=[] for vw in collector: - if vw.ViewType == DB.ViewType.Legend: - legends.append(vw) + if vw.ViewType == ViewType.Legend: + legends.Add(vw) break - if len(legends) > 0: - # Duplicate existing legend - with revit.TransactionGroup(doc=new_doc, name="Create Legend"): - with revit.Transaction(doc=new_doc, name="Duplicate Legend"): - sel_cat = wndw._categories.SelectedItem["Value"] - sel_par = wndw._list_box1.SelectedItem["Value"] - new_id_legend = legends[0].Duplicate( - DB.ViewDuplicateOption.Duplicate - ) - new_legend = new_doc.GetElement(new_id_legend) - i = 1 - new_legend_name = ( - str( - "Color Legend {} for View {}".format( - (sel_cat._name + " / " + sel_par._name), - revit.DOCS.doc.ActiveView.Name, - ) - ) - .replace("{", "") - .replace("}", "") - ) - while True: - try: - new_legend.Name = str(new_legend_name + " - " + str(i)) + if len(legends)>0: + #Duplicate existing legend + t = Transaction(new_doc, "Create Legend") + t.Start() + trans = SubTransaction(new_doc) + trans.Start() + new_id_legend = legends[0].Duplicate(ViewDuplicateOption.Duplicate) + newLegend = new_doc.GetElement(new_id_legend) + i=1 + while True: + try: + newLegend.Name = "Color Legend " + str(i) + break + except: + i+=1 + if i == 1000: + break + trans.Commit() + old_all_ele = FilteredElementCollector(new_doc, legends[0].Id).ToElements() + ele_id_type = ElementId(0) + for ele in old_all_ele: + if ele.Id.IntegerValue != newLegend.Id.IntegerValue and ele.Category != None: + if isinstance(ele, TextNote): + ele_id_type = ele.GetTypeId() + break + if ele_id_type.IntegerValue == 0: + #Get any text in model + all_text_notes = FilteredElementCollector(new_doc).OfClass(TextNoteType).ToElements() + for ele in all_text_notes: + ele_id_type = ele.Id + break + sel_cat = wndw._categories.SelectedItem['Value'] + sel_par = wndw._listBox1.SelectedItem['Value'] + list_max_X = [] + list_y = [] + #FilledRegionType + filled_type=[] + all_types = FilteredElementCollector(new_doc).OfClass(FilledRegionType).ToElements() + for ty in all_types: + pattern = new_doc.GetElement(ty.ForegroundPatternId) + if pattern != None: + if pattern.GetFillPattern().IsSolidFill: + if ty.ForegroundPatternColor.IsValid: + filled_type.Add(ty) break - except Exception: - i += 1 - if i == 100: - break - with revit.Transaction(doc=new_doc, name="Create Legend Graphic"): - ele_id_type = ( - DB.FilteredElementCollector(new_doc) - .OfClass(DB.TextNoteType) - .FirstElementId() - ) - list_max_X = [] - list_y = [] - # FilledRegionType - filled_type = [] - all_types = ( - DB.FilteredElementCollector(new_doc) - .OfClass(DB.FilledRegionType) - .ToElements() - ) - for type in all_types: - pattern = new_doc.GetElement(type.ForegroundPatternId) - if pattern is not None: - if pattern.GetFillPattern().IsSolidFill: - if type.ForegroundPatternColor.IsValid: - filled_type.append(type) - break - # Create Type if none is fill - if len(filled_type) == 0 and len(all_types) > 0: - it = 1 - # Duplicate existing fillregiontype - while True: - try: - new_type = all_types[0].Duplicate( - "Fill Region " + str(it) - ) - break - except: - it += 1 - if it == 100: - break - # Create pattern - it = 1 - while True: - try: - new_pattern = DB.FillPattern( - "Fill Pattern " + str(it), - DB.FillPatternTarget.Drafting, - DB.FillPatternHostOrientation.ToView, - float(0), - float(0.00001), - ) - new_elePat = DB.FillPatternElement.Create( - new_doc, new_pattern - ) - break - except: - it += 1 - if it == 100: - break - # Assign to type - new_type.ForegroundPatternId = new_elePat.Id - filled_type.append(new_type) - # Create Title - title_loc = DB.XYZ(0, 0, 0) - title_text = sel_cat._name + " / " + sel_par._name - legend_title = DB.TextNote.Create( - new_doc, new_legend.Id, title_loc, title_text, ele_id_type - ) - new_doc.Regenerate() - title_bbox = legend_title.get_BoundingBox(new_legend) - offset = (title_bbox.Max.Y + title_bbox.Min.Y) * 2 - # Create Text - for vw_item in wndw._list_box2.Items: - point = DB.XYZ(0, offset, 0) - index = wndw._list_box2.Items.IndexOf(vw_item) - if index != 0: - point = DB.XYZ(0, fin_coord_y, 0) - item = vw_item["Value"] - text_line = item._value - new_text = DB.TextNote.Create( - new_doc, new_legend.Id, point, text_line, ele_id_type - ) - new_doc.Regenerate() - prev_bbox = new_text.get_BoundingBox(new_legend) - offset = (prev_bbox.Max.Y - prev_bbox.Min.Y) * 0.25 - fin_coord_y = prev_bbox.Min.Y - offset - list_max_X.append(prev_bbox.Max.X) - list_y.append(fin_coord_y + offset) - height = (prev_bbox.Max.Y - prev_bbox.Min.Y) * 0.8 - ini_x = max(list_max_X) - ogs = DB.OverrideGraphicSettings() - # Create filled color region - for indx, elem in enumerate(list_y): - coord_y = elem - item = wndw._list_box2.Items[indx]["Value"] - point0 = DB.XYZ(ini_x, coord_y, 0) - point1 = DB.XYZ(ini_x, coord_y + height, 0) - point2 = DB.XYZ(ini_x * 2, coord_y + height, 0) - point3 = DB.XYZ(ini_x * 2, coord_y, 0) - line01 = DB.Line.CreateBound(point0, point1) - line12 = DB.Line.CreateBound(point1, point2) - line23 = DB.Line.CreateBound(point2, point3) - line30 = DB.Line.CreateBound(point3, point0) - list_curveLoops = List[DB.CurveLoop]() - curveLoops = DB.CurveLoop() - curveLoops.Append(line01) - curveLoops.Append(line12) - curveLoops.Append(line23) - curveLoops.Append(line30) - list_curveLoops.Add(curveLoops) - reg = DB.FilledRegion.Create( - new_doc, - filled_type[0].Id, - new_legend.Id, - list_curveLoops, - ) - # Assign color filled region - color = DB.Color(item._n1, item._n2, item._n3) - # ogs.SetProjectionLineColor(color) - ogs.SetSurfaceForegroundPatternColor(color) - ogs.SetCutForegroundPatternColor(color) - # ogs.SetProjectionLinePatternId(DB.ElementId(-1)) - new_legend.SetElementOverrides(reg.Id, ogs) + #Create Type if none is fill + if len(filled_type) == 0 and len(all_types) > 0: + it = 1 + #Duplicate existing fillregiontype + while True: + try: + new_type = all_types[0].Duplicate("Fill Region " + str(it)) + break + except: + it +=1 + if it == 100: + break + #Create pattern + it = 1 + while True: + try: + new_pattern = FillPattern("Fill Pattern " + str(it), FillPatternTarget.Drafting, FillPatternHostOrientation.ToView, float(0), float(0.00001)) + new_elePat = FillPatternElement.Create(new_doc, new_pattern) + break + except: + it +=1 + if it == 100: + break + #Assign to type + new_type.ForegroundPatternId = new_elePat.Id + filled_type.Add(new_type) + #Create Text + for vw_item in wndw._listBox2.Items: + punto = XYZ(0,0,0) + index = wndw._listBox2.Items.IndexOf(vw_item) + if index !=0: + punto = XYZ(0,fin_coord_y,0) + item = vw_item['Value'] + text_line = sel_cat._name + "/" + sel_par._name + " - " + item._value + new_text = TextNote.Create(new_doc, newLegend.Id, punto, text_line, ele_id_type) + new_doc.Regenerate() + prev_bbox = new_text.get_BoundingBox(newLegend) + offset = (prev_bbox.Max.Y - prev_bbox.Min.Y)*0.25 + fin_coord_y = prev_bbox.Min.Y - offset + list_max_X.Add(prev_bbox.Max.X) + list_y.Add(fin_coord_y + offset) + height = prev_bbox.Max.Y - prev_bbox.Min.Y + ini_x = max(list_max_X) + ogs = OverrideGraphicSettings() + #Create filled color region + for indx in range(len(list_y)): + coord_y = list_y[indx] + item = wndw._listBox2.Items[indx]['Value'] + point0 = XYZ(ini_x, coord_y, 0) + point1 = XYZ(ini_x, coord_y + height, 0) + point2 = XYZ(ini_x *1.5, coord_y + height, 0) + point3 = XYZ(ini_x *1.5, coord_y, 0) + line01 = Line.CreateBound(point0,point1) + line12= Line.CreateBound(point1,point2) + line23 = Line.CreateBound(point2,point3) + line30 = Line.CreateBound(point3,point0) + list_curveLoops = List[CurveLoop]() + curveLoops = CurveLoop() + curveLoops.Append(line01) + curveLoops.Append(line12) + curveLoops.Append(line23) + curveLoops.Append(line30) + list_curveLoops.Add(curveLoops) + reg = FilledRegion.Create(new_doc, filled_type[0].Id, newLegend.Id, list_curveLoops) + #Assign color filled region + color = Autodesk.Revit.DB.Color(item._n1, item._n2, item._n3) + ogs.SetProjectionLineColor(color) + ogs.SetSurfaceForegroundPatternColor(color); + ogs.SetCutForegroundPatternColor(color); + ogs.SetProjectionLinePatternId(ElementId(-1)); + newLegend.SetElementOverrides(reg.Id, ogs) + t.Commit() else: - task2 = UI.TaskDialog("Color Elements by Parameter Value") + task2 = Autodesk.Revit.UI.TaskDialog("Color Elements by Parameter") task2.MainInstruction = "In order to create a new legend, you need to have at least one. Please, create a legend view." wndw.TopMost = False task2.Show() wndw.TopMost = True - except Exception: + except Exception as e: pass - def GetName(self): return "Create Legend" - - -class ValuesInfo: +class createFilters(IExternalEventHandler): + def __init__(self): + pass + + def Execute(self, uiapp): + try: + new_doc = uiapp.ActiveUIDocument.Document + view = getActiveView(new_doc) + if view != 0: + dict_filters = {} + for filt_Id in view.GetFilters(): + filter_ele = new_doc.GetElement(filt_Id) + dict_filters.Add(filter_ele.Name, filt_Id) + #Get rules apply in document + dict_rules = {} + iterator = FilteredElementCollector(new_doc).OfClass(Autodesk.Revit.DB.ParameterFilterElement).GetElementIterator() + while iterator.MoveNext(): + ele = iterator.Current + dict_rules.Add(ele.Name, ele.Id) + with Transaction(new_doc, "Create View Filters") as t: + t.Start() + sel_cat = wndw._categories.SelectedItem['Value'] + sel_par = wndw._listBox1.SelectedItem['Value'] + parameter_id = sel_par._rl_par.Id + param_storage_type = sel_par._rl_par.StorageType + categories = List[ElementId]() + categories.Add(sel_cat._cat.Id) + sf = self.solid_fill_pattern_id(new_doc) + items_listbox = wndw._listBox2.Items + for i, element in enumerate(items_listbox): + item = wndw._listBox2.Items[i]['Value'] + # Assign color filled region + ogs = OverrideGraphicSettings().Dispose() + ogs = OverrideGraphicSettings() + color = Autodesk.Revit.DB.Color(item._n1, item._n2, item._n3) + ogs.SetSurfaceForegroundPatternColor(color) + ogs.SetCutForegroundPatternColor(color) + ogs.SetSurfaceForegroundPatternId(sf) + ogs.SetCutForegroundPatternId(sf) + #Get filters apply to view + filter_name = sel_cat._name + "/" + sel_par._name + " - " + item._value + filter_name = filter_name.strip("{}[]:\|?/<>*") + if dict_filters.ContainsKey(filter_name) or dict_rules.ContainsKey(filter_name): + if dict_rules.ContainsKey(filter_name) and not dict_filters.ContainsKey(filter_name): + view.AddFilter(dict_rules[filter_name]) + view.SetFilterOverrides(dict_rules[filter_name], ogs) + else: + #Reassign filter + view.SetFilterOverrides(dict_filters[filter_name], ogs) + else: + # Create filter + if param_storage_type == StorageType.Double: + if item._value =="None" or len(item.values_double) == 0: + equals_rule = ParameterFilterRuleFactory.CreateEqualsRule(parameter_id, "" , 0.001) + else: + minimo = min(item.values_double) + maximo = max(item.values_double) + avg_values = (maximo+minimo)/2 + equals_rule = ParameterFilterRuleFactory.CreateEqualsRule(parameter_id, avg_values, math.fabs(avg_values-minimo)+0.001) + elif param_storage_type == StorageType.ElementId: + if item._value =="None": + prevalue = ElementId.InvalidElementId + else: + prevalue = item._par.AsElementId() + equals_rule = ParameterFilterRuleFactory.CreateEqualsRule(parameter_id, prevalue) + elif param_storage_type == StorageType.Integer: + if item._value =="None": + prevalue = 0 + else: + prevalue = item._par.AsInteger() + equals_rule = ParameterFilterRuleFactory.CreateEqualsRule(parameter_id, prevalue) + elif param_storage_type == StorageType.String: + if item._value == "None": + prevalue = "" + else: + prevalue = item._value + if version > 2023: + equals_rule = ParameterFilterRuleFactory.CreateEqualsRule(parameter_id, prevalue) + else: + equals_rule = ParameterFilterRuleFactory.CreateEqualsRule(parameter_id, prevalue, True) + else: + task2 = Autodesk.Revit.UI.TaskDialog("Color Elements by Parameter") + task2.MainInstruction = "Creation of filters for this type of parameter is not supported." + wndw.TopMost = False + task2.Show() + wndw.TopMost = True + break + try: + elem_filter = ElementParameterFilter(equals_rule) + fltr = Autodesk.Revit.DB.ParameterFilterElement.Create(new_doc, filter_name, categories, elem_filter) + view.AddFilter(fltr.Id) + view.SetFilterOverrides(fltr.Id, ogs) + except Exception as e: + task2 = Autodesk.Revit.UI.TaskDialog("Color Elements by Parameter") + task2.MainInstruction = "View filters were not created. The selected parameter is not exposed by Revit and rules cannot be created." + # + str(e) + '\nError on line {}'.format(sys.exc_info()[-1].tb_lineno) + wndw.TopMost = False + task2.Show() + wndw.TopMost = True + break + t.Commit() + except Exception as e: + task2 = Autodesk.Revit.UI.TaskDialog("Color Elements by Parameter") + task2.MainInstruction = "Error in Filter Creation:\n" + str(e) + '\nError on line {}'.format(sys.exc_info()[-1].tb_lineno) + wndw.TopMost = False + task2.Show() + wndw.TopMost = True + def solid_fill_pattern_id(self, new_doc): + solid_fill_id = None + fillpatterns = FilteredElementCollector(new_doc).OfClass(FillPatternElement) + for pat in fillpatterns: + if pat.GetFillPattern().IsSolidFill: + solid_fill_id = pat.Id + break + return solid_fill_id + def GetName(self): + return "Create Filters" +class values_info(): def __init__(self, para, val, id, n1, n2, n3): self._par = para self._value = val - self._name = para.Definition.Name - self._eleId = List[DB.ElementId]() + self._name = strip_accents(para.Definition.Name) + self._eleId = List[ElementId]() self._eleId.Add(id) self._n1 = n1 self._n2 = n2 self._n3 = n3 self._colour = Color.FromArgb(self._n1, self._n2, self._n3) + self.values_double = [] + if para.StorageType == StorageType.Double: + self.values_double.Add(para.AsDouble()) + elif para.StorageType == StorageType.ElementId: + self.values_double.Add(para.AsElementId()) - -class ParaInfo: +class para_info(): def __init__(self, type, para): self._type = type self._rl_par = para self._par = para.Definition - self._name = para.Definition.Name + self._name = strip_accents(para.Definition.Name) - -class CategInfo: +class categ_info(): def __init__(self, cat, param): - self._name = cat.Name + self._name = strip_accents(cat.Name) self._cat = cat self._intId = cat.Id.IntegerValue self._par = param - -def get_active_view(ac_doc): - sel_view = ac_doc.ActiveView - if ( - sel_view.ViewType == DB.ViewType.ProjectBrowser - or sel_view.ViewType == DB.ViewType.SystemBrowser - ): - sel_view = ac_doc.GetElement(uidoc.GetOpenUIViews()[0].ViewId) - if not sel_view.CanUseTemporaryVisibilityModes(): - task2 = UI.TaskDialog("Color Elements by Parameter Value") - task2.MainInstruction = ( - "Visibility settings cannot be modified in " - + str(sel_view.ViewType) - + " views. Please, change your current view." - ) +def getActiveView(ac_doc): + sel_View = ac_doc.ActiveView + if sel_View.ViewType == ViewType.ProjectBrowser or sel_View.ViewType == ViewType.SystemBrowser: + sel_View = ac_doc.GetElement(uidoc.GetOpenUIViews()[0].ViewId) + if not sel_View.CanUseTemporaryVisibilityModes(): + task2 = Autodesk.Revit.UI.TaskDialog("Color Elements by Parameter") + task2.MainInstruction = "Visibility settings cannot be modified in " + str(sel_View.ViewType) + " views. Please, change your current view." try: wndw.TopMost = False except: @@ -635,389 +500,335 @@ def get_active_view(ac_doc): pass return 0 else: - return sel_view + return sel_View - -def get_value_par(para): +def getValuePar(para): value = "" - if para.StorageType == DB.StorageType.Double: - value = para.AsValueString() - elif para.StorageType == DB.StorageType.ElementId: - id_val = para.AsElementId() - if id_val.IntegerValue >= 0: - value = DB.Element.Name.__get__(doc.GetElement(id_val)) - else: - value = "None" - elif para.StorageType == DB.StorageType.Integer: - if version > 2021: - type = para.Definition.GetDataType() - if DB.SpecTypeId.Boolean.YesNo == type: - if para.AsInteger() == 1: - value = "True" - else: - value = "False" + if para.HasValue: + if para.StorageType == StorageType.Double: + value = para.AsValueString() + elif para.StorageType == StorageType.ElementId: + id_val = para.AsElementId() + if id_val.IntegerValue >= 0: + value = Element.Name.__get__(doc.GetElement(id_val)) else: - value = para.AsValueString() - else: - type = para.Definition.ParameterType - if DB.ParameterType.YesNo == type: - if para.AsInteger() == 1: - value = "True" + value ="None" + elif para.StorageType == StorageType.Integer: + if version > 2021: + type = para.Definition.GetDataType() + if SpecTypeId.Boolean.YesNo == type: + if para.AsInteger()==1: + value = "True" + else: + value = "False" else: - value = "False" + value = para.AsValueString() else: - value = para.AsValueString() - elif para.StorageType == DB.StorageType.String: - value = para.AsString() + type = para.Definition.ParameterType + if ParameterType.YesNo == type: + if para.AsInteger()==1: + value = "True" + else: + value = "False" + else: + value = para.AsValueString() + elif para.StorageType == StorageType.String: + value = para.AsString() + else: + value = "None" else: - value = "N/A" + value = "None" return value - def strip_accents(text): - return "".join(char for char in normalize("NFKD", text) if category(char) != "Mn") - + return ''.join(char for char in unicodedata.normalize('NFKD', text) if unicodedata.category(char) != 'Mn') -def random_color(): +def randomColor(): r = randint(0, 230) g = randint(0, 230) b = randint(0, 230) - return r, g, b - + return r,g,b -def get_range_of_values(category, param, new_view): - for sample_bic in Enum.GetValues(DB.BuiltInCategory): +def getRangeOfValues(category, param, new_view): + for sample_bic in System.Enum.GetValues(BuiltInCategory): if category._intId == int(sample_bic): bic = sample_bic break - collector = ( - DB.FilteredElementCollector(doc, new_view.Id) - .OfCategory(bic) - .WhereElementIsNotElementType() - .WhereElementIsViewIndependent() - .ToElements() - ) - list_values = [] - # Iterar todos los elementos y conseguir valores unicos + collector = FilteredElementCollector(doc, new_view.Id).OfCategory(bic).WhereElementIsNotElementType().WhereElementIsViewIndependent().ToElements() + list_values=[] + #Iterar todos los elementos y conseguir valores unicos for ele in collector: ele_par = ele if param._type == 1: ele_par = doc.GetElement(ele.GetTypeId()) for pr in ele_par.Parameters: if pr.Definition.Name == param._par.Name: - value = get_value_par(pr) - if value == "" or value is None: - value = "N/A" - match = [x for x in list_values if x._value == value] + valor = getValuePar(pr) + if valor == "" or valor == None: + valor = "None" + match = [x for x in list_values if x._value == valor] if len(match) > 0: match[0]._eleId.Add(ele.Id) + if pr.StorageType == StorageType.Double: + match[0].values_double.Add(pr.AsDouble()) else: while True: - r, g, b = random_color() - match = [ - x - for x in list_values - if x._n1 == r and x._n2 == g and x._n3 == b - ] + r,g,b=randomColor() + match = [x for x in list_values if x._n1 == r and x._n2 == g and x._n3 == b] if len(match) == 0: - val = ValuesInfo(pr, value, ele.Id, r, g, b) - list_values.append(val) + val = values_info(pr, valor, ele.Id, r, g, b) + list_values.Add(val) break break - copy = [x for x in list_values if x._value == "N/A"] + copy = [x for x in list_values if x._value == "None"] if len(copy) > 0: - list_values.remove(copy[0]) - # Ordenar - list_values.sort(key=lambda x: x._value, reverse=False) + list_values.Remove(copy[0]) + #Ordenar + list_values = sorted(list_values, key=lambda x: x._value, reverse=False) + #list_values.sort(key=lambda x: x._value, reverse=False) if len(list_values) > 1: try: first_value = list_values[0]._value - indx_del = get_index_units(first_value) - if indx_del == 0: + indx_del = getIndexUnits(first_value) + if indx_del ==0: list_values = sorted(list_values, key=lambda x: float(x._value)) - elif indx_del < len(first_value) and indx_del != -1: - list_values = sorted( - list_values, key=lambda x: float(x._value[:-indx_del]) - ) - except Exception: + elif indx_del < len(first_value) and indx_del !=-1: + list_values = sorted(list_values, key=lambda x: float(x._value[:-indx_del])) + except Exception as e: pass if len(copy) > 0 and len(copy[0]._eleId) > 0: - list_values.append(copy[0]) + list_values.Add(copy[0]) return list_values - -def get_used_categories_and_parameters(cat_exc, acti_view): - # Get All elements and filter unneeded - collector = ( - DB.FilteredElementCollector(doc, acti_view.Id) - .WhereElementIsNotElementType() - .WhereElementIsViewIndependent() - .ToElements() - ) - +def getCategoriesAndParametersInUsed(cat_exc, acti_view): + #Get All elements and filter unneeded + collector = FilteredElementCollector(doc, acti_view.Id).WhereElementIsNotElementType().WhereElementIsViewIndependent().ToElements() list_cat = [] for ele in collector: - if ele.Category is not None: + if ele.Category != None: current_int_cat_id = ele.Category.Id.IntegerValue - if current_int_cat_id not in cat_exc: + if not current_int_cat_id in cat_exc and current_int_cat_id < -1: if not any(x._intId == current_int_cat_id for x in list_cat): - list_parameters = [] - # Instance parameters + list_parameters=[] + #Instance parameters for par in ele.Parameters: - if ( - par.Definition.BuiltInParameter - != DB.BuiltInParameter.ELEM_CATEGORY_PARAM - and par.Definition.BuiltInParameter - != DB.BuiltInParameter.ELEM_CATEGORY_PARAM_MT - ): - list_parameters.append(ParaInfo(0, par)) + if par.Definition.BuiltInParameter != BuiltInParameter.ELEM_CATEGORY_PARAM and par.Definition.BuiltInParameter != BuiltInParameter.ELEM_CATEGORY_PARAM_MT: + list_parameters.Add(para_info(0, par)) typ = ele.Document.GetElement(ele.GetTypeId()) - # Type parameters - if typ is not None: + #Type parameters + if typ != None: for par in typ.Parameters: - if ( - par.Definition.BuiltInParameter - is not DB.BuiltInParameter.ELEM_CATEGORY_PARAM - and par.Definition.BuiltInParameter - is not DB.BuiltInParameter.ELEM_CATEGORY_PARAM_MT - ): - list_parameters.append(ParaInfo(1, par)) - # Sort and add - list_parameters.sort(key=lambda x: x._name.upper(), reverse=False) - list_cat.append(CategInfo(ele.Category, list_parameters)) - list_cat.sort(key=lambda x: x._name, reverse=False) + if par.Definition.BuiltInParameter != BuiltInParameter.ELEM_CATEGORY_PARAM and par.Definition.BuiltInParameter != BuiltInParameter.ELEM_CATEGORY_PARAM_MT: + list_parameters.Add(para_info(1, par)) + #Sort and add + list_parameters = sorted(list_parameters, key=lambda x: x._name.upper(), reverse=False) + #list_parameters.sort(key=lambda x: x._name.upper(), reverse=False) + list_cat.Add(categ_info(ele.Category,list_parameters)) + #list_cat.sort(key=lambda x: x._name, reverse=False) + list_cat = sorted(list_cat, key=lambda x: x._name, reverse=False) return list_cat - - -class FormCats(Form): - def __init__( - self, categories, ext_ev, uns_ev, s_view, reset_event, ev_legend, ev_filter - ): +class Form_cats(Form): + def __init__(self, categories, ext_ev, uns_ev, s_view, reset_event, ev_legend, ev_filters): + self.Font = Font("Arial", 15, FontStyle.Regular, GraphicsUnit.Pixel) self.IsOpen = 1 + self.filter_ev = ev_filters self.legend_ev = ev_legend - self.filter_ev = ev_filter self.reset_ev = reset_event self.crt_view = s_view self.event = ext_ev self.uns_event = uns_ev self.uns_event.Raise() self.categs = categories + list_par = [] + list_values = [] self.width_par = 1 - self._categories_table_data = DataTable("Data") - self._categories_table_data.Columns.Add("Key", String) - self._categories_table_data.Columns.Add("Value", Object) + self._tableData = DataTable("Data") + self._tableData.Columns.Add("Key", System.String) + self._tableData.Columns.Add("Value", System.Object) names = [x._name for x in self.categs] - self._categories_table_data.Rows.Add("Select a Category Here!", 0) - [ - self._categories_table_data.Rows.Add(key_, value_) - for key_, value_ in zip(names, self.categs) - ] + self._tableData.Rows.Add("Select a Category Here!", 0 ) + [self._tableData.Rows.Add(key_, value_ ) for key_, value_ in zip(names, self.categs)] self.out = [] self.InitializeComponent() - + def InitializeComponent(self): - self._categories = ComboBox() - self._list_box1 = CheckedListBox() - self._list_box2 = ListBox() - self._button1 = Button() - self._button2 = Button() - self._button3 = Button() - self._button4 = Button() - self._button5 = Button() - self._button6 = Button() - self._txt_block2 = Label() - self._txt_block3 = Label() - self._txt_block4 = Label() - self._txt_block5 = Label() + self._categories = System.Windows.Forms.ComboBox() + self._listBox1 = System.Windows.Forms.CheckedListBox() + self._listBox2 = System.Windows.Forms.ListBox() + self._button1 = System.Windows.Forms.Button() + self._button2 = System.Windows.Forms.Button() + self._button3 = System.Windows.Forms.Button() + self._button4 = System.Windows.Forms.Button() + self._button5 = System.Windows.Forms.Button() + self._button6 = System.Windows.Forms.Button() + self._txtBlock2 = System.Windows.Forms.Label() + self._txtBlock3 = System.Windows.Forms.Label() + self._txtBlock4 = System.Windows.Forms.Label() + self._txtBlock5 = System.Windows.Forms.Label() + self.toolTip1 = System.Windows.Forms.ToolTip() self.SuspendLayout() - # + # # TextBlock2 - # - self._txt_block2.Anchor = ( - AnchorStyles.Bottom - | AnchorStyles.Left - ) - self._txt_block2.Location = Point(12, 10) - self._txt_block2.Name = "txtBlock2" - self._txt_block2.Size = Size(120, 20) - self._txt_block2.Text = "Category:" - # + # + self._txtBlock2.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left + self._txtBlock2.Location = System.Drawing.Point(12, 2) + self._txtBlock2.Name = "txtBlock2" + self._txtBlock2.Size = System.Drawing.Size(120, 25) + self._txtBlock2.Text = "Category:" + self.toolTip1.SetToolTip(self._txtBlock2, "Select a category to start coloring.") + # # comboBox1 Cat - # - self._categories.Anchor = ( - AnchorStyles.Top - | AnchorStyles.Bottom - | AnchorStyles.Left - | AnchorStyles.Right - ) - self._categories.Location = Point(12, 27) + # + self._categories.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right + self._categories.Location = System.Drawing.Point(12, 27) self._categories.Name = "dropDown" - self._categories.DataSource = self._categories_table_data + self._categories.DataSource = self._tableData self._categories.DisplayMember = "Key" - self._categories.Size = Size(310, 244) + self._categories.Size = System.Drawing.Size(310, 244) self._categories.DropDownWidth = 150 self._categories.DropDownStyle = ComboBoxStyle.DropDownList - self._categories.SelectedIndexChanged += self.update_filter - # + self._categories.SelectedIndexChanged += self.UpdateFilter + self.toolTip1.SetToolTip(self._categories, "Select a category to start coloring.") + # # TextBlock3 - # - self._txt_block3.Anchor = ( - AnchorStyles.Bottom - | AnchorStyles.Left - ) - self._txt_block3.Location = Point(12, 53) - self._txt_block3.Name = "txtBlock3" - self._txt_block3.Size = Size(120, 13) - self._txt_block3.Text = "Parameters:" - # + # + self._txtBlock3.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left + self._txtBlock3.Location = System.Drawing.Point(12, 57) + self._txtBlock3.Name = "txtBlock3" + self._txtBlock3.Size = System.Drawing.Size(120, 20) + self._txtBlock3.Text = "Parameters:" + self.toolTip1.SetToolTip(self._txtBlock3, "Select a parameter to color elements based on its value.") + # # checkedListBox1 - # - self._list_box1.Anchor = ( - AnchorStyles.Top - | AnchorStyles.Left - | AnchorStyles.Bottom - | AnchorStyles.Right - ) - self._list_box1.FormattingEnabled = True - self._list_box1.CheckOnClick = True - self._list_box1.HorizontalScrollbar = True - self._list_box1.Location = Point(12, 70) - self._list_box1.Name = "checkedListBox1" - self._list_box1.DisplayMember = "Key" - self._list_box1.Size = Size(310, 170) - self._list_box1.ItemCheck += self.check_item - # + # + self._listBox1.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right + self._listBox1.FormattingEnabled = True + self._listBox1.CheckOnClick = True + self._listBox1.HorizontalScrollbar = True + self._listBox1.Location = System.Drawing.Point(12, 80) + self._listBox1.Name = "checkedListBox1" + self._listBox1.DisplayMember = "Key" + self._listBox1.Size = System.Drawing.Size(310, 158) + self._listBox1.ItemCheck += self.checkItem + self.toolTip1.SetToolTip(self._listBox1, "Select a parameter to color elements based on its value.") + # # TextBlock4 - # - self._txt_block4.Anchor = ( - AnchorStyles.Bottom - | AnchorStyles.Left - ) - self._txt_block4.Location = Point(12, 245) - self._txt_block4.Name = "txtBlock4" - self._txt_block4.Size = Size(120, 13) - self._txt_block4.Text = "Values:" - # + # + self._txtBlock4.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left + self._txtBlock4.Location = System.Drawing.Point(12, 238) + self._txtBlock4.Name = "txtBlock4" + self._txtBlock4.Size = System.Drawing.Size(120, 23) + self._txtBlock4.Text = "Values:" + self.toolTip1.SetToolTip(self._txtBlock4, "Reassign colors by clicking on their value.") + # # TextBlock5 - # - self._txt_block5.Anchor = ( - AnchorStyles.Bottom - | AnchorStyles.Left - ) - self._txt_block5.Location = Point(12, 557) - self._txt_block5.Name = "txtBlock5" - self._txt_block5.Size = Size(310, 27) - self._txt_block5.Text = ( - "*Spaces may require you to apply a color scheme in the view." - ) - self._txt_block5.ForeColor = Color.Red - self._txt_block5.Font = Font("Arial", 8, FontStyle.Underline) - self._txt_block5.Visible = False - # + # + self._txtBlock5.Anchor = System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left + self._txtBlock5.Location = System.Drawing.Point(12, 585) + self._txtBlock5.Name = "txtBlock5" + self._txtBlock5.Size = System.Drawing.Size(310, 27) + self._txtBlock5.Text = "*Spaces may require a color scheme in the view." + self._txtBlock5.ForeColor = Color.Red + self._txtBlock5.Font = Font("Arial", 8, FontStyle.Underline) + self._txtBlock5.Visible = False + # # checkedListBox2 - # - self._list_box2.Anchor = ( - AnchorStyles.Top - | AnchorStyles.Left - | AnchorStyles.Bottom - | AnchorStyles.Right - ) - self._list_box2.FormattingEnabled = True - self._list_box2.HorizontalScrollbar = True - self._list_box2.Location = Point(12, 262) - self._list_box2.Name = "listBox2" - self._list_box2.DisplayMember = "Key" - self._list_box2.Size = Size(310, 280) - self._list_box2.DrawMode = DrawMode.OwnerDrawFixed - self._list_box2.DrawItem += self.colour_item - # + # + self._listBox2.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right + self._listBox2.FormattingEnabled = True + self._listBox2.HorizontalScrollbar = True + self._listBox2.Location = System.Drawing.Point(12, 262) + self._listBox2.Name = "listBox2" + self._listBox2.DisplayMember = "Key" + self._listBox2.DrawMode = DrawMode.OwnerDrawFixed + self._listBox2.DrawItem += self.ColourItem + self.new_fnt = Font(self.Font.FontFamily, self.Font.Size-4, FontStyle.Bold) + g = self._listBox2.CreateGraphics() + self._listBox2.ItemHeight = int(g.MeasureString("Sample", self.new_fnt).Height) + self._listBox2.Size = System.Drawing.Size(310, 280) + self.toolTip1.SetToolTip(self._listBox2, "Reassign colors by clicking on their value.") + # # button1 - # - self._button1.Anchor = ( - AnchorStyles.Bottom - | AnchorStyles.Right - ) - self._button1.Location = Point(222, 592) + # + self._button1.Anchor = System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right + self._button1.Location = System.Drawing.Point(222, 602) self._button1.Name = "button1" - self._button1.Size = Size(100, 27) - self._button1.Text = "Apply Colors" + self._button1.Size = System.Drawing.Size(100, 27) + self._button1.Text = "Set Colors" self._button1.UseVisualStyleBackColor = True - self._button1.Click += self.button_1_click - # + self._button1.Click += self.Button1Click + self.toolTip1.SetToolTip(self._button1, "Apply the colors from each value in your Revit view.") + # # button2 - # - self._button2.Anchor = ( - AnchorStyles.Bottom - | AnchorStyles.Right - ) - self._button2.Location = Point(12, 592) + # + self._button2.Anchor = System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left + self._button2.Location = System.Drawing.Point(12, 602) self._button2.Name = "button2" - self._button2.Size = Size(100, 27) - self._button2.Text = "Reset All Colors" + self._button2.Size = System.Drawing.Size(100, 27) + self._button2.Text = "Reset" self._button2.UseVisualStyleBackColor = True - self._button2.Click += self.button_2_click - # + self._button2.Click += self.Button2Click + self.toolTip1.SetToolTip(self._button2, "Reset the colors in your Revit view to its initial stage.") + # # button3 - # - self._button3.Anchor = ( - AnchorStyles.Bottom - | AnchorStyles.Right - ) - self._button3.Location = Point(11, 538) + # + self._button3.Anchor = System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right + self._button3.Location = System.Drawing.Point(167, 538) self._button3.Name = "button3" - self._button3.Size = Size(156, 20) + self._button3.Size = System.Drawing.Size(156, 25) self._button3.Text = "Random Colors" self._button3.UseVisualStyleBackColor = True - self._button3.Click += self.button_3_click - # + self._button3.Click += self.Button3Click + self.toolTip1.SetToolTip(self._button3, "Reassign new random colors to all values.") + # # button4 - # - self._button4.Anchor = ( - AnchorStyles.Bottom - | AnchorStyles.Right - ) - self._button4.Location = Point(167, 538) + # + self._button4.Anchor = System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left + self._button4.Location = System.Drawing.Point(11, 538) self._button4.Name = "button4" - self._button4.Size = Size(156, 20) + self._button4.Size = System.Drawing.Size(156, 25) self._button4.Text = "Gradient Colors" self._button4.UseVisualStyleBackColor = True - self._button4.Click += self.button_4_click - # + self._button4.Click += self.Button4Click + self.toolTip1.SetToolTip(self._button4, "Based on the color of the first and last value,\nreassign gradients colors to all values.") + # # button5 - # - self._button5.Anchor = ( - AnchorStyles.Bottom - | AnchorStyles.Right - ) - self._button5.Location = Point(11, 558) + # + self._button5.Anchor = System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left + #self._button5.Location = System.Drawing.Point(167, 243) + self._button5.Location = System.Drawing.Point(11, 563) self._button5.Name = "button5" - self._button5.Size = Size(156, 20) - self._button5.Text = "Create a Legend" + self._button5.Size = System.Drawing.Size(156, 25) + self._button5.Text = "Create Legend" self._button5.UseVisualStyleBackColor = True - self._button5.Click += self.button_5_click - # + self._button5.Click += self.Button5Click + self.toolTip1.SetToolTip(self._button5, "Create a new legend view for all the values and their colors.") + # # button6 - # - self._button6.Anchor = ( - AnchorStyles.Bottom - | AnchorStyles.Right - ) - self._button6.Location = Point(167, 558) + # + self._button6.Anchor = System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right + #self._button5.Location = System.Drawing.Point(167, 243) + self._button6.Location = System.Drawing.Point(167, 563) self._button6.Name = "button6" - self._button6.Size = Size(156, 20) + self._button6.Size = System.Drawing.Size(156, 25) self._button6.Text = "Create View Filters" self._button6.UseVisualStyleBackColor = True - self._button6.Click += self.button_6_click - # - # Form - # + self._button6.Click += self.Button6Click + self.toolTip1.SetToolTip(self._button6, "Create view filters and rules for all the values and their colors.") + # + # Form24 + # self.TopMost = True self.ShowInTaskbar = False - self.ClientSize = Size(334, 630) + self.ClientSize = System.Drawing.Size(334, 642) self.MaximizeBox = 0 self.MinimizeBox = 0 self.CenterToScreen() - self.FormBorderStyle = FormBorderStyle.FixedSingle + self.FormBorderStyle = FormBorderStyle.Sizable + self.SizeGripStyle = System.Windows.Forms.SizeGripStyle.Show + self.ShowInTaskbar = True + self.MaximizeBox = True + self.MinimizeBox = True self.Controls.Add(self._button1) self.Controls.Add(self._button2) self.Controls.Add(self._button3) @@ -1025,264 +836,327 @@ def InitializeComponent(self): self.Controls.Add(self._button5) self.Controls.Add(self._button6) self.Controls.Add(self._categories) - self.Controls.Add(self._txt_block2) - self.Controls.Add(self._txt_block3) - self.Controls.Add(self._txt_block4) - self.Controls.Add(self._txt_block5) - self.Controls.Add(self._list_box1) - self.Controls.Add(self._list_box2) - self.Name = "Color Elements By Parameter Value" - self.Text = "Color Elements By Parameter Value" - script.get_script_path() - icon_filename = script.get_script_path() + ".\\icon.ico" - if not os.path.exists(icon_filename): - icon_filename = script.get_script_path() + ".\\icon.ico" - icon = Icon(icon_filename) - self.Icon = icon - self.Closing += self.closing_event + self.Controls.Add(self._txtBlock2) + self.Controls.Add(self._txtBlock3) + self.Controls.Add(self._txtBlock4) + self.Controls.Add(self._txtBlock5) + self.Controls.Add(self._listBox1) + self.Controls.Add(self._listBox2) + self.Name = "Color Elements By Parameter" + self.Text = "Color Elements By Parameter" + self.Closing += self.closingEvent self.ResumeLayout(False) - - def button_1_click(self, sender, e): - if self._list_box2.Items.Count > 0: + + def Button1Click(self, sender, e): + if self._listBox2.Items.Count > 0: self.event.Raise() - - def button_2_click(self, sender, e): + + def Button2Click(self, sender, e): self.reset_ev.Raise() - - def button_3_click(self, sender, e): - # Reassign Random colors + + def Button3Click(self, sender, e): + #Reassign Random colors try: - checkindex = self._list_box1.CheckedIndices + checkindex = self._listBox1.CheckedIndices for indx in checkindex: - self._list_box1.SetItemChecked(indx, False) - self._list_box1.SetItemChecked(indx, True) + self._listBox1.SetItemChecked(indx, False) + self._listBox1.SetItemChecked(indx, True) except: - pass - - def button_4_click(self, sender, e): - self._list_box2.SelectedIndexChanged -= self.list_selected_index_changed + pass + + def Button4Click(self, sender, e): + self._listBox2.SelectedIndexChanged -= self.lstselectedIndexChanged try: - list_values = [] - number_items = len(self._list_box2.Items) + list_values=[] + number_items = len(self._listBox2.Items) if number_items > 2: - st_color = self._list_box2.Items[0]["Value"]._colour - end_color = self._list_box2.Items[number_items - 1]["Value"]._colour - list_colors = self.get_gradient_colors(st_color, end_color, number_items) - for indx in range(len(self._list_box2.Items)): - item = self._list_box2.Items[indx]["Value"] + stColor = self._listBox2.Items[0]['Value']._colour + endColor = self._listBox2.Items[number_items-1]['Value']._colour + list_colors = self.getGradientColors(stColor, endColor, number_items) + for indx in range(len(self._listBox2.Items)): + item = self._listBox2.Items[indx]['Value'] item._n1 = abs(list_colors[indx][1]) item._n2 = abs(list_colors[indx][2]) item._n3 = abs(list_colors[indx][3]) item._colour = Color.FromArgb(item._n1, item._n2, item._n3) - list_values.append(item) - self._table_data3 = DataTable("Data") - self._table_data3.Columns.Add("Key", String) - self._table_data3.Columns.Add("Value", Object) + list_values.Add(item) + self._tableData3 = DataTable("Data") + self._tableData3.Columns.Add("Key", System.String) + self._tableData3.Columns.Add("Value", System.Object) vl_par = [x._value for x in list_values] - [ - self._table_data3.Rows.Add(key_, value_) - for key_, value_ in zip(vl_par, list_values) - ] - self._list_box2.DataSource = self._table_data3 - self._list_box2.DisplayMember = "Key" - self._list_box2.SelectedIndex = -1 - except Exception: + [self._tableData3.Rows.Add(key_, value_ ) for key_, value_ in zip(vl_par, list_values)] + self._listBox2.DataSource = self._tableData3 + self._listBox2.DisplayMember = "Key" + self._listBox2.SelectedIndex = -1 + except Exception as e: pass - self._list_box2.SelectedIndexChanged += self.list_selected_index_changed - - def button_5_click(self, sender, e): - if self._list_box2.Items.Count > 0: + self._listBox2.SelectedIndexChanged += self.lstselectedIndexChanged + + def Button5Click(self, sender, e): + if self._listBox2.Items.Count > 0: self.legend_ev.Raise() - - def button_6_click(self, sender, e): - if self._list_box2.Items.Count > 0: + + def Button6Click(self, sender, e): + if self._listBox2.Items.Count > 0: + self.reset_ev.Raise() self.filter_ev.Raise() - - def get_gradient_colors(self, start_color, end_color, steps): - aStep = float((end_color.A - start_color.A) / steps) - rStep = float((end_color.R - start_color.R) / steps) - gStep = float((end_color.G - start_color.G) / steps) - bStep = float((end_color.B - start_color.B) / steps) - colorList = [] + + def getGradientColors(self, startColor, endColor, steps): + aStep = float((endColor.A - startColor.A) / steps) + rStep = float((endColor.R - startColor.R) / steps) + gStep = float((endColor.G - startColor.G) / steps) + bStep = float((endColor.B - startColor.B) / steps) + colorList=[] for index in range(steps): - a = start_color.A + int(aStep * index) - 1 - r = start_color.R + int(rStep * index) - 1 - g = start_color.G + int(gStep * index) - 1 - b = start_color.B + int(bStep * index) - 1 + a = startColor.A + int(aStep * index)-1; + r = startColor.R + int(rStep * index)-1; + g = startColor.G + int(gStep * index)-1; + b = startColor.B + int(bStep * index)-1; if a < 0: - a = 0 + a=0 if r < 0: - r = 0 + r=0 if g < 0: - g = 0 + g=0 if b < 0: - b = 0 - colorList.append([a, r, g, b]) + b=0 + colorList.Add([a,r,g,b]) return colorList - - def closing_event(self, sender, e): + + def closingEvent(self, sender, e): self.IsOpen = 0 self.uns_event.Raise() - - def list_selected_index_changed(self, sender, e): - # Ask colour + + def lstselectedIndexChanged(self, sender, e): + #Ask colour if sender.SelectedIndex != -1: clr_dlg = ColorDialog() clr_dlg.AllowFullOpen = True if clr_dlg.ShowDialog() == DialogResult.OK: - sender.SelectedItem["Value"]._n1 = clr_dlg.Color.R - sender.SelectedItem["Value"]._n2 = clr_dlg.Color.G - sender.SelectedItem["Value"]._n3 = clr_dlg.Color.B - sender.SelectedItem["Value"]._colour = Color.FromArgb( - clr_dlg.Color.R, clr_dlg.Color.G, clr_dlg.Color.B - ) - self._list_box2.SelectedIndex = -1 - - def colour_item(self, sender, e): - cnt = e.Index - g = e.Graphics - text_device = sender.Items[e.Index]["Key"] - if cnt == self._list_box2.SelectedIndex: - color = Color.White - font_color = Color.Black - else: - color = sender.Items[e.Index]["Value"]._colour - font_color = Color.White - e.DrawBackground() - g.FillRectangle(SolidBrush(color), e.Bounds) - TextRenderer.DrawText( - g, text_device, Font("Arial", 9, FontStyle.Bold), e.Bounds, font_color - ) - e.DrawFocusRectangle() - - def check_item(self, sender, e): - # Only one element can be selected - for indx in range(self._list_box1.Items.Count): + sender.SelectedItem['Value']._n1 = clr_dlg.Color.R + sender.SelectedItem['Value']._n2 = clr_dlg.Color.G + sender.SelectedItem['Value']._n3 = clr_dlg.Color.B + sender.SelectedItem['Value']._colour = Color.FromArgb(clr_dlg.Color.R, clr_dlg.Color.G, clr_dlg.Color.B) + self._listBox2.SelectedIndex = -1 + + def ColourItem(self, sender, e): + try: + cnt = e.Index + g = e.Graphics + textDevice = sender.Items[e.Index]['Key'] + color = sender.Items[e.Index]['Value']._colour + if cnt == self._listBox2.SelectedIndex or color == Color.FromArgb(Color.White.R, Color.White.G, Color.White.B): + color = Color.White + font_color = Color.Black + else: + font_color = Color.White + wdth = g.MeasureString(textDevice, self.new_fnt).Width + 30 + if self._listBox2.Width < wdth and self._listBox2.HorizontalExtent < wdth: + self._listBox2.HorizontalExtent = wdth + e.DrawBackground() + g.FillRectangle(SolidBrush(color), e.Bounds) + TextRenderer.DrawText(g, textDevice, self.new_fnt, e.Bounds, font_color, TextFormatFlags.Left) + e.DrawFocusRectangle() + except: + pass + + def checkItem(self, sender, e): + #Only one element can be selected + for indx in range(self._listBox1.Items.Count): if indx != e.Index: - self._list_box1.SetItemChecked(indx, False) + self._listBox1.SetItemChecked(indx, False) try: - self._list_box2.SelectedIndexChanged -= self.list_selected_index_changed + self._listBox2.SelectedIndexChanged -= self.lstselectedIndexChanged except: pass - sel_cat = self._categories.SelectedItem["Value"] - sel_param = sender.Items[e.Index]["Value"] - if sel_cat is not None and sel_cat != 0: - self._table_data3 = DataTable("Data") - self._table_data3.Columns.Add("Key", String) - self._table_data3.Columns.Add("Value", Object) + sel_cat = self._categories.SelectedItem['Value'] + sel_param = sender.Items[e.Index]['Value'] + if sel_cat != None and sel_cat != 0: + self._tableData3 = DataTable("Data") + self._tableData3.Columns.Add("Key", System.String) + self._tableData3.Columns.Add("Value", System.Object) if e.NewValue == CheckState.Unchecked: - self._list_box2.DataSource = self._table_data3 - self._list_box2.DisplayMember = "Key" + self._listBox2.DataSource = self._tableData3 + self._listBox2.DisplayMember = "Key" else: - rng_val = get_range_of_values(sel_cat, sel_param, self.crt_view) + rng_val = getRangeOfValues(sel_cat, sel_param, self.crt_view) vl_par = [x._value for x in rng_val] - g = self._list_box2.CreateGraphics() - width = [ - int(g.MeasureString(x, self._list_box2.Font).Width) for x in vl_par - ] - self._list_box2.HorizontalExtent = max(width) + 50 - [ - self._table_data3.Rows.Add(key_, value_) - for key_, value_ in zip(vl_par, rng_val) - ] - self._list_box2.DataSource = self._table_data3 - self._list_box2.DisplayMember = "Key" - self._list_box2.SelectedIndex = -1 - self._list_box2.SelectedIndexChanged += self.list_selected_index_changed - - def update_filter(self, sender, e): - # Update param listbox - sel_cat = sender.SelectedItem["Value"] - self._table_data2 = DataTable("Data") - self._table_data2.Columns.Add("Key", String) - self._table_data2.Columns.Add("Value", Object) - self._table_data3 = DataTable("Data") - self._table_data3.Columns.Add("Key", String) - self._table_data3.Columns.Add("Value", Object) + g = self._listBox2.CreateGraphics() + if len(vl_par) != 0: + width = [int(g.MeasureString(x,self._listBox2.Font).Width) for x in vl_par] + self._listBox2.HorizontalExtent = max(width) + 50; + [self._tableData3.Rows.Add(key_, value_ ) for key_, value_ in zip(vl_par, rng_val)] + self._listBox2.DataSource = self._tableData3 + self._listBox2.DisplayMember = "Key" + self._listBox2.SelectedIndex = -1 + self._listBox2.SelectedIndexChanged += self.lstselectedIndexChanged + + def UpdateFilter(self, sender, e): + #Update param listbox + sel_cat = sender.SelectedItem['Value'] + self._tableData2 = DataTable("Data") + self._tableData2.Columns.Add("Key", System.String) + self._tableData2.Columns.Add("Value", System.Object) + self._tableData3 = DataTable("Data") + self._tableData3.Columns.Add("Key", System.String) + self._tableData3.Columns.Add("Value", System.Object) if sel_cat != 0 and sender.SelectedIndex != 0: names_par = [x._name for x in sel_cat._par] - [ - self._table_data2.Rows.Add(key_, value_) - for key_, value_ in zip(names_par, sel_cat._par) - ] - self._list_box1.DataSource = self._table_data2 - self._list_box1.DisplayMember = "Key" - for indx in range(self._list_box1.Items.Count): - self._list_box1.SetItemChecked(indx, False) - self._list_box2.DataSource = self._table_data3 + [self._tableData2.Rows.Add(key_, value_ ) for key_, value_ in zip(names_par, sel_cat._par)] + self._listBox1.DataSource = self._tableData2 + self._listBox1.DisplayMember = "Key" + for indx in range(self._listBox1.Items.Count): + self._listBox1.SetItemChecked(indx, False) + self._listBox2.DataSource = self._tableData3 else: - self._list_box1.DataSource = self._table_data2 - self._list_box2.DataSource = self._table_data3 + self._listBox1.DataSource = self._tableData2 + self._listBox2.DataSource = self._tableData3 - -def get_index_units(str_value): +def getIndexUnits(str_value): for let in str_value[::-1]: if let.isdigit(): return str_value[::-1].index(let) return -1 - doc = revit.DOCS.doc uidoc = HOST_APP.uiapp.ActiveUIDocument app = HOST_APP.app version = int(app.VersionNumber) uiapp = HOST_APP.uiapp -sel_view = get_active_view(doc) -if sel_view != 0: - # Categories to exclude - cat_excluded = [ - int(DB.BuiltInCategory.OST_RoomSeparationLines), - int(DB.BuiltInCategory.OST_Cameras), - int(DB.BuiltInCategory.OST_CurtainGrids), - int(DB.BuiltInCategory.OST_Elev), - int(DB.BuiltInCategory.OST_Grids), - int(DB.BuiltInCategory.OST_IOSModelGroups), - int(DB.BuiltInCategory.OST_Views), - int(DB.BuiltInCategory.OST_SitePropertyLineSegment), - int(DB.BuiltInCategory.OST_SectionBox), - int(DB.BuiltInCategory.OST_ShaftOpening), - int(DB.BuiltInCategory.OST_BeamAnalytical), - int(DB.BuiltInCategory.OST_StructuralFramingOpening), - int(DB.BuiltInCategory.OST_MEPSpaceSeparationLines), - int(DB.BuiltInCategory.OST_DuctSystem), - int(DB.BuiltInCategory.OST_Lines), - int(DB.BuiltInCategory.OST_PipingSystem), - int(DB.BuiltInCategory.OST_Matchline), - int(DB.BuiltInCategory.OST_CenterLines), - int(DB.BuiltInCategory.OST_CurtainGridsRoof), - int(DB.BuiltInCategory.OST_SWallRectOpening), - -2000278, - ] - # Get categories in used - categ_inf_used = get_used_categories_and_parameters(cat_excluded, sel_view) - if len(categ_inf_used) == 0: - alert('No categories found in the current view. Please, change your current view.') - script.exit() - # Window - event_handler = ApplyColors() - ext_event = UI.ExternalEvent.Create(event_handler) - - event_handler_uns = SubscribeView() - ext_event_uns = UI.ExternalEvent.Create(event_handler_uns) +sel_View = getActiveView(doc) +if sel_View !=0: + #Categories to exclude + cat_excluded = [int(BuiltInCategory.OST_RoomSeparationLines), int(BuiltInCategory.OST_Cameras), int(BuiltInCategory.OST_CurtainGrids), int(BuiltInCategory.OST_Elev), int(BuiltInCategory.OST_Grids), int(BuiltInCategory.OST_IOSModelGroups), int(BuiltInCategory.OST_Views), int(BuiltInCategory.OST_SitePropertyLineSegment), int(BuiltInCategory.OST_SectionBox), int(BuiltInCategory.OST_ShaftOpening), int(BuiltInCategory.OST_BeamAnalytical), int(BuiltInCategory.OST_StructuralFramingOpening), int(BuiltInCategory.OST_MEPSpaceSeparationLines), int(BuiltInCategory.OST_DuctSystem), int(BuiltInCategory.OST_Lines), int(BuiltInCategory.OST_PipingSystem), int(BuiltInCategory.OST_Matchline), int(BuiltInCategory.OST_CenterLines), int(BuiltInCategory.OST_CurtainGridsRoof), int(BuiltInCategory.OST_SWallRectOpening), -2000278, -1] + #Get categories in used + categ_inf_used = getCategoriesAndParametersInUsed(cat_excluded, sel_View) + #Window + event_handler = applyColors() + ext_event = ExternalEvent.Create(event_handler) + + event_handler_uns = subscribeView() + ext_event_uns = ExternalEvent.Create(event_handler_uns) + + event_handler_filters = createFilters() + ext_event_filters = ExternalEvent.Create(event_handler_filters) + + event_handler_reset = resetColors() + ext_event_reset = ExternalEvent.Create(event_handler_reset) + + event_handler_Legend = createLegend() + ext_event_legend = ExternalEvent.Create(event_handler_Legend) + + wndw = Form_cats(categ_inf_used, ext_event, ext_event_uns, sel_View, ext_event_reset, ext_event_legend, ext_event_filters) + wndw._categories.SelectedIndex = -1 + wndw.Show() - event_handler_reset = ResetColors() - ext_event_reset = UI.ExternalEvent.Create(event_handler_reset) +""" +Credit to Jean-Marc Couffin for his contribution in this work. +This script is based on ColorSplasher by BIMOne. +All original code is licensed under MIT License, however all modifications and improvements are licensed under a different license agreement included below: +################################ +MIT License +Copyright (c) 2021 BIM One Inc. +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: - event_handler_Legend = CreateLegend() - ext_event_legend = UI.ExternalEvent.Create(event_handler_Legend) +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. - event_handler_filters = CreateFilters() - ext_event_filters = UI.ExternalEvent.Create(event_handler_filters) +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +################################ +License Agreement +For the use of this script +This License Agreement (this “Agreement” of this “License Agreement”) is made and effective as of the current date (the “Commencement Date”) by and between Nonica by Estudio Alonso Candau SLP a company organized and existing in Spain with a registered address at Avd.Chafarinas 16 Puerto Rey Vera, Almeria (“Licensor”) and yourself (“Licensee”). +WHEREAS: +1. Licensee wishes to obtain access and use this script (hereinafter, the “Asset”), and +2. Licensor is willing to grant to the Licensee a non-exclusive, non-transferable License to use the Asset for the term and specific purpose set forth in this Agreement, +NOW, THEREFORE, your access to and use of the Service is conditioned on your acceptance of and compliance with these Terms and Conditions. These Terms and Conditions apply to all visitors, users and others who access or use this script. +1. Definitions +1.1 “Agreement” means this License Agreement including the attached Schedule. +1.2 “Confidential Information” means information that: +a. is by its nature confidential; +b. is designated in writing by Licensor as confidential; +c. the Licensee knows or reasonably ought to know is confidential; +d. Information comprised in or relating to any Intellectual Property Rights of Licensor. +1.3 “Asset” means the Asset provided by Licensor as specified in Item 6 of the Schedule in the form as stated in Item 7 of the Schedule. +1.4 “Intellectual Property Rights” means all rights in and to any copyright, trademark, trading name, design, patent, know how (trade secrets) and all other rights resulting from intellectual activity in the industrial, scientific, literary or artistic field and any application or right to apply for registration of any of these rights and any right to protect or enforce any of these rights, as further specified in clause 5. +1.5 “Party” means a person or business entity who has executed this Agreement; details of the Parties are specified in Item 2 of the Schedule. +1.6 “Term” means the term of this Agreement commencing on the Commencement Date as specified in Item 4 of the Schedule and expiring on the Expiry Date specified in Item 5 of the Schedule. +2. License Grant +2.1 Licensor grants to the Licensee a non-exclusive, non-transferable License for the Term to use the Asset for the specific purpose specified in this Agreement, subject to the terms and conditions set out in this Agreement. +3. Charges +3.1 In consideration of the Licensor providing the License under clause 2 of this License Agreement, the Licensee agrees to pay Licensor the amount of the License Charge as specified in Item 9 of the Schedule. +4. Licensee’s Obligations +4.1 The Licensee cannot use the Asset, for purposes other than as specified in this Agreement and in Item 8 of the Schedule. +4.2 The Licensee may permit its employees to use the Asset for the purposes described in Item 8, provided that the Licensee takes all necessary steps and imposes the necessary conditions to ensure that all employees using the Asset do not commercialise or disclose the contents of it to any third person, or use it other than in accordance with the terms of this Agreement. +4.3 The Licensee will not distribute, sell, License or sub-License, let, trade or expose for sale the Asset to a third party. +4.4 No copies of the Asset are to be made other than as expressly approved by Licensor. +4.5 No changes to the Asset or its content may be made by Licensee. +4.6 The Licensee will provide technological and security measures to ensure that the Asset which the Licensee is responsible for is physically and electronically secure from unauthorised use or access. +4.7 Licensee shall ensure that the Asset retains all Licensor copyright notices and other proprietary legends and all trademarks or service marks of Licensor. +5. Intellectual Property Rights +5.1 All Intellectual Property Rights over and in respect of the Asset are owned by Licensor. The Licensee does not acquire any rights of ownership in the Asset. +6. Limitation of Liability +6.1 The Licensee acknowledges and agrees that neither Licensor nor its board members, officers, employees or agents, will be liable for any loss or damage arising out of or resulting from Licensor’s provision of the Asset under this Agreement, or any use of the Asset by the Licensee or its employees; and Licensee hereby releases Licensor to the fullest extent from any such liability, loss, damage or claim. +7. Confidentiality +7.1 Neither Party may use, disclose or make available to any third party the other Party’s Confidential Information, unless such use or disclosure is done in accordance with the terms of this Agreement. +7.2 Each Party must hold the other Party’s Confidential Information secure and in confidence, except to the extent that such Confidential Information: +a. is required to be disclosed according to the requirements of any law, judicial or legislative body or government agency; or +b. was approved for release in writing by the other Party, but only to the extent of and subject to such conditions as may be imposed in such written authorisation. +7.3 This clause 7 will survive termination of this Agreement. +8. Disclaimers & Release +8.1 To the extent permitted by law, Licensor will in no way be liable to the Licensee or any third party for any loss or damage, however caused (including through negligence) which may be directly or indirectly suffered in connection with any use of the Asset. +8.2 The Asset is provided by Licensor on an “as is” basis. +8.3 Licensor will not be held liable by the Licensee in any way, for any loss, damage or injury suffered by the Licensee or by any other person related to any use of the Asset or any part thereof. +8.4 Notwithstanding anything contained in this Agreement, in no event shall Licensor be liable for any claims, damages or loss which may arise from the modification, combination, operation or use of the Asset with Licensee computer programs. +8.5 Licensor does not warrant that the Asset will function in any environment. +8.6 The Licensee acknowledges that: a. The Asset has not been prepared to meet any specific requirements of any party, including any requirements of Licensee; and b. it is therefore the responsibility of the Licensee to ensure that the Asset meets its own individual requirements. +8.7 To the extent permitted by law, no express or implied warranty, term, condition or undertaking is given or assumed by Licensor, including any implied warranty of merchantability or fitness for a particular purpose. +9. Indemnification +9.1 The Licensee must indemnify, defend and hold harmless Licensor, its board members, officers, employees and agents from and against any and all claims (including third party claims), demands, actions, suits, expenses (including attorney’s fees) and damages (including indirect or consequential loss) resulting in any way from: +a. Licensee’s and Licensee’s employee’s use or reliance on the Asset, +b. any breach of the terms of this License Agreement by the Licensee or any Licensee employee, and +c. any other act of Licensee. +9.2 This clause 9 will survive termination of this Agreement. +10. Waiver +10.1 Any failure or delay by either Party to exercise any right, power or privilege hereunder or to insist upon observance or performance by the other of the provisions of this License Agreement shall not operate or be construed as a waiver thereof. +11. Governing Law +11.1 This Agreement will be construed by and governed in accordance with the laws of Spain. The Parties submit to exclusive jurisdiction of the courts of Spain. +12. Termination +12.1 This Agreement and the License granted herein commences upon the Commencement Date and is granted for the Term, unless otherwise terminated by Licensor in the event of any of the following: +a. if the Licensee is in breach of any term of this License Agreement and has not corrected such breach to Licensor’s reasonable satisfaction within 7 days of Licensor’s notice of the same; +b. if the Licensee becomes insolvent, or institutes (or there is instituted against it) proceedings in bankruptcy, insolvency, reorganization or dissolution, or makes an assignment for the benefit of creditors; or +c. the Licensee is in breach of clause 5 or 7 of this Agreement. +12.2 Termination under this clause shall not affect any other rights or remedies Licensor may have. +14. Assignment +14.1 Licensee shall not assign any rights of this License Agreement, without the prior written consent of Licensor. +15. Notices +15.1 All notices required under this Agreement shall be in writing and shall be deemed given (i) when delivered personally; (ii) five (5) days after mailing, when sent certified mail, return receipt requested and postage prepaid; or (iii) one (1) business day after dispatch, when sent via a commercial overnight carrier, fees prepaid. All notices given by either Party must be sent to the address of the other as first written above (unless otherwise changed by written notice). +16. Counterparts +16.1 This Agreement may be executed in any number of counterparts, each of which shall be deemed to be an original and all of which taken together shall constitute one instrument. +17. Severability +17.1 The Parties recognize the uncertainty of the law with respect to certain provisions of this Agreement and expressly stipulate that this Agreement will be construed in a manner that renders its provisions valid and enforceable to the maximum extent possible under applicable law. To the extent that any provisions of this Agreement are determined by a court of competent jurisdiction to be invalid or unenforceable, such provisions will be deleted from this Agreement or modified so as to make them enforceable and the validity and enforceability of the remainder of such provisions and of this Agreement will be unaffected. +18. Entire Agreement +18.1 This Agreement contains the entire agreement between the Parties and supersedes any previous understanding, commitments or agreements, oral or written. Further, this Agreement may not be modified, changed, or otherwise altered in any respect except by a written agreement signed by both Parties. +IN WITNESS WHEREOF, this Agreement, including the attached Schedule, was signed by the Parties under the hands of their duly authorized representatives and made effective as of the current date. +Nonica by Estudio Alonso Candau SLP, +Signature +02/05/2021 +Jaime Alonso Candau +Please contact hello@nonica.io with any further doubt/request. +Your signatureby using and accessing this script. +Signed by accepting these terms. +Current date. - wndw = FormCats( - categ_inf_used, - ext_event, - ext_event_uns, - sel_view, - ext_event_reset, - ext_event_legend, - ext_event_filters, - ) - wndw._categories.SelectedIndex = -1 - wndw.Show() +""" diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/bundle.yaml b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/bundle.yaml new file mode 100644 index 000000000..f3495b090 --- /dev/null +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/bundle.yaml @@ -0,0 +1,7 @@ +title: + fr_fr: Décompte des Triangles par type de famille + en_us: Triangles count per family type +tooltip: + fr_fr: Compte de Triangles par type de famille. Le résultat est un tableau classé du plus petit nombre de faces au plus grand, avec un grand total. + en_us: Triangles count per family type. The result is a table sorted from the smallest number of faces to the largest, with a grand total. +author: Jean-Marc Couffin, thanks to BIMOne Inc. who allowed me to share this script \ No newline at end of file diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/icon.dark.png b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/icon.dark.png new file mode 100644 index 000000000..ae24ae691 Binary files /dev/null and b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/icon.dark.png differ diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/icon.png b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/icon.png new file mode 100644 index 000000000..e954c545f Binary files /dev/null and b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/icon.png differ diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/script.py b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/script.py new file mode 100644 index 000000000..695efb63e --- /dev/null +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/Count Faces.pushbutton/script.py @@ -0,0 +1,84 @@ +from pyrevit import revit, script, DB + +doc = revit.doc +# currView = revit.active_view + +# Get the output window +output = script.get_output() +output.close_others() + + +# Get Elements of the FamilyInstance Class +elements = ( + DB.FilteredElementCollector(doc) + .OfClass(DB.FamilyInstance) + .WhereElementIsNotElementType() + .ToElements() +) + +grand_total = [] +table_data = [] +elements_name = [] +elements_count = [] +elements_category = [] +elements_type = [] + +opt = DB.Options() + +for element in elements: + total_triangles = [] + typeId = element.GetTypeId() + if typeId not in elements_type: + elements_type.append(typeId) + geometry_set = element.get_Geometry(opt) + try: + for geometry in geometry_set: + if isinstance(geometry, DB.Solid) and geometry.Faces.Size > 0: + nbrtriangle = sum( + [ + f.Triangulate().NumTriangles + for f in geometry.Faces + if f.Triangulate() is not None + ] + ) + total_triangles.append(nbrtriangle) + elif isinstance(geometry, DB.GeometryInstance): + for instObj in geometry.SymbolGeometry: + if isinstance(instObj, DB.Solid) and instObj.Faces.Size > 0: + nbrtriangle = sum( + [ + f.Triangulate().NumTriangles + for f in instObj.Faces + if f.Triangulate() is not None + ] + ) + total_triangles.append(nbrtriangle) + else: + pass + geometry_set.Dispose() + total_triangles = sum(total_triangles) + if total_triangles != 0: + elements_count.append(total_triangles) + elements_name.append( + output.linkify(element.Id) + + "**" + + element.Name + + "** (*Category*: " + + element.Category.Name + + ")" + ) + grand_total.append(total_triangles) + except: + pass + +# adding grand total and making a dictionary out of it +elements_count.append(sum(grand_total)) +elements_name.append("Grand Total") +my_dict = dict(zip(elements_name, elements_count)) + +# output as a table +output.print_table( + sorted(my_dict.items(), key=lambda item: item[1]), + ["Name", "Count"], + last_line_style="color:white;font-weight: bolder; background-color: gray;", +) diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/LinesPerViewCounter.pushbutton/LinesPerViewCounter_script.py b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/LinesPerViewCounter.pushbutton/LinesPerViewCounter_script.py index da0f00f19..5c154b0b6 100644 --- a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/LinesPerViewCounter.pushbutton/LinesPerViewCounter_script.py +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/LinesPerViewCounter.pushbutton/LinesPerViewCounter_script.py @@ -5,46 +5,65 @@ from pyrevit import revit, DB +__title__ = 'Lines Per View Counter' +__author__ = 'Frederic Beaupere' +__contact__ = 'https://github.com/frederic-beaupere' +__author2__ = 'Jean-Marc Couffin' +__contact2__ = 'https://github.com/jmcouffin' +__credits__ = 'http://eirannejad.github.io/pyRevit/credits/' + +doc = revit.doc output = script.get_output() +output.close_others() +output.set_width(800) -detail_lines = defaultdict(int) -all_lines = DB.FilteredElementCollector(revit.doc)\ - .OfCategory(DB.BuiltInCategory.OST_Lines)\ - .WhereElementIsNotElementType()\ - .ToElements() +def line_count(document=doc): + """ + Counts the number of detail lines in each view of a Revit document. -for line in all_lines: - if line.CurveElementType.ToString() == "DetailCurve": - view_id_int = line.OwnerViewId.IntegerValue - detail_lines[view_id_int] += 1 + Args: + document (Document): The Revit document to count the lines in. Defaults to the active document. -output.print_md("####LINE COUNT IN CURRENT VIEW:") -output.print_md('By: [{}]({})'.format('Frederic Beaupere', - 'https://github.com/frederic-beaupere')) + Returns: + None + """ + if document == doc: + output.print_md("\n\n## LINE COUNT IN CURRENT DOCUMENT: "+ doc.Title+"\n") + else: + document = document.GetLinkDocument() + l_title = document.Title.split(":")[0] + output.print_md("\n\n## LINE COUNT IN REVIT LINK: "+ l_title+"\n") + try: + detail_lines = defaultdict(int) + table_data = [] + lines = DB.FilteredElementCollector(document).OfCategory(DB.BuiltInCategory.OST_Lines).WhereElementIsNotElementType().ToElements() + for line in lines: + if line.CurveElementType.ToString() == "DetailCurve": + view_id_int = line.OwnerViewId.IntegerValue + detail_lines[view_id_int] += 1 + for line_count, view_id_int \ + in sorted(zip(detail_lines.values(), detail_lines.keys()), + reverse=True): + view_id = DB.ElementId(view_id_int) + view_creator = DB.WorksharingUtils.GetWorksharingTooltipInfo(document,view_id).Creator + try: + view_name = revit.query.get_name(document.GetElement(view_id)) + except Exception: + view_name = "" + table_data.append([line_count, view_name, output.linkify(view_id), view_creator]) + table_data.append([str(sum(detail_lines.values()))+" Lines in Total","In "+str(len(detail_lines))+" Views", "", ""]) + output.print_table(table_data,columns=["Number", 'Name', 'Id', 'Creator'], last_line_style='font-weight:bold;font-size:1.2em;') + except Exception as e: + output.print_md("**Error: {}**".format(e)) -for line_count, view_id_int \ - in sorted(zip(detail_lines.values(), detail_lines.keys()), - reverse=True): - view_id = DB.ElementId(view_id_int) - view_creator = \ - DB.WorksharingUtils.GetWorksharingTooltipInfo(revit.doc, - view_id).Creator +if __name__ == '__main__': + output.print_md("\n\n# LINES PER VIEW IN CURRENT DOCUMENT\n___\n\n") + line_count() + if __shiftclick__: + output.print_md("\n\n# LINES PER VIEW IN LINKS\n___\n\n") + revit_links = DB.FilteredElementCollector(doc).OfClass(DB.RevitLinkInstance).ToElements() + for link in revit_links: + line_count(link) - try: - view_name = revit.query.get_name(revit.doc.GetElement(view_id)) - except Exception: - view_name = "" - - output.print_md("\n**{0} Lines in view:** {3}\n" - "View id:{1}\n" - "View creator: {2}\n".format(line_count, - output.linkify(view_id), - view_creator, - view_name)) - -print("\n" - + str(sum(detail_lines.values())) - + " Lines in " - + str(len(detail_lines)) - + " Views.") +output.print_md('By: [{}]({}) and some improvements from [{}]({})\n\n'.format(__author__, __contact__, __author2__, __contact2__)) diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/LinesPerViewCounter.pushbutton/bundle.yaml b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/LinesPerViewCounter.pushbutton/bundle.yaml index 5c6ea82e6..61a2b3737 100644 --- a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/LinesPerViewCounter.pushbutton/bundle.yaml +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/LinesPerViewCounter.pushbutton/bundle.yaml @@ -3,8 +3,7 @@ title: fr_fr: Compteur de lignes par vue en_us: Lines Per View Counter tooltip: - ru: Отображает отсортированный список количетсва линий детализации для всех линий детализации. - fr_fr: Lister classée du nombre de lignes de détail par vue contenant des lignes de détail - en_us: List sorted Detail Line Counts for all views with Detail Lines -author: 'Frederic Beaupere' -contact: 'https://github.com/frederic-beaupere' \ No newline at end of file + ru: Перечислите отсортированное количество строк детализации для всех видов со строками детализации. Нажмите SHIFT + щелчок, чтобы получить счетчик ссылок Revit. + fr_fr: Lister classée du nombre de lignes de détail par vue contenant des lignes de détail. Utilisez SHIFT+Click pour obtenir le décompte pour les fichiers liés. + en_us: List sorted Detail Line Counts for all views with Detail Lines. Press SHIFT+Click to get the count for Revit Links +author: 'Original by Frederic Beaupere; Improvements by Jean-Marc Couffin' diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/ListFamilySizeCreator.pushbutton/ListFamilySizeCreator_script.py b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/ListFamilySizeCreator.pushbutton/ListFamilySizeCreator_script.py index ec68483b3..53c801415 100644 --- a/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/ListFamilySizeCreator.pushbutton/ListFamilySizeCreator_script.py +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Analysis.panel/Tools.stack/Inspect.pulldown/ListFamilySizeCreator.pushbutton/ListFamilySizeCreator_script.py @@ -8,7 +8,7 @@ __title__ = 'Lists Family Sizes' __authors__ = ['Frederic Beaupere', 'Alex Melnikov'] __contact__ = 'https://github.com/frederic-beaupere' -__credits__ = 'http://eirannejad.github.io/pyRevit/credits/' +__credits__ = 'http://pyrevitlabs.github.io/pyRevit/credits/' FIELDS = ["Size", "Name", "Category", "Creator"] # temporary path for saving families diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Drawing Set.panel/Revision.pulldown/Set Revision On Sheets.pushbutton/script.py b/extensions/pyRevitTools.extension/pyRevit.tab/Drawing Set.panel/Revision.pulldown/Set Revision On Sheets.pushbutton/script.py index ea5f22cb2..a344fc50a 100644 --- a/extensions/pyRevitTools.extension/pyRevit.tab/Drawing Set.panel/Revision.pulldown/Set Revision On Sheets.pushbutton/script.py +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Drawing Set.panel/Revision.pulldown/Set Revision On Sheets.pushbutton/script.py @@ -3,9 +3,13 @@ from pyrevit import revit, DB from pyrevit import forms +# define a filterfunc to filter out issued revisions +def filterfunc(rev): + return rev.Issued == False revisions = forms.select_revisions(button_name='Select Revision', - multiple=True) + multiple=True, + filterfunc=filterfunc) if revisions: sheets = forms.select_sheets(button_name='Set Revision', diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Modify.panel/edit1.stack/Patterns.splitpushbutton/Make Pattern.pushbutton/patmaker.py b/extensions/pyRevitTools.extension/pyRevit.tab/Modify.panel/edit1.stack/Patterns.splitpushbutton/Make Pattern.pushbutton/patmaker.py index 4bd55ae2f..5bdcbc90a 100644 --- a/extensions/pyRevitTools.extension/pyRevit.tab/Modify.panel/edit1.stack/Patterns.splitpushbutton/Make Pattern.pushbutton/patmaker.py +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Modify.panel/edit1.stack/Patterns.splitpushbutton/Make Pattern.pushbutton/patmaker.py @@ -36,7 +36,7 @@ PAT_SEPARATOR = ', ' PAT_FILE_TEMPLATE = \ "; Written by \"Make Pattern\" tool for pyRevit\n" \ - "; http://eirannejad.github.io/pyRevit/\n" \ + "; http://pyrevitlabs.github.io/pyRevit/\n" \ ";-Date : {date}\n" \ ";-Time : {time}\n" \ ";-pyRevit Version : {version}\n" \ diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools.stack/Family.pulldown/Family QuickCheck.pushbutton/FamilyQuickcheck_script.py b/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools.stack/Family.pulldown/Family QuickCheck.pushbutton/FamilyQuickcheck_script.py index 0c150446a..7667aaaf4 100644 --- a/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools.stack/Family.pulldown/Family QuickCheck.pushbutton/FamilyQuickcheck_script.py +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools.stack/Family.pulldown/Family QuickCheck.pushbutton/FamilyQuickcheck_script.py @@ -4,7 +4,7 @@ Copyright (c) 2017 Frederic Beaupere github.com/frederic-beaupere -PR731 https://github.com/eirannejad/pyRevit/pull/731 +PR731 https://github.com/pyrevitlabs/pyRevit/pull/731 """ #pylint: disable=invalid-name,import-error,superfluous-parens,broad-except from pyrevit import revit diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools.stack/Family.pulldown/Family QuickCheck.pushbutton/bundle.yaml b/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools.stack/Family.pulldown/Family QuickCheck.pushbutton/bundle.yaml index dd91ce11c..6ae13438b 100644 --- a/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools.stack/Family.pulldown/Family QuickCheck.pushbutton/bundle.yaml +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools.stack/Family.pulldown/Family QuickCheck.pushbutton/bundle.yaml @@ -10,7 +10,7 @@ tooltip: github.com/frederic-beaupere - PR731 https://github.com/eirannejad/pyRevit/pull/731 + PR731 https://github.com/pyrevitlabs/pyRevit/pull/731 fr_fr: >- Vérification non exhaustive pour détecter les familles Revit corrompues. @@ -18,7 +18,7 @@ tooltip: github.com/frederic-beaupere - PR731 https://github.com/eirannejad/pyRevit/pull/731 + PR731 https://github.com/pyrevitlabs/pyRevit/pull/731 en_us: >- Non-exhaustive check to detect corrupt Revit families. @@ -26,7 +26,7 @@ tooltip: github.com/frederic-beaupere - PR731 https://github.com/eirannejad/pyRevit/pull/731 + PR731 https://github.com/pyrevitlabs/pyRevit/pull/731 author: - Frederic Beaupere - '{{author}}' diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools2.stack/Get RVT Info.pushbutton/script.py b/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools2.stack/Get RVT Info.pushbutton/script.py index 538a32e30..2ecadf499 100644 --- a/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools2.stack/Get RVT Info.pushbutton/script.py +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Project.panel/ptools2.stack/Get RVT Info.pushbutton/script.py @@ -2,6 +2,7 @@ #pylint: disable=E0401,C0103 from pyrevit import forms from pyrevit.revit import files +from pyrevit import DB rvt_file = forms.pick_file(files_filter='Revit Files |*.rvt;*.rte;*.rfa|' 'Revit Model |*.rvt|' @@ -9,9 +10,13 @@ 'Revit Family |*.rfa') if rvt_file: mfile = files.get_file_info(rvt_file) - print("Created in: {0} ({1}({2}))".format(mfile.RevitProduct.Name, + bfi = DB.BasicFileInfo.Extract(rvt_file) + if mfile.RevitProduct is not None: + print("Created in: {0} ({1}({2}))".format(mfile.RevitProduct, mfile.RevitProduct.BuildNumber, mfile.RevitProduct.BuildTarget)) + else: + print("Created in: {0}".format(bfi.Format)) print("Workshared: {0}".format("Yes" if mfile.IsWorkshared else "No")) if mfile.IsWorkshared: print("Central Model Path: {0}".format(mfile.CentralModelPath)) diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/Pick.pushbutton/icon.dark.png b/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/Pick.pushbutton/icon.dark.png index 5674581ef..4567d03a6 100644 Binary files a/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/Pick.pushbutton/icon.dark.png and b/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/Pick.pushbutton/icon.dark.png differ diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/Pick.pushbutton/icon.png b/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/Pick.pushbutton/icon.png index 9206d26f5..6b7d6a3df 100644 Binary files a/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/Pick.pushbutton/icon.png and b/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/Pick.pushbutton/icon.png differ diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/icon.dark.png b/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/icon.dark.png new file mode 100644 index 000000000..4567d03a6 Binary files /dev/null and b/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/icon.dark.png differ diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/icon.png b/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/icon.png index f7c367e69..6b7d6a3df 100644 Binary files a/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/icon.png and b/extensions/pyRevitTools.extension/pyRevit.tab/Selection.panel/Pick.splitpushbutton/icon.png differ diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/bundle.yaml b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/bundle.yaml index cd51c2423..620d4f087 100644 --- a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/bundle.yaml +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/bundle.yaml @@ -1,4 +1,4 @@ layout: - toggles1 - toggles2 - - sync \ No newline at end of file + - toggles3 \ No newline at end of file diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/MainWindow.xaml b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/MainWindow.xaml new file mode 100644 index 000000000..8d80cef29 --- /dev/null +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/MainWindow.xaml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/bundle.yaml b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/bundle.yaml new file mode 100644 index 000000000..9865e641b --- /dev/null +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/bundle.yaml @@ -0,0 +1,12 @@ +title: + fr_fr: Illustrer Profondeur de Vue + en_us: Show View Range +tooltip: + fr_fr: Outil pour illustrer la profondeur de vue des vues en plan dans une vue 3D à l'aide de plans colorés. Ouvrir une vue 3D et sélectionner les vues en plan à illustrer dans le navigateur de projet. + en_us: Tool to illustrate the view range of plan views in a 3D view using colored planes. Open a 3D view and select the plan views to illustrate in the project browser. +author: Tamás Déri +min_revit_version: 2023 +engine: + clean: true + full_frame: false + persistent: true \ No newline at end of file diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/icon.dark.png b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/icon.dark.png new file mode 100644 index 000000000..59b4d1431 Binary files /dev/null and b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/icon.dark.png differ diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/icon.png b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/icon.png new file mode 100644 index 000000000..0e1925fcb Binary files /dev/null and b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/icon.png differ diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/script.py b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/script.py new file mode 100644 index 000000000..c01ff9304 --- /dev/null +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/ViewRange.pushbutton/script.py @@ -0,0 +1,465 @@ +# -*- coding: UTF-8 -*- + +from __future__ import print_function +from pyrevit import script, forms, revit, HOST_APP +from pyrevit.revit import dc3dserver as d3d +import traceback + +from Autodesk.Revit import DB, UI +from Autodesk.Revit.Exceptions import InvalidOperationException +from Autodesk.Revit.UI.Events import ViewActivatedEventArgs, SelectionChangedEventArgs +from Autodesk.Revit.DB.Events import DocumentChangedEventArgs + +from System import EventHandler, Convert +from System.Windows.Media import Color, SolidColorBrush + +from System.Collections.Generic import List + +doc = revit.doc +uidoc = revit.uidoc + +logger = script.get_logger() +output = script.get_output() + +PLANES = { + DB.PlanViewPlane.TopClipPlane: [0, 255, 0], + DB.PlanViewPlane.CutPlane: [255, 0, 0], + DB.PlanViewPlane.BottomClipPlane: [0, 0, 255], + DB.PlanViewPlane.ViewDepthPlane: [255, 127, 0] +} + +class SimpleEventHandler(UI.IExternalEventHandler): + """ + Simple IExternalEventHandler sample + """ + + def __init__(self, do_this): + self.do_this = do_this + + def Execute(self, uiapp): + try: + self.do_this(uiapp) + except InvalidOperationException: + print('InvalidOperationException catched') + + def GetName(self): + return "SimpleEventHandler" + + +class Context(object): + def __new__(cls, *args, **kwargs): + if not hasattr(cls, "instance"): + cls.instance = super(Context, cls).__new__(cls, *args, **kwargs) + return cls.instance + + def __init__(self, view_model): + self._active_view = None + self._source_view = None + self.length_unit = (doc.GetUnits() + .GetFormatOptions(DB.SpecTypeId.Length) + .GetUnitTypeId()) + + self.height_data = {} + self.view_model = view_model + view_model.unit_label = DB.LabelUtils.GetLabelForUnit(self.length_unit) + + @property + def active_view(self): + if self._active_view and not self._active_view.IsValidObject: + self._active_view = None + return self._active_view + @active_view.setter + def active_view(self, value): + if not compare_views(self._active_view, value): + self._active_view = value + self.context_changed() + + @property + def source_view(self): + if self._source_view and not self._source_view.IsValidObject: + self._source_view = None + return self._source_view + @source_view.setter + def source_view(self, value): + if not compare_views(self._source_view, value): + self._source_view = value + self.context_changed() + + def context_changed(self): + server.uidoc = UI.UIDocument(self.active_view.Document) + self.view_model.topplane_elevation = "-" + self.view_model.cutplane_elevation = "-" + self.view_model.bottomplane_elevation = "-" + self.view_model.viewdepth_elevation = "-" + + if not self.is_valid(): + server.meshes = None + refresh_event.Raise() + + return + try: + + + edges = [] + triangles = [] + if isinstance(self.source_view, DB.ViewPlan): + + if self.active_view.get_Parameter( + DB.BuiltInParameter.VIEWER_MODEL_CLIP_BOX_ACTIVE + ).AsInteger() == 1: + bbox = self.active_view.GetSectionBox() + + corners = corners_from_bb(bbox) + else: + crop_bbox = self.source_view.CropBox + corners = corners_from_bb(crop_bbox) + + view_range = self.source_view.GetViewRange() + + for plane in PLANES: + + plane_level = self.source_view.Document.GetElement( + view_range.GetLevelId(plane) + ) + + if not plane_level: + self.height_data[plane] = "N/A" + continue + plane_elevation = ( + plane_level.ProjectElevation + + view_range.GetOffset(plane) + ) + + self.height_data[plane] = round( + DB.UnitUtils.ConvertFromInternalUnits( + plane_elevation, + self.length_unit + ), + 2 + ) + + cut_plane_vertices = [ + DB.XYZ(c.X, c.Y, plane_elevation) for c in corners + ] + + color = get_color_from_plane(plane) + + edges.extend( + create_edges(cut_plane_vertices, color)) + + triangles.extend( + create_triangles(cut_plane_vertices, color)) + + self.view_model.topplane_elevation = str(self.height_data[ + DB.PlanViewPlane.TopClipPlane]) + self.view_model.cutplane_elevation = str(self.height_data[ + DB.PlanViewPlane.CutPlane]) + self.view_model.bottomplane_elevation = str(self.height_data[ + DB.PlanViewPlane.BottomClipPlane]) + self.view_model.viewdepth_elevation = str(self.height_data[ + DB.PlanViewPlane.ViewDepthPlane]) + + else: + crop_bbox = self.source_view.CropBox + cut_plane_vertices = corners_from_bb(crop_bbox) + + plane = DB.PlanViewPlane.ViewDepthPlane + + color = get_color_from_plane(plane) + + edges.extend( + create_edges(cut_plane_vertices, color)) + + triangles.extend( + create_triangles(cut_plane_vertices, color)) + + view_dir_transform = DB.Transform.CreateTranslation( + self.source_view.ViewDirection.Negate() + * self.source_view.CropBox.Min.Z + ) + cut_plane_vertices = [view_dir_transform.OfPoint(pt) + for pt in cut_plane_vertices] + plane = DB.PlanViewPlane.CutPlane + + color = get_color_from_plane(plane) + + edges.extend( + create_edges(cut_plane_vertices, color)) + + triangles.extend( + create_triangles(cut_plane_vertices, color)) + + + + mesh = revit.dc3dserver.Mesh( + edges, + triangles + ) + + server.meshes = [mesh] + refresh_event.Raise() + + except: + print(traceback.format_exc()) + + + + def is_valid(self): + if not can_use_view_as_source(self.source_view): + self.view_model.message = \ + "Please select a Plan or Section View in the Project Browser!" + return False + elif not isinstance(context.active_view, DB.View3D): + self.view_model.message = "Please activate a 3D View!" + return False + elif ( + not context.source_view.CropBoxActive and + not context.active_view.get_Parameter( + DB.BuiltInParameter.VIEWER_MODEL_CLIP_BOX_ACTIVE + ).AsInteger() == 1 + ): + self.view_model.message = ("Please activate the \"Section Box\" " + "on the active view,\nor the " + "\"Crop View\" on the selected view!") + + else: + self.view_model.message = "Showing View Range of\n[{}]".format( + self.source_view.Name) + return True + + +class MainViewModel(forms.Reactive): + + def __init__(self): + self._message = None + self.topplane_brush = SolidColorBrush(Color.FromRgb( + *[Convert.ToByte(i) for i in PLANES[DB.PlanViewPlane.TopClipPlane]] + )) + self.cutplane_brush = SolidColorBrush(Color.FromRgb( + *[Convert.ToByte(i) for i in PLANES[DB.PlanViewPlane.CutPlane]] + )) + self.bottomplane_brush = SolidColorBrush(Color.FromRgb( + *[Convert.ToByte(i) for i in PLANES[DB.PlanViewPlane.BottomClipPlane]] + )) + self.viewdepth_brush = SolidColorBrush(Color.FromRgb( + *[Convert.ToByte(i) for i in PLANES[DB.PlanViewPlane.ViewDepthPlane]] + )) + self._topplane_elevation = "-" + self._cutplane_elevation = "-" + self._bottomplane_elevation = "-" + self._viewdepth_elevation = "-" + + self.unit_label = "" + + @forms.reactive + def message(self): + return self._message + + @message.setter + def message(self, value): + self._message = value + + @forms.reactive + def topplane_elevation(self): + return self._topplane_elevation + + @topplane_elevation.setter + def topplane_elevation(self, value): + self._topplane_elevation = value + + @forms.reactive + def cutplane_elevation(self): + return self._cutplane_elevation + + @cutplane_elevation.setter + def cutplane_elevation(self, value): + self._cutplane_elevation = value + + @forms.reactive + def bottomplane_elevation(self): + return self._bottomplane_elevation + + @bottomplane_elevation.setter + def bottomplane_elevation(self, value): + self._bottomplane_elevation = value + + @forms.reactive + def viewdepth_elevation(self): + return self._viewdepth_elevation + + @viewdepth_elevation.setter + def viewdepth_elevation(self, value): + self._viewdepth_elevation = value + + +class MainWindow(forms.WPFWindow): + def __init__(self): + forms.WPFWindow.__init__(self, "MainWindow.xaml") + self.Closed += self.window_closed + subscribe() + server.add_server() + + + def window_closed(self, sender, args): + server.remove_server() + refresh_event.Raise() + unsubscribe_event.Raise() + +def subscribe(): + try: + ui_app = UI.UIApplication(HOST_APP.app) + ui_app.ViewActivated += EventHandler[ViewActivatedEventArgs](view_activated) + ui_app.SelectionChanged += EventHandler[SelectionChangedEventArgs](selection_changed) + ui_app.Application.DocumentChanged += EventHandler[DocumentChangedEventArgs](doc_changed) + except: + print(traceback.format_exc()) + + +def unsubscribe(uiapp): + try: + uiapp.ViewActivated -= EventHandler[ViewActivatedEventArgs](view_activated) + uiapp.SelectionChanged -= EventHandler[SelectionChangedEventArgs](selection_changed) + uiapp.Application.DocumentChanged -= EventHandler[DocumentChangedEventArgs](doc_changed) + except: + print(traceback.format_exc()) + + +def refresh_active_view(uiapp): + try: + uidoc = uiapp.ActiveUIDocument + if not compare_views(uidoc.ActiveView, context.active_view): + uidoc.ActiveView = context.active_view + uidoc.RefreshActiveView() + if context.source_view: + uidoc.Selection.SetElementIds( + List[DB.ElementId]([context.source_view.Id])) + except: + print(traceback.format_exc()) + + +def view_activated(sender, args): + try: + context.active_view = args.CurrentActiveView + except: + print(traceback.format_exc()) + + +def selection_changed(sender, args): + # only handle selections made in the Project Browser + if not args.GetDocument().ActiveView.ViewType == DB.ViewType.ProjectBrowser: + return + + try: + doc = args.GetDocument() + sel_ids = list(args.GetSelectedElements()) + if len(sel_ids) == 1: + sel = doc.GetElement(sel_ids[0]) + if can_use_view_as_source(sel): + context.source_view = sel + return + context.source_view = None + except: + print(traceback.format_exc()) + +def doc_changed(sender, args): + try: + affected_ids = list(args.GetModifiedElementIds()) + affected_ids.extend(list(args.GetDeletedElementIds())) + if any([view.Id in affected_ids for view + in [context.source_view, context.active_view]]): + context.context_changed() + except AttributeError: + context.context_changed() + except: + print(traceback.format_exc()) + + +def compare_views(view1, view2): + if not view1 and not view2: + return True + elif not view1 or not view2: + return False + if view1.Document.GetHashCode() != view2.Document.GetHashCode(): + return False + else: + return view1.Id == view2.Id + + +def can_use_view_as_source(view): + return ( + isinstance(view, DB.ViewPlan) or + isinstance(view, DB.ViewSection) + ) + + +def corners_from_bb(bbox): + transform = bbox.Transform + + corners = [ + bbox.Min, + bbox.Min + DB.XYZ.BasisX * (bbox.Max - bbox.Min).X, + bbox.Min + DB.XYZ.BasisX * (bbox.Max - bbox.Min).X + + DB.XYZ.BasisY * (bbox.Max - bbox.Min).Y, + bbox.Min + DB.XYZ.BasisY * (bbox.Max - bbox.Min).Y + ] + return [transform.OfPoint(c) for c in corners] + + +def create_edges(vertices, color): + return [ + revit.dc3dserver.Edge( + vertices[i-1], + vertices[i], + color + ) for i in range(len(vertices)) + ] + + +def create_triangles(vertices, color): + return [ + revit.dc3dserver.Triangle( + vertices[0], + vertices[1], + vertices[2], + revit.dc3dserver.Mesh.calculate_triangle_normal( + vertices[0], + vertices[1], + vertices[2], + ), + color + ), + revit.dc3dserver.Triangle( + vertices[2], + vertices[3], + vertices[0], + revit.dc3dserver.Mesh.calculate_triangle_normal( + vertices[2], + vertices[3], + vertices[0], + ), + color + ) + ] + + +def get_color_from_plane(plane): + return DB.ColorWithTransparency( + PLANES[plane][0], + PLANES[plane][1], + PLANES[plane][2], + 180 + ) + + +server = revit.dc3dserver.Server(register=False) + +unsubscribe_event = UI.ExternalEvent.Create(SimpleEventHandler(unsubscribe)) +refresh_event = UI.ExternalEvent.Create(SimpleEventHandler(refresh_active_view)) + +vm = MainViewModel() +context = Context(vm) +context.active_view = uidoc.ActiveGraphicalView + +main_window = MainWindow() +main_window.DataContext = vm +main_window.show() diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/bundle.yaml b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/bundle.yaml new file mode 100644 index 000000000..3ae619831 --- /dev/null +++ b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/bundle.yaml @@ -0,0 +1,3 @@ +layout: + - sync + - ViewRange \ No newline at end of file diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/sync.pushbutton/bundle.yaml b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/sync.pushbutton/bundle.yaml similarity index 100% rename from extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/sync.pushbutton/bundle.yaml rename to extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/sync.pushbutton/bundle.yaml diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/sync.pushbutton/config.py b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/sync.pushbutton/config.py similarity index 100% rename from extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/sync.pushbutton/config.py rename to extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/sync.pushbutton/config.py diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/sync.pushbutton/icon.dark.png b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/sync.pushbutton/icon.dark.png similarity index 100% rename from extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/sync.pushbutton/icon.dark.png rename to extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/sync.pushbutton/icon.dark.png diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/sync.pushbutton/icon.png b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/sync.pushbutton/icon.png similarity index 100% rename from extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/sync.pushbutton/icon.png rename to extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/sync.pushbutton/icon.png diff --git a/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/sync.pushbutton/script.py b/extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/sync.pushbutton/script.py similarity index 100% rename from extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/sync.pushbutton/script.py rename to extensions/pyRevitTools.extension/pyRevit.tab/Toggles.panel/toggles3.stack/sync.pushbutton/script.py diff --git a/extensions/pyRevitTutor.extension/extension.json b/extensions/pyRevitTutor.extension/extension.json index dfea0c0e0..fcbe7223c 100644 --- a/extensions/pyRevitTutor.extension/extension.json +++ b/extensions/pyRevitTutor.extension/extension.json @@ -7,8 +7,8 @@ "description": "Python for Revit Tutorials form pyRevit Youtube Channel", "author": "Ehsan Iran-Nejad", "author_profile": "https://keybase.io/ein", - "url": "https://github.com/eirannejad/pyRevit.git", - "website": "http://eirannejad.github.io/pyRevit/", + "url": "https://github.com/pyrevitlabs/pyRevit.git", + "website": "http://pyrevitlabs.github.io/pyRevit/", "image": "", "dependencies": [] } \ No newline at end of file diff --git a/extras/dark_mode/convert_icon_to_dark_mode.py b/extras/dark_mode/convert_icon_to_dark_mode.py index 21d560227..262165191 100644 --- a/extras/dark_mode/convert_icon_to_dark_mode.py +++ b/extras/dark_mode/convert_icon_to_dark_mode.py @@ -13,7 +13,7 @@ def create_dark_icon(source): Returns: None """ - image = Image.open(source) + image = Image.open(source).convert('RGBA') create_bitmap(image, (235, 235, 235), os.path.join(os.path.dirname(source), os.path.splitext(source)[0] + ".dark.png")) def create_bitmap(source, color, target): @@ -42,7 +42,7 @@ def create_bitmap(source, color, target): # all icon.png files in the current directory and subfolders for root, dirs, files in os.walk("C:\pyRevit"): # folder path that requires conversion for file in files: - if file == "icon.png": + if file == "icon.png" and not os.path.exists(os.path.join(root, "icon.dark.png")): try: create_dark_icon(os.path.join(root, file)) except Exception as e: diff --git a/mkdocs.yml b/mkdocs.yml index fde8532eb..71854a0e3 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -1,13 +1,14 @@ site_name: pyRevit -repo_url: https://github.com/eirannejad/pyRevit -repo_name: eirannejad/pyRevit +repo_url: https://github.com/pyrevitlabs/pyRevit +repo_name: pyrevitlabs/pyRevit extra: - homepage: https://pyrevitlabs.notion.site + homepage: https://pyrevitlabs.io theme: name: material logo: static/pyRevitLogo.svg + favicon: images/favicon.ico features: - content.code.select - content.code.copy diff --git a/pyRevitfile b/pyRevitfile index cdc2024fa..1b50aab84 100644 --- a/pyRevitfile +++ b/pyRevitfile @@ -4,65 +4,56 @@ kernel = 'IronPython 3' version = 340 runtime = true -path = 'bin\engines\IPY340PR' +path = 'IPY340PR' assembly = 'pyRevitLoader.dll' compatproducts = [] description = 'IronPython 3 Engine' [engines.DEFAULT] kernel = 'IronPython' -version = 2711 +version = 2712 runtime = true -path = 'bin\engines\IPY2711PR' +path = 'IPY2712PR' assembly = 'pyRevitLoader.dll' description = 'Custom pyRevit IronPython Engine' -[engines.CPY378] +[engines.CPY3123] kernel = 'CPython' -version = 378 +version = 3123 runtime = false -path = 'bin\engines\CPY378' -assembly = 'pyRevitLabs.PythonNet.dll' -description = 'CPython Engine' - -[engines.CPY385] -kernel = 'CPython' -version = 385 -runtime = false -path = 'bin\engines\CPY385' -assembly = 'pyRevitLabs.PythonNet.dll' +path = 'CPY3123' +assembly = 'python312.dll' description = 'CPython Engine' [deployments] -core = ['bin', - 'pyrevitlib', - 'site-packages', - 'pyRevitfile'] -corex = ['bin', - 'extensions/pyRevitCore.extension', - 'extensions/extensions.json', - 'pyrevitlib', - 'site-packages', - 'pyRevitfile'] -base = ['bin', - 'extensions/pyRevitCore.extension', - 'extensions/pyRevitTags.extension', - 'extensions/pyRevitTools.extension', - 'extensions/extensions.json', - 'pyrevitlib', - 'site-packages', - 'pyRevitfile'] -basepublic = ['bin', - 'extensions/pyRevitCore.extension', - 'extensions/pyRevitTags.extension', - 'extensions/pyRevitTools.extension', - 'extensions/pyRevitTutor.extension', - 'extensions/extensions.json', - 'pyrevitlib', - 'site-packages', - 'pyRevitfile'] -basex = ['bin', - 'extensions', - 'pyrevitlib', - 'site-packages', - 'pyRevitfile'] \ No newline at end of file +core = ['bin', 'pyrevitlib', 'site-packages', 'pyRevitfile'] +corex = [ + 'bin', + 'extensions/pyRevitCore.extension', + 'extensions/extensions.json', + 'pyrevitlib', + 'site-packages', + 'pyRevitfile', +] +base = [ + 'bin', + 'extensions/pyRevitCore.extension', + 'extensions/pyRevitTags.extension', + 'extensions/pyRevitTools.extension', + 'extensions/extensions.json', + 'pyrevitlib', + 'site-packages', + 'pyRevitfile', +] +basepublic = [ + 'bin', + 'extensions/pyRevitCore.extension', + 'extensions/pyRevitTags.extension', + 'extensions/pyRevitTools.extension', + 'extensions/pyRevitTutor.extension', + 'extensions/extensions.json', + 'pyrevitlib', + 'site-packages', + 'pyRevitfile', +] +basex = ['bin', 'extensions', 'pyrevitlib', 'site-packages', 'pyRevitfile'] diff --git a/pyrevitlib/pyrevit/__init__.py b/pyrevitlib/pyrevit/__init__.py index a5f01d3b3..e27bb3787 100644 --- a/pyrevitlib/pyrevit/__init__.py +++ b/pyrevitlib/pyrevit/__init__.py @@ -54,8 +54,14 @@ except NameError: raise Exception('Critical Error. Can not find home directory.') + +# try get net folder +net_folder = "netfx" +if int(__revit__.Application.VersionNumber) >= 2025: + net_folder = "netcore" + # BIN directory -BIN_DIR = op.join(HOME_DIR, 'bin') +BIN_DIR = op.join(HOME_DIR, 'bin', net_folder) # main pyrevit lib folders MAIN_LIB_DIR = op.join(HOME_DIR, 'pyrevitlib') @@ -88,7 +94,7 @@ sys.path.append(ENGINES_DIR) -PYREVIT_CLI_PATH = op.join(BIN_DIR, PYREVIT_CLI_NAME) +PYREVIT_CLI_PATH = op.join(HOME_DIR, 'bin', PYREVIT_CLI_NAME) # now we can start importing stuff diff --git a/pyrevitlib/pyrevit/coreutils/__init__.py b/pyrevitlib/pyrevit/coreutils/__init__.py index d4634c0d9..c4014419a 100644 --- a/pyrevitlib/pyrevit/coreutils/__init__.py +++ b/pyrevitlib/pyrevit/coreutils/__init__.py @@ -31,7 +31,7 @@ from pyrevit import framework from pyrevit import api -# RE: https://github.com/eirannejad/pyRevit/issues/413 +# RE: https://github.com/pyrevitlabs/pyRevit/issues/413 # import uuid from System import Guid @@ -1282,7 +1282,7 @@ def format_hex_rgb(rgb_value): def new_uuid(): """Create a new UUID (using dotnet Guid.NewGuid).""" - # RE: https://github.com/eirannejad/pyRevit/issues/413 + # RE: https://github.com/pyrevitlabs/pyRevit/issues/413 # return uuid.uuid1() return str(Guid.NewGuid()) diff --git a/pyrevitlib/pyrevit/coreutils/appdata.py b/pyrevitlib/pyrevit/coreutils/appdata.py index 3491e85e4..7f647125a 100644 --- a/pyrevitlib/pyrevit/coreutils/appdata.py +++ b/pyrevitlib/pyrevit/coreutils/appdata.py @@ -95,7 +95,7 @@ def _match_file(file_name): if match: return match.groupdict() - # e.g. pyRevit_2018_eirannejad_ + # e.g. pyRevit_2018_pyrevitlabs_ match = re.match(pattern=pyrevit.PYREVIT_FILE_PREFIX_USER_REGEX, string=file_name) if match: @@ -107,7 +107,7 @@ def _match_file(file_name): if match: return match.groupdict() - # e.g. pyRevit_eirannejad_ + # e.g. pyRevit_pyrevitlabs_ match = re.match(pattern=pyrevit.PYREVIT_FILE_PREFIX_UNIVERSAL_USER_REGEX, string=file_name) if match: @@ -126,7 +126,7 @@ def get_universal_data_file(file_id, file_ext, name_only=False): """Get path to file that is shared between all host versions. These data files are not cleaned up at Revit restart. - e.g pyrevit_eirannejad_file_id.file_ext + e.g pyrevit_pyrevitlabs_file_id.file_ext Args: file_id (str): Unique identifier for the file @@ -143,7 +143,7 @@ def get_universal_data_file(file_id, file_ext, name_only=False): def get_data_file(file_id, file_ext, name_only=False): """Get path to file that will not be cleaned up at Revit load. - e.g pyrevit_2016_eirannejad_file_id.file_ext + e.g pyrevit_2016_pyrevitlabs_file_id.file_ext Args: file_id (str): Unique identifier for the file @@ -160,7 +160,7 @@ def get_instance_data_file(file_id, file_ext=TEMP_FILE_EXT, name_only=False): """Get path to file that should be used by current instance only. These data files will be cleaned up at Revit restart. - e.g pyrevit_2016_eirannejad_2353_file_id.file_ext + e.g pyrevit_2016_pyrevitlabs_2353_file_id.file_ext Args: file_id (str): Unique identifier for the file diff --git a/pyrevitlib/pyrevit/coreutils/ribbon.py b/pyrevitlib/pyrevit/coreutils/ribbon.py index a5588d286..5b0cf1abc 100644 --- a/pyrevitlib/pyrevit/coreutils/ribbon.py +++ b/pyrevitlib/pyrevit/coreutils/ribbon.py @@ -749,9 +749,19 @@ def set_tooltip_ext(self, tooltip_ext): def set_tooltip_image(self, tooltip_image): try: adwindows_obj = self.get_adwindows_object() - if adwindows_obj and adwindows_obj.ToolTip: - adwindows_obj.ToolTip.ExpandedImage = \ - load_bitmapimage(tooltip_image) + if adwindows_obj: + exToolTip = self.get_rvtapi_object().ToolTip + if not isinstance(exToolTip, str): + exToolTip = None + adwindows_obj.ToolTip = AdWindows.RibbonToolTip() + adwindows_obj.ToolTip.Title = self.ui_title + adwindows_obj.ToolTip.Content = exToolTip + _StackPanel = System.Windows.Controls.StackPanel() + _image = System.Windows.Controls.Image() + _image.Source = load_bitmapimage(tooltip_image) + _StackPanel.Children.Add(_image) + adwindows_obj.ToolTip.ExpandedContent = _StackPanel + adwindows_obj.ResolveToolTip() else: self.tooltip_image = tooltip_image except Exception as ttimage_err: @@ -761,11 +771,10 @@ def set_tooltip_image(self, tooltip_image): def set_tooltip_video(self, tooltip_video): try: adwindows_obj = self.get_adwindows_object() - if isinstance(self.get_rvtapi_object().ToolTip, str): - exToolTip = self.get_rvtapi_object().ToolTip - else: - exToolTip = None if adwindows_obj: + exToolTip = self.get_rvtapi_object().ToolTip + if not isinstance(exToolTip, str): + exToolTip = None adwindows_obj.ToolTip = AdWindows.RibbonToolTip() adwindows_obj.ToolTip.Title = self.ui_title adwindows_obj.ToolTip.Content = exToolTip diff --git a/pyrevitlib/pyrevit/forms/__init__.py b/pyrevitlib/pyrevit/forms/__init__.py index fdf433ced..da6a6d5d8 100644 --- a/pyrevitlib/pyrevit/forms/__init__.py +++ b/pyrevitlib/pyrevit/forms/__init__.py @@ -1315,6 +1315,9 @@ def handle_input_key(self, sender, args): elif args.Key == Input.Key.Enter: active_button = self._get_active_button() if active_button: + if isinstance(active_button, + framework.Controls.Primitives.ToggleButton): + return self.process_option(active_button, None) args.Handled = True elif args.Key != Input.Key.Tab \ @@ -2682,15 +2685,16 @@ def select_parameters(src_element, if include_type: # collect type parameters - src_type = revit.query.get_type(src_element) - param_defs.extend( - [ParamDef(name=x.Definition.Name, - istype=True, - definition=x.Definition, - isreadonly=x.IsReadOnly) - for x in src_type.Parameters - if x.StorageType != non_storage_type] - ) + src_type = revit.query.get_type(src_element) if src_element else None + if src_type is not None: + param_defs.extend( + [ParamDef(name=x.Definition.Name, + istype=True, + definition=x.Definition, + isreadonly=x.IsReadOnly) + for x in src_type.Parameters + if x.StorageType != non_storage_type] + ) if exclude_readonly: param_defs = filter(lambda x: not x.isreadonly, param_defs) @@ -3346,7 +3350,7 @@ def toast(message, title='pyRevit', appid='pyRevit', script.toast("Hello World!", title="My Script", appid="MyAPP", - click="https://eirannejad.github.io/pyRevit/", + click="https://pyrevitlabs.github.io/pyRevit/", actions={ "Open Google":"https://google.com", "Open Toast64":"https://github.com/go-toast/toast" diff --git a/pyrevitlib/pyrevit/framework.py b/pyrevitlib/pyrevit/framework.py index f9a081258..8735f31f7 100644 --- a/pyrevitlib/pyrevit/framework.py +++ b/pyrevitlib/pyrevit/framework.py @@ -14,6 +14,22 @@ import System +# netcore init +if int(__revit__.Application.VersionNumber) >= 2025: + clr.AddReference('System.Runtime') + clr.AddReference('System.Text.RegularExpressions') + clr.AddReference('System.Diagnostics.Process') + clr.AddReference('System.IO.FileSystem.DriveInfo') + clr.AddReference('System.Net.WebClient') + clr.AddReference('System.Net.Requests') + clr.AddReference('System.Net.WebProxy') + clr.AddReference('System.Runtime.Serialization.Formatters') + clr.AddReference('System.Reflection.Emit') + clr.AddReference('Lokad.ILPack') + clr.AddReference('System.ComponentModel') + clr.AddReference('System.ObjectModel') + clr.AddReference('System.Diagnostics.FileVersionInfo') + clr.AddReference('System.Core') clr.AddReference('System.Management') clr.AddReference('System.Windows.Forms') diff --git a/pyrevitlib/pyrevit/interop/adc.py b/pyrevitlib/pyrevit/interop/adc.py index 83b24beb6..78d4c5ae4 100644 --- a/pyrevitlib/pyrevit/interop/adc.py +++ b/pyrevitlib/pyrevit/interop/adc.py @@ -175,9 +175,9 @@ def is_synced(path): drive = _get_item_drive(adc, item) # ADC uses translated property names so # check status property by its type "LocalState" - # see https://github.com/eirannejad/pyRevit/issues/1152 + # see https://github.com/pyrevitlabs/pyRevit/issues/1152 # ADC version 15 changed property_id_value - # see https://github.com/eirannejad/pyRevit/issues/1371 + # see https://github.com/pyrevitlabs/pyRevit/issues/1371 prop_val = _get_item_property_id_value(adc, drive, item, 'DesktopConnector.Core.LocalState') if prop_val is None: # version older than ADC 15 diff --git a/pyrevitlib/pyrevit/labs.py b/pyrevitlib/pyrevit/labs.py index 75d910e1e..b0e8e3ca9 100644 --- a/pyrevitlib/pyrevit/labs.py +++ b/pyrevitlib/pyrevit/labs.py @@ -22,16 +22,8 @@ clr.AddReference('System.Text.Encoding.CodePages') # Revit, and its builtin addons, ship multiple versions of this assembly # let's make sure our specific version is loaded -if PY2: - clr.AddReferenceToFileAndPath( - op.join(BIN_DIR, 'System.Runtime.CompilerServices.Unsafe.dll') - ) - clr.AddReferenceToFileAndPath( - op.join(BIN_DIR, 'System.Memory.dll') - ) -else: - clr.AddReference('System.Runtime.CompilerServices.Unsafe') - clr.AddReference('System.Memory.dll') +clr.AddReference('System.Runtime.CompilerServices.Unsafe') +clr.AddReference('System.Memory') # clr.AddReference('System.Memory') clr.AddReference('System.Reflection.Metadata') clr.AddReference('Microsoft.CodeAnalysis') diff --git a/pyrevitlib/pyrevit/loader/asmmaker.py b/pyrevitlib/pyrevit/loader/asmmaker.py index 0b8b32ae3..da4060336 100644 --- a/pyrevitlib/pyrevit/loader/asmmaker.py +++ b/pyrevitlib/pyrevit/loader/asmmaker.py @@ -17,6 +17,7 @@ from pyrevit.runtime import typemaker from pyrevit.userconfig import user_config +from System.Reflection.Emit import AssemblyBuilder # Generic named tuple for passing assembly information to other modules ExtensionAssemblyInfo = namedtuple('ExtensionAssemblyInfo', @@ -94,15 +95,23 @@ def _create_asm_file(extension, ext_asm_file_name, ext_asm_file_path): mlogger.debug('Generated assembly file name for this package: %s', ext_asm_full_file_name) - # get assembly builder - asm_builder = AppDomain.CurrentDomain.DefineDynamicAssembly( - win_asm_name, - AssemblyBuilderAccess.RunAndSave, - op.dirname(ext_asm_file_path)) + if int(__revit__.Application.VersionNumber) >= 2025: + asm_builder = AssemblyBuilder.DefineDynamicAssembly( + win_asm_name, + AssemblyBuilderAccess.Run) - # get module builder - module_builder = asm_builder.DefineDynamicModule(ext_asm_file_name, - ext_asm_full_file_name) + # get module builder + module_builder = asm_builder.DefineDynamicModule(ext_asm_file_name) + else: + # get assembly builder + asm_builder = AppDomain.CurrentDomain.DefineDynamicAssembly( + win_asm_name, + AssemblyBuilderAccess.RunAndSave, + op.dirname(ext_asm_file_path)) + + # get module builder + module_builder = asm_builder.DefineDynamicModule(ext_asm_file_name, + ext_asm_full_file_name) # create command classes for cmd_component in extension.get_all_commands(): @@ -110,8 +119,14 @@ def _create_asm_file(extension, ext_asm_file_name, ext_asm_file_path): mlogger.debug('Creating types for command: %s', cmd_component) typemaker.make_bundle_types(extension, cmd_component, module_builder) - # save final assembly - asm_builder.Save(ext_asm_full_file_name) + if int(__revit__.Application.VersionNumber) >= 2025: + from Lokad.ILPack import AssemblyGenerator + generator = AssemblyGenerator() + generator.GenerateAssembly(asm_builder, ext_asm_file_path) + else: + # save final assembly + asm_builder.Save(ext_asm_full_file_name) + assmutils.load_asm_file(ext_asm_file_path) mlogger.debug('Executer assembly saved.') diff --git a/pyrevitlib/pyrevit/revit/db/transaction.py b/pyrevitlib/pyrevit/revit/db/transaction.py index 6bd4d369d..1c849eecd 100644 --- a/pyrevitlib/pyrevit/revit/db/transaction.py +++ b/pyrevitlib/pyrevit/revit/db/transaction.py @@ -77,8 +77,10 @@ def __exit__(self, exception, exception_value, traceback): self._rvtxn.Commit() except Exception as errmsg: self._rvtxn.RollBack() - mlogger.error('Error in Transaction Commit. ' - 'Rolling back changes. | %s', errmsg) + if self._logerror: + mlogger.error('Error in Transaction Commit. ' + 'Rolling back changes. | %s', errmsg) + self._rvtxn.Dispose() @property def name(self): @@ -105,6 +107,7 @@ class DryTransaction(Transaction): """Wrapper to a transaction that doesn't commit anything (dry-run).""" def __exit__(self, exception, exception_value, traceback): self._rvtxn.RollBack() + self._rvtxn.Dispose() class TransactionGroup(): @@ -135,8 +138,10 @@ def __exit__(self, exception, exception_value, traceback): self._rvtxn_grp.Commit() except Exception as errmsg: self._rvtxn_grp.RollBack() - mlogger.error('Error in TransactionGroup Commit: rolled back.') - mlogger.error('Error: %s', errmsg) + if self._logerror: + mlogger.error('Error in TransactionGroup Commit. ' + 'Rolling back changes. | %s', errmsg) + self._rvtxn_grp.Dispose() @property def name(self): diff --git a/pyrevitlib/pyrevit/revit/selection.py b/pyrevitlib/pyrevit/revit/selection.py index 14a4ae759..f5b2f2206 100644 --- a/pyrevitlib/pyrevit/revit/selection.py +++ b/pyrevitlib/pyrevit/revit/selection.py @@ -5,6 +5,7 @@ from pyrevit.revit import ensure from pyrevit.revit import query +from Autodesk.Revit import Exceptions as RevitExceptions __all__ = ('pick_element', 'pick_element_by_category', @@ -145,74 +146,53 @@ def AllowReference(self, refer, point): # pylint: disable=W0613 def _pick_obj(obj_type, message, multiple=False, world=False, selection_filter=None): - refs = [] - + mlogger.debug( + "Picking elements: %s " "message: %s " "multiple: %s " "world: %s", + obj_type, + message, + multiple, + world, + ) + picker_func = ( + HOST_APP.uidoc.Selection.PickObjects + if multiple + else HOST_APP.uidoc.Selection.PickObject + ) try: - mlogger.debug('Picking elements: %s ' - 'message: %s ' - 'multiple: %s ' - 'world: %s', obj_type, message, multiple, world) - - # decide which picker method to use - picker_func = HOST_APP.uidoc.Selection.PickObject - if multiple: - picker_func = HOST_APP.uidoc.Selection.PickObjects - - # call the correct signature of the picker function - # if selection filter is provided - if selection_filter: - pick_result = \ - picker_func( - obj_type, - selection_filter, - message - ) - else: - pick_result = \ - picker_func( - obj_type, - message - ) - - # process the results - if multiple: - refs = list(pick_result) - else: - refs = [] - refs.append(pick_result) - - if not refs: - mlogger.debug('Nothing picked by user...Returning None') - return None - - mlogger.debug('Picked elements are: %s', refs) - - if obj_type == UI.Selection.ObjectType.Element: - return_values = \ - [DOCS.doc.GetElement(ref) - for ref in refs] - elif obj_type == UI.Selection.ObjectType.PointOnElement: - if world: - return_values = [ref.GlobalPoint for ref in refs] - else: - return_values = [ref.UVPoint for ref in refs] - else: - return_values = \ - [DOCS.doc.GetElement(ref) - .GetGeometryObjectFromReference(ref) - for ref in refs] + pick_result = ( + picker_func(obj_type, selection_filter, message) + if selection_filter + else picker_func(obj_type, message) + ) + except RevitExceptions.OperationCanceledException: + mlogger.debug("Operation canceled by user") + return None + refs = list(pick_result) if multiple else [pick_result] + if not refs: + mlogger.debug("Nothing picked by user") + return None - mlogger.debug('Processed return elements are: %s', return_values) + mlogger.debug("Picked elements are: %s", refs) - if len(return_values) > 1 or multiple: - return return_values - elif len(return_values) == 1: - return return_values[0] + if obj_type == UI.Selection.ObjectType.Element: + return_values = [DOCS.doc.GetElement(ref) for ref in refs] + elif obj_type == UI.Selection.ObjectType.PointOnElement: + if world: + return_values = [ref.GlobalPoint for ref in refs] else: - mlogger.error('Error processing picked elements. ' - 'return_values should be a list.') - except Exception: - return None + return_values = [ref.UVPoint for ref in refs] + else: + return_values = [ + DOCS.doc.GetElement(ref).GetGeometryObjectFromReference(ref) for ref in refs + ] + + mlogger.debug("Processed return elements are: %s", return_values) + + if len(return_values) > 1 or multiple: + return return_values + if len(return_values) == 1: + return return_values[0] + mlogger.error("Error processing picked elements. return_values should be a list.") def pick_element(message=''): diff --git a/pyrevitlib/pyrevit/runtime/__init__.py b/pyrevitlib/pyrevit/runtime/__init__.py index fd030394e..8400d6be2 100644 --- a/pyrevitlib/pyrevit/runtime/__init__.py +++ b/pyrevitlib/pyrevit/runtime/__init__.py @@ -11,7 +11,7 @@ from pyrevit import api from pyrevit import labs from pyrevit.compat import safe_strtype -from pyrevit import RUNTIME_DIR +from pyrevit import BIN_DIR, RUNTIME_DIR from pyrevit import coreutils from pyrevit.coreutils import assmutils from pyrevit.coreutils import logger @@ -92,12 +92,6 @@ if not EXEC_PARAMS.doc_mode: # get and load the active Cpython engine CPYTHON_ENGINE = user_config.get_active_cpython_engine() - if CPYTHON_ENGINE: - CPYTHON_ENGINE_ASSM = CPYTHON_ENGINE.AssemblyPath - mlogger.debug('Loading cpython engine: %s', CPYTHON_ENGINE_ASSM) - assmutils.load_asm_file(CPYTHON_ENGINE_ASSM) - else: - raise PyRevitException('Can not find cpython engines.') # create a hash for the loader assembly # this hash is calculated based on: @@ -115,9 +109,10 @@ )[:HASH_CUTOFF_LENGTH] RUNTIME_ASSM_FILE_ID = '{}_{}'\ .format(BASE_TYPES_DIR_HASH, RUNTIME_NAMESPACE) + RUNTIME_ASSM_FILE = \ - appdata.get_data_file(RUNTIME_ASSM_FILE_ID, - framework.ASSEMBLY_FILE_TYPE) + op.join(BIN_DIR, "pyRevitLabs.PyRevit.Runtime.{}.dll".format(__revit__.Application.VersionNumber)) + # taking the name of the generated data file and use it as assembly name RUNTIME_ASSM_NAME = op.splitext(op.basename(RUNTIME_ASSM_FILE))[0] mlogger.debug('Interface types assembly file is: %s', RUNTIME_ASSM_NAME) @@ -278,41 +273,14 @@ def get_references(): if HOST_APP.is_newer_than(2018): ref_list.extend(['Xceed.Wpf.AvalonDock']) - refs = [_get_reference_file(ref_name) for ref_name in ref_list] - - # add cpython engine assembly - refs.append(CPYTHON_ENGINE_ASSM) - - return refs + return [_get_reference_file(ref_name) for ref_name in ref_list] def _generate_runtime_asm(): source_list = list(_get_source_files()) - # now try to compile + # now try to load compiled runtime assembly try: - mlogger.debug('Compiling base types to: %s', RUNTIME_ASSM_FILE) - res, msgs = labs.Common.CodeCompiler.CompileCSharp( - sourceFiles=Array[str](source_list), - outputPath=RUNTIME_ASSM_FILE, - references=Array[str]( - get_references() - ), - defines=Array[str]([ - "REVIT{}".format(HOST_APP.version), - "REVIT{}".format(HOST_APP.subversion.replace('.', '_')) - ]), - debug=False - ) - # log results - logfile = RUNTIME_ASSM_FILE.replace('.dll', '.log') - with open(logfile, 'w') as lf: - lf.write('\n'.join(msgs)) - # load compiled dll if successful - if res: - return assmutils.load_asm_file(RUNTIME_ASSM_FILE) - # otherwise raise hell - else: - raise PyRevitException('\n'.join(msgs)) + return assmutils.load_asm_file(RUNTIME_ASSM_FILE) except PyRevitException as compile_err: errors = safe_strtype(compile_err).replace('Compile error: ', '') mlogger.critical('Can not compile base types code into assembly.\n%s', diff --git a/pyrevitlib/pyrevit/version b/pyrevitlib/pyrevit/version index 04d19da3f..5ca92a604 100644 --- a/pyrevitlib/pyrevit/version +++ b/pyrevitlib/pyrevit/version @@ -1 +1 @@ -4.8.15 \ No newline at end of file +5.0.0.24174+2300 \ No newline at end of file diff --git a/pyrevitlib/rpw/ui/forms/os_dialog.py b/pyrevitlib/rpw/ui/forms/os_dialog.py index 41b39af55..28c931b14 100644 --- a/pyrevitlib/rpw/ui/forms/os_dialog.py +++ b/pyrevitlib/rpw/ui/forms/os_dialog.py @@ -1,6 +1,6 @@ """ Standard IO Dialogs -Original code by github.com/eirannejad/pyRevit +Original code by github.com/pyrevitlabs/pyRevit """ # diff --git a/pyrevitlib/rpw/ui/forms/resources.py b/pyrevitlib/rpw/ui/forms/resources.py index badbda01f..9c574b97a 100644 --- a/pyrevitlib/rpw/ui/forms/resources.py +++ b/pyrevitlib/rpw/ui/forms/resources.py @@ -7,9 +7,11 @@ from abc import ABCMeta -from rpw import revit -from rpw.utils.dotnet import clr -from rpw.utils.logger import logger +import clr + +import os.path as op +from pyrevit.compat import PY3, PY2 +import pyrevit.engine as eng # WPF/Form Imports clr.AddReference("PresentationFramework") # System.Windows: Controls, ? @@ -33,16 +35,29 @@ # OS Dialogs from System.Windows import Forms -if revit.host == 'Dynamo': - # IronPython 2.7.3 - Dynamo + RPS w/out pyRevit - # Conflicts with PyRevit. Must Ensure exact path is specified - # https://github.com/architecture-building-systems/revitpythonshell/issues/46 - clr.AddReferenceToFileAndPath(r'C:\Program Files (x86)\IronPython 2.7\Platforms\Net40\IronPython.Wpf.dll') - import wpf - # on 2.7.7 this raises wpf import error + +ASSEMBLY_FILE_TYPE = 'dll' +ASSEMBLY_FILE_EXT = '.dll' + +ipy_assmname = '{prefix}IronPython'.format(prefix=eng.EnginePrefix) +ipy_dllpath = op.join(eng.EnginePath, ipy_assmname + ASSEMBLY_FILE_EXT) +if PY3: + clr.AddReference(ipy_dllpath) else: - # IronPython 2.7.7 - pyRevit - # clr.AddReference('IronPython') # Works W/Out - clr.AddReference('IronPython.Wpf') # 2.7. - from IronPython.Modules import Wpf as wpf - # on 2.7.7 this works. On 2.7.3 you get a LoadComponent 3 args error + clr.AddReferenceToFileAndPath(ipy_dllpath) + +import IronPython + +# WPF +wpf = None +wpf_assmname = '{prefix}IronPython.Wpf'.format(prefix=eng.EnginePrefix) +wpf_dllpath = op.join(eng.EnginePath, wpf_assmname + ASSEMBLY_FILE_EXT) +try: + clr.AddReference(wpf_assmname) + if PY3: + wpf = IronPython.Modules.Wpf + else: + import wpf +except Exception: + clr.AddReferenceToFileAndPath(wpf_dllpath) + import wpf \ No newline at end of file diff --git a/release/.pyrevitargs b/release/.pyrevitargs index ef1392d9f..76ced8a5d 100644 --- a/release/.pyrevitargs +++ b/release/.pyrevitargs @@ -1,3 +1,3 @@ -https://github.com/eirannejad/pyRevit/archive/master.zip +https://github.com/pyrevitlabs/pyRevit/archive/master.zip master -basepublic \ No newline at end of file +basepublic diff --git a/release/choco/pyrevit-cli.nuspec b/release/choco/pyrevit-cli.nuspec index 6f7f1a06b..ddd116fd8 100644 --- a/release/choco/pyrevit-cli.nuspec +++ b/release/choco/pyrevit-cli.nuspec @@ -2,7 +2,7 @@ pyrevit-cli - 4.8.14.24016 + 5.0.0.24174 https://github.com/eirannejad/pyRevit/tree/master/release/choco/ Ehsan Iran-Nejad pyRevit CLI @@ -20,7 +20,7 @@ and configure pyRevit in your production/development environment. Each section below showcases a specific set of functionality of the command line tool. - https://github.com/eirannejad/pyRevit/releases/tag/v4.8.14.24016%2B1909/ + https://github.com/eirannejad/pyRevit/releases/tag/v5.0.0.24174%2B2300/ diff --git a/release/choco/tools/chocolateyinstall.ps1 b/release/choco/tools/chocolateyinstall.ps1 index 6999aef46..6baa445b8 100644 --- a/release/choco/tools/chocolateyinstall.ps1 +++ b/release/choco/tools/chocolateyinstall.ps1 @@ -2,7 +2,7 @@ $ErrorActionPreference = 'Stop'; $toolsDir = "$(Split-Path -parent $MyInvocation.MyCommand.Definition)" -$url64 = 'https://github.com/eirannejad/pyRevit/releases/download/v4.8.14.24016/pyRevit_CLI_4.8.14.24016_admin_signed.exe' +$url64 = 'https://github.com/pyrevitlabs/pyRevit/releases/download/v4.8.16.24121%2B2117/pyRevit_CLI_4.8.16.24121_admin_signed.exe' $packageArgs = @{ packageName = $env:ChocolateyPackageName @@ -12,7 +12,7 @@ $packageArgs = @{ softwareName = 'pyrevit-cli*' - checksum64 = 'BAA23042B9EB3EDB55E6089751190276F7A8049A0520BA6F76A6EC24F7137D18' + checksum64 = '1A46DAD7AF5ADB3BD0C9E589B6E51FBCF06BD6348CF520E8142FA3781456FECA' checksumType64= 'sha256' silentArgs = "/VERYSILENT" diff --git a/release/pyrevit-admin.iss b/release/pyrevit-admin.iss index 5d9721a9e..3c7a42b6f 100644 --- a/release/pyrevit-admin.iss +++ b/release/pyrevit-admin.iss @@ -1,6 +1,6 @@ #define MyAppName "pyRevit" #define MyAppUUID "f2a3da53-6f34-41d5-abbd-389ffa7f4d5f" -#define MyAppVersion "4.8.14.24016" +#define MyAppVersion "5.0.0.24174" #define MyAppPublisher "pyRevitLabs" #define MyAppURL "pyrevitlabs.io" @@ -80,7 +80,7 @@ Root: HKLM; Subkey: "SYSTEM\CurrentControlSet\Control\Session Manager\Environmen Filename: "{app}\bin\pyrevit.exe"; Description: "Clearning caches..."; Parameters: "caches clear --all"; Flags: runhidden runascurrentuser Filename: "{app}\bin\pyrevit.exe"; Description: "Detach existing clones..."; Parameters: "detach --all"; Flags: runhidden runascurrentuser Filename: "{app}\bin\pyrevit.exe"; Description: "Registering this clone..."; Parameters: "clones add this master --force"; Flags: runhidden runascurrentuser -Filename: "{app}\bin\pyrevit.exe"; Description: "Attaching this clone..."; Parameters: "attach master 2711 --installed"; Flags: runhidden runascurrentuser +Filename: "{app}\bin\pyrevit.exe"; Description: "Attaching this clone..."; Parameters: "attach master default --installed"; Flags: runhidden runascurrentuser [UninstallRun] Filename: "{app}\bin\pyrevit.exe"; RunOnceId: "ClearCaches"; Parameters: "caches clear --all"; Flags: runhidden runascurrentuser diff --git a/release/pyrevit-bin.wxs b/release/pyrevit-bin.wxs index ee73820fb..2e9b28223 100644 --- a/release/pyrevit-bin.wxs +++ b/release/pyrevit-bin.wxs @@ -17,8 +17,8 @@ - - + + @@ -194,7 +194,7 @@ - + diff --git a/release/pyrevit-cli-admin.iss b/release/pyrevit-cli-admin.iss index 501dedf85..d472bcd7d 100644 --- a/release/pyrevit-cli-admin.iss +++ b/release/pyrevit-cli-admin.iss @@ -1,6 +1,6 @@ #define MyAppName "pyRevit CLI" #define MyAppUUID "9557b432-cf79-4ece-91cf-b8f996c88b47" -#define MyAppVersion "4.8.14.24016" +#define MyAppVersion "5.0.0.24174" #define MyAppPublisher "pyRevitLabs" #define MyAppURL "pyrevitlabs.io" #define MyAppExeName "pyrevit.exe" diff --git a/release/pyrevit-cli.iss b/release/pyrevit-cli.iss index d0d82e31a..4d212641f 100644 --- a/release/pyrevit-cli.iss +++ b/release/pyrevit-cli.iss @@ -1,6 +1,6 @@ #define MyAppName "pyRevit CLI" #define MyAppUUID "9557b432-cf79-4ece-91cf-b8f996c88b47" -#define MyAppVersion "4.8.14.24016" +#define MyAppVersion "5.0.0.24174" #define MyAppPublisher "pyRevitLabs" #define MyAppURL "pyrevitlabs.io" #define MyAppExeName "pyrevit.exe" diff --git a/release/pyrevit-cli.props b/release/pyrevit-cli.props index 29d4a5758..e28292a17 100644 --- a/release/pyrevit-cli.props +++ b/release/pyrevit-cli.props @@ -1,7 +1,7 @@ - 9557b432-cf79-4ece-91cf-b8f996c88b47 + 2669428b-35bc-4824-afb5-9c8b7e343d3d 618520c4-0c3a-4e8d-8e8a-b74db3f3592b diff --git a/release/pyrevit-common.props b/release/pyrevit-common.props index b426482ae..9776fdab7 100644 --- a/release/pyrevit-common.props +++ b/release/pyrevit-common.props @@ -1,7 +1,7 @@ - 4.8.14.24016 + 5.0.0.24174 Copyright © 2014-2024 pyRevitLabs.io diff --git a/release/pyrevit.aip b/release/pyrevit.aip index 19aafd3dd..f06e9d91d 100644 --- a/release/pyrevit.aip +++ b/release/pyrevit.aip @@ -3257,8 +3257,8 @@ - - + + diff --git a/release/pyrevit.iss b/release/pyrevit.iss index ef8b2d756..46743e05a 100644 --- a/release/pyrevit.iss +++ b/release/pyrevit.iss @@ -1,6 +1,6 @@ #define MyAppName "pyRevit" #define MyAppUUID "f2a3da53-6f34-41d5-abbd-389ffa7f4d5f" -#define MyAppVersion "4.8.14.24016" +#define MyAppVersion "5.0.0.24174" #define MyAppPublisher "pyRevitLabs" #define MyAppURL "pyrevitlabs.io" @@ -80,7 +80,7 @@ Root: HKCU; Subkey: "Environment"; ValueType: expandsz; ValueName: "Path"; Value Filename: "{app}\bin\pyrevit.exe"; Description: "Clearning caches..."; Parameters: "caches clear --all"; Flags: runhidden Filename: "{app}\bin\pyrevit.exe"; Description: "Detach existing clones..."; Parameters: "detach --all"; Flags: runhidden Filename: "{app}\bin\pyrevit.exe"; Description: "Registering this clone..."; Parameters: "clones add this master --force"; Flags: runhidden -Filename: "{app}\bin\pyrevit.exe"; Description: "Attaching this clone..."; Parameters: "attach master 2711 --installed"; Flags: runhidden +Filename: "{app}\bin\pyrevit.exe"; Description: "Attaching this clone..."; Parameters: "attach master default --installed"; Flags: runhidden [UninstallRun] Filename: "{app}\bin\pyrevit.exe"; RunOnceId: "ClearCaches"; Parameters: "caches clear --all"; Flags: runhidden diff --git a/release/version b/release/version index 04d19da3f..558be7ca1 100644 --- a/release/version +++ b/release/version @@ -1 +1 @@ -4.8.15 \ No newline at end of file +5.0.0.24174 \ No newline at end of file