Skip to content

Commit

Permalink
라이센스 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
hongbeomi committed Apr 14, 2020
1 parent eb11189 commit f2b6100
Show file tree
Hide file tree
Showing 22 changed files with 342 additions and 23 deletions.
1 change: 1 addition & 0 deletions .idea/gradle.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 17 additions & 0 deletions app/src/main/java/com/hongbeomi/harrypotter/HarryPotterApp.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import android.app.Application
import com.hongbeomi.harrypotter.di.dataSourceModule
import com.hongbeomi.harrypotter.di.networkModule
Expand Down
17 changes: 17 additions & 0 deletions app/src/main/java/com/hongbeomi/harrypotter/base/BaseActivity.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.base

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import androidx.annotation.LayoutRes
import androidx.appcompat.app.AppCompatActivity
import androidx.databinding.DataBindingUtil
Expand Down
13 changes: 0 additions & 13 deletions app/src/main/java/com/hongbeomi/harrypotter/base/BaseViewHolder.kt

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.data.remote

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import com.hongbeomi.harrypotter.model.Character

interface RemoteDataSource {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.data.remote

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import com.hongbeomi.harrypotter.data.service.HarryPotterService

class RemoteDataSourceImpl(private val service: HarryPotterService) : RemoteDataSource {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.data.repository

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import com.hongbeomi.harrypotter.model.Character

interface Repository {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.data.repository

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import com.hongbeomi.harrypotter.data.remote.RemoteDataSource

class RepositoryImpl(private val remoteDataSource: RemoteDataSource) : Repository {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.data.service

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import com.hongbeomi.harrypotter.model.Character
import retrofit2.http.GET
import retrofit2.http.Path
Expand Down
17 changes: 17 additions & 0 deletions app/src/main/java/com/hongbeomi/harrypotter/di/DataSourceModule.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.di

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import com.hongbeomi.harrypotter.data.remote.RemoteDataSource
import com.hongbeomi.harrypotter.data.remote.RemoteDataSourceImpl
import org.koin.dsl.module
Expand Down
25 changes: 17 additions & 8 deletions app/src/main/java/com/hongbeomi/harrypotter/di/NetworkModule.kt
Original file line number Diff line number Diff line change
@@ -1,21 +1,30 @@
package com.hongbeomi.harrypotter.di

import com.google.gson.GsonBuilder
import com.google.gson.JsonSyntaxException
import com.google.gson.TypeAdapter
import com.google.gson.stream.JsonReader
import com.google.gson.stream.JsonToken
import com.google.gson.stream.JsonWriter
/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import com.hongbeomi.harrypotter.data.service.HarryPotterService
import okhttp3.OkHttpClient
import okhttp3.logging.HttpLoggingInterceptor
import org.koin.dsl.module
import retrofit2.Retrofit
import retrofit2.converter.gson.GsonConverterFactory
import java.io.IOException
import java.util.concurrent.TimeUnit


private const val CONNECT_TIMEOUT = 10L
private const val WRITE_TIMEOUT = 1L
private const val READ_TIMEOUT = 20L
Expand Down
17 changes: 17 additions & 0 deletions app/src/main/java/com/hongbeomi/harrypotter/di/RepositoryModule.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.di

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import com.hongbeomi.harrypotter.data.repository.Repository
import com.hongbeomi.harrypotter.data.repository.RepositoryImpl
import org.koin.dsl.module
Expand Down
17 changes: 17 additions & 0 deletions app/src/main/java/com/hongbeomi/harrypotter/di/ViewModelModule.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.di

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import com.hongbeomi.harrypotter.ui.detail.DetailViewModel
import com.hongbeomi.harrypotter.ui.HouseType
import org.koin.android.viewmodel.dsl.viewModel
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.extension

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import android.widget.ImageView
import androidx.databinding.BindingAdapter
import androidx.recyclerview.widget.RecyclerView
Expand Down
17 changes: 17 additions & 0 deletions app/src/main/java/com/hongbeomi/harrypotter/model/Character.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.model

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import android.os.Parcelable
import kotlinx.android.parcel.Parcelize

Expand Down
17 changes: 17 additions & 0 deletions app/src/main/java/com/hongbeomi/harrypotter/ui/HouseType.kt
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
package com.hongbeomi.harrypotter.ui

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import androidx.annotation.ColorRes
import androidx.annotation.DrawableRes
import com.hongbeomi.harrypotter.R
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,27 @@
package com.hongbeomi.harrypotter.ui

/**
* Copyright 2020 Hongbeom Ahn
*
* 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.
*
**/

import android.graphics.Rect
import android.view.View
import androidx.recyclerview.widget.RecyclerView
import androidx.recyclerview.widget.RecyclerView.ItemDecoration


class SpaceItemDecoration(private val space: Int, private val mNumCol: Int) : ItemDecoration() {

override fun getItemOffsets(
Expand Down
Loading

0 comments on commit f2b6100

Please sign in to comment.