Description Properties Active bindings Methods Examples
NetType provide the name and namespace of a .Net type
Name
: .Net type
Namespace
: .Net type namespace
FullName
: Full .Net type
Name
.Net type name.
Namespace
namespace of .Net type.
FullName
.Net type name
new()
Create a new NetType object.
NetType$new(namespace, name)
namespace
Namespace namespace of .Net type.
name
.Net type name.
createObject()
Create a new .Net object and wrap it.
NetType$createObject(...)
...
Ctor arguments of the .Net type
clone()
The objects of this class are cloneable with this method.
NetType$clone(deep = FALSE)
deep
Whether to make a deep clone.
1 2 3 4 5 6 7 8 9 10 11 12 13 | ## Not run:
library(sharper)
package_folder <- path.package("sharper")
netLoadAssembly(file.path(package_folder, "tests", "AssemblyForTests.dll"))
netType <- NetType$new("AssemblyForTests", "ManyCtorData")
print(sprintf("Name=%s, Namespace=%s, FullName=%s",
netType$Name, netType$Namespace, netType$FullName))
object <- netType$createObject(21L)
object$get("Id")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.