1*f585d8a3SJacky Wang# Copyright (C) 2019 The Dagger Authors. 2*f585d8a3SJacky Wang# 3*f585d8a3SJacky Wang# Licensed under the Apache License, Version 2.0 (the "License"); 4*f585d8a3SJacky Wang# you may not use this file except in compliance with the License. 5*f585d8a3SJacky Wang# You may obtain a copy of the License at 6*f585d8a3SJacky Wang# 7*f585d8a3SJacky Wang# http://www.apache.org/licenses/LICENSE-2.0 8*f585d8a3SJacky Wang# 9*f585d8a3SJacky Wang# Unless required by applicable law or agreed to in writing, software 10*f585d8a3SJacky Wang# distributed under the License is distributed on an "AS IS" BASIS, 11*f585d8a3SJacky Wang# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12*f585d8a3SJacky Wang# See the License for the specific language governing permissions and 13*f585d8a3SJacky Wang# limitations under the License. 14*f585d8a3SJacky Wang 15*f585d8a3SJacky Wang# Description: 16*f585d8a3SJacky Wang# An example of using dagger in a computerized fake ATM. The User's Guide (https://dagger.dev/users-guide) 17*f585d8a3SJacky Wang# is a walkthrough that ultimately builds this example. 18*f585d8a3SJacky Wang 19*f585d8a3SJacky Wangload("@rules_java//java:defs.bzl", "java_binary", "java_library") 20*f585d8a3SJacky Wang 21*f585d8a3SJacky Wangpackage(default_visibility = ["//:src"]) 22*f585d8a3SJacky Wang 23*f585d8a3SJacky Wangjava_library( 24*f585d8a3SJacky Wang name = "atm", 25*f585d8a3SJacky Wang srcs = glob(["*.java"]), 26*f585d8a3SJacky Wang deps = ["//:dagger_with_compiler"], 27*f585d8a3SJacky Wang) 28*f585d8a3SJacky Wang 29*f585d8a3SJacky Wangjava_binary( 30*f585d8a3SJacky Wang name = "CommandLineAtm", 31*f585d8a3SJacky Wang main_class = "dagger.example.atm.CommandLineAtm", 32*f585d8a3SJacky Wang runtime_deps = [":atm"], 33*f585d8a3SJacky Wang) 34