Skip to content
This repository has been archived by the owner on Aug 18, 2021. It is now read-only.

Commit

Permalink
Release v1.0.4
Browse files Browse the repository at this point in the history
  • Loading branch information
amirisback committed May 13, 2020
1 parent 0b88b72 commit f86ccb7
Showing 1 changed file with 72 additions and 69 deletions.
141 changes: 72 additions & 69 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# consumable-code-news-api By AmirIsBack
- v1.0.3 - Development
- v1.0.4 - Development
- Stable version

# About This Project
Expand All @@ -8,83 +8,20 @@ Eliminates the method of retrieving json data using retrofit repeatedly. so this
# Special From This Project
Simple code and reusable data

# Fecthing Data Library
- Retrofit
- RxJava
- OkHttp
- Chuck Interceptor

# Documentation The News API
https://newsapi.org/

# Function Main From This Project
// Switch For Using Chuck Interceptor
fun usingChuckInterceptor(context: Context)

// Get Top Headline
fun getTopHeadline(
q: String?,
sources: String?,
category: String?,
country: String?,
pageSize: Int?,
page: Int?,
callback: NewsResultCallback<ArticleResponse>
)

// Get Everythings
fun getEverythings(
q: String?,
from: String?,
to: String?,
qInTitle: String?,
sources: String?,
domains: String?,
excludeDomains: String?,
language: String?,
sortBy: String?,
pageSize: Int?,
page: Int?,
callback: NewsResultCallback<ArticleResponse>
)

// Get Sources
fun getSources(
language: String,
country: String,
category: String,
callback: NewsResultCallback<SourceResponse>
)

# Contant Value Category

object NewsConstant {

const val CATEGORY_BUSINESS = "business"
const val CATEGORY_ENTERTAIMENT = "entertainment"
const val CATEGORY_GENERAL = "general"
const val CATEGORY_HEALTH = "health"
const val CATEGORY_SCIENCE = "science"
const val CATEGORY_SPORTS = "sports"
const val CATEGORY_TECHNOLOGY = "technology"

}

# Android Library Version (build.gradle)
- ext.kotlin_version = '1.3.71'
- classpath 'com.android.tools.build:gradle:3.6.1'
- compileSdkVersion 29
- buildToolsVersion "29.0.3"
- minSdkVersion 21
# Screenshoot Apps
<span align="center"><img width="200px" height="360px" src="docs/image/ss_main.png"></span>

# Version Release
This Is Latest Release

$version_release = 1.0.3
$version_release = 1.0.4

What's New??

* Remove Unused Dependencies *
* update build.gradle, adding sample code *

# How To Use This Project
<h3>Step 1. Add the JitPack repository to your build file</h3>
Expand All @@ -103,7 +40,7 @@ Add it in your root build.gradle at the end of repositories:

dependencies {
// library consumable code news api
implementation 'com.github.amirisback:consumable-code-news-api:$version_release'
implementation 'com.github.amirisback:consumable-code-news-api:1.0.4'
}

<h3>Step 3. Declaration ConsumeNewsApi</h3>
Expand Down Expand Up @@ -137,6 +74,72 @@ Add it in your root build.gradle at the end of repositories:
})


# Contant Value Category

object NewsConstant {

const val CATEGORY_BUSINESS = "business"
const val CATEGORY_ENTERTAIMENT = "entertainment"
const val CATEGORY_GENERAL = "general"
const val CATEGORY_HEALTH = "health"
const val CATEGORY_SCIENCE = "science"
const val CATEGORY_SPORTS = "sports"
const val CATEGORY_TECHNOLOGY = "technology"

}

# Function Main From This Project
// Switch For Using Chuck Interceptor
fun usingChuckInterceptor(context: Context)

// Get Top Headline
fun getTopHeadline(
q: String?,
sources: String?,
category: String?,
country: String?,
pageSize: Int?,
page: Int?,
callback: NewsResultCallback<ArticleResponse>
)

// Get Everythings
fun getEverythings(
q: String?,
from: String?,
to: String?,
qInTitle: String?,
sources: String?,
domains: String?,
excludeDomains: String?,
language: String?,
sortBy: String?,
pageSize: Int?,
page: Int?,
callback: NewsResultCallback<ArticleResponse>
)

// Get Sources
fun getSources(
language: String,
country: String,
category: String,
callback: NewsResultCallback<SourceResponse>
)

# Fecthing Data Library
- Retrofit
- RxJava
- OkHttp
- Chuck Interceptor

# Android Library Version (build.gradle)
- ext.kotlin_version = '1.3.72'
- classpath 'com.android.tools.build:gradle:3.6.3'
- compileSdkVersion 29
- buildToolsVersion "29.0.3"
- minSdkVersion 21

# Colaborator
Very open to anyone, I'll write your name under this, please contribute by sending an email to me

Expand Down

0 comments on commit f86ccb7

Please sign in to comment.