Skip to content
Jeff Pang edited this page Aug 12, 2013 · 3 revisions

Welcome to the AppDomainSample. This is a Sample App which accompanies the 2 part article Working with AppDomain and Working with AppDomain Part 2 to help understand it. This Sample App also serves as a scaffold to help jump-start projects that works with AppDomain in mind.

List of commands available from the Sample App:

  1. domain -new [domain name]

    e.g domain -new test1. This will create a new child domain with the name “test1″ and start the auto counter

  2. domain -unload [domain name]

    e.g domain -unload test1. This will unload the domain with the name “test1″

  3. ref -show [domain name]

    e.g ref -show test1. This will show the value of the ReferencedObject in domain “test1″ and that of the copy residing in host domain

  4. ref -set [domain name] -value [string value]

    e.g ref -set test1 -value 10 – This will set a value of ReferencedObject in domain “test1″ to “10″

  5. var -show [domain name]

    e.g var -show test1 – This will show the value of the SerializableObject in domain “test1″ and that of the copy residing in host domain

  6. var -set [domain name] -value [string value]

    e.g var -set test1 -value 10 – This will set a value of SerializeableObject in domain “test1″ to “10″

  7. var -refresh [domain name]

    e.g var -refresh test1 – This will get the SerializeableObject from Child Domain to update to the Host Domain

  8. var -tryget [domain name]

    e.g var -tryget test1 – This will attempt to get the NonSerializeableObject from Child Domain to to the Host Domain. This will throw an exception which will be caught and displayed on console.

Clone this wiki locally