-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
83 lines (67 loc) · 2.94 KB
/
index.html
File metadata and controls
83 lines (67 loc) · 2.94 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="chrome=1">
<title>Divineinject.GitHub.io by DivineInject</title>
<link rel="stylesheet" href="stylesheets/styles.css">
<link rel="stylesheet" href="stylesheets/github-dark.css">
<link rel="stylesheet" href="stylesheets/buttons.css">
<link rel="stylesheet" href="stylesheets/nav.css">
<script src="javascripts/scale.fix.js"></script>
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
<!--[if lt IE 9]>
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
</head>
<body>
<div class="wrapper">
<header class="without-description">
<h1>DivineInject.GitHub.io</h1>
<p></p>
<p class="view"><a href="https://github.com/DivineInject">View the Project on GitHub <small>DivineInject</small></a></p>
<ul>
<li class="single"><a href="https://github.com/DivineInject/DivineInject.github.io">View On <strong>GitHub</strong></a></li>
</ul>
</header>
<ul id="nav">
<li><a href="index.html" class="myButton">About</a></li>
<li><a href="why.html" class="myButton">Why</a></li>
<li><a href="getting_started.html" class="myButton">Getting Started</a></li>
<li><a href="scopes.html" class="myButton">Scopes</a></li>
<li><a href="rich_domain_objects.html" class="myButton">Rich Domain</a></li>
</ul>
<section>
<h1>
<a id="divine-inject" class="anchor" href="#divine-inject" aria-hidden="true"><span class="octicon octicon-link"></span></a>Divine Inject</h1>
<p>DivineInject is a .net dependency injection framework, designed to be simple to use and easy to understand.</p>
<p>See how to <a href="#quickstart">get started in 30 seconds</a>, find out <a href="why.html">why we created DivineInject</a> or
<a href="getting_started.html">read more detailed documentation</a>.
<h2>
<a id="quickstart" class="anchor" href="#quickstart" aria-hidden="true"><span class="octicon octicon-link"></span></a>Quick Start</h2>
<p>First, install the nuget package:</p>
<pre>
Install-Package DivineInject
</pre>
<p>Second, wire up your dependencies:</p>
<pre>
DivineInjector.Current
.Bind<IDatabaseProvider>().To<MSSQLDatabaseProvider>()
.Bind<IOrderService>().To<OrderService>();
</pre>
<p>Third, create your root object:</p>
<pre>
public object GetInstance(InstanceContext instanceContext, Message message)
{
return DivineInjector.Current.Get(m_instanceType);
}
</pre>
<p><i>This is a snippet from a WCF service's IInstanceProvider implementation, other application types will obviously create their root object differently</i></p>
</section>
</div>
<footer>
<p>Hosted on GitHub Pages — Theme by <a href="https://github.com/orderedlist">orderedlist</a></p>
</footer>
<!--[if !IE]><script>fixScale(document);</script><![endif]-->
</body>
</html>