Sheath

A small wrapper of Dagger to facilitate interaction with the object graph

Лицензия

Лицензия

Группа

Группа

io.pristine.sheath
Идентификатор

Идентификатор

sheath
Последняя версия

Последняя версия

1.0.0
Дата

Дата

Тип

Тип

jar
Описание

Описание

Sheath
A small wrapper of Dagger to facilitate interaction with the object graph
Ссылка на сайт

Ссылка на сайт

https://github.com/pristineio/sheath
Система контроля версий

Система контроля версий

https://github.com/pristineio/sheath

Скачать sheath

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/io.pristine.sheath/sheath/ -->
<dependency>
    <groupId>io.pristine.sheath</groupId>
    <artifactId>sheath</artifactId>
    <version>1.0.0</version>
</dependency>
// https://jarcasting.com/artifacts/io.pristine.sheath/sheath/
implementation 'io.pristine.sheath:sheath:1.0.0'
// https://jarcasting.com/artifacts/io.pristine.sheath/sheath/
implementation ("io.pristine.sheath:sheath:1.0.0")
'io.pristine.sheath:sheath:jar:1.0.0'
<dependency org="io.pristine.sheath" name="sheath" rev="1.0.0">
  <artifact name="sheath" type="jar" />
</dependency>
@Grapes(
@Grab(group='io.pristine.sheath', module='sheath', version='1.0.0')
)
libraryDependencies += "io.pristine.sheath" % "sheath" % "1.0.0"
[io.pristine.sheath/sheath "1.0.0"]

Зависимости

compile (2)

Идентификатор библиотеки Тип Версия
com.squareup.dagger : dagger jar 1.2.2
com.squareup.dagger : dagger-compiler jar 1.2.2

test (1)

Идентификатор библиотеки Тип Версия
junit : junit-dep jar 4.8.2

Модули Проекта

Данный проект не имеет модулей.

Sheath

A very very simple static wrapper for Dagger.

Usage

This was made with Android development in mind because I didn't like writing static getters for my Application contexts in order to inject new entities into the object graph.

First you must call holster with all your modules before you can inject anything.

public class MyApplication extends Application {
    public void onCreate() {
        super.onCreate();

        // You are now ready to wield your Dagger
        Sheath.holster(new ModuleOne(), new ModuleTwo());
    }
}

After holster is called you can now inject your objects

public class MyActivity extends Activity {
    public void onCreate() {
        super.onCreate();

        Sheath.inject(this);
    }
}

Download

Including Sheath in your project gives you Dagger so don't worry about including it unless you want a specific version of Dagger. If you are doing this be sure to exclude the version of Dagger included with Sheath.

Maven

<dependency>
	<groupId>io.pristine.sheath</groupId>
	<artifactId>sheath</artifactId>
	<version>{latest-version}</version>
</dependency>

Gradle

compile 'io.pristine.sheath:sheath:{latest-version}'

License

Copyright 2014-2015, Pristine Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

io.pristine.sheath

Pristine, Inc.

Pristine, Inc.

Версии библиотеки

Версия
1.0.0