CLN: simplify CategoricalIndex internals
State: closed

Simplify method signatures of some internal methods of ``CategoricalIndex``.

Labels:
name: Internals
description: Related to non-user accessible pandas implementation
name: Categorical
description: Categorical Data Type

Comments:
Hello @topper-123! Thanks for submitting the PR.

 - There are no PEP8 issues in the file [`pandas/core/indexes/category.py`](https://github.com/topper-123/pandas/blob/6a5a1f76f26842d97e1fe89d035a90159fab159d/pandas/core/indexes/category.py) !


The travis error is unrelated: 

```
curl: (56) SSL read: error:00000000:lib(0):func(0):reason(0), errno 104
Unable to download 3.5 archive. The archive may not exist. Please consider a different version.
```

i restarted to make sure this passes. ping on green.
# [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24343?src=pr&el=h1) Report
> Merging [#24343](https://codecov.io/gh/pandas-dev/pandas/pull/24343?src=pr&el=desc) into [master](https://codecov.io/gh/pandas-dev/pandas/commit/a34adac86c6bc15d854dbaf2092eab37c76c1461?src=pr&el=desc) will **increase** coverage by `0.06%`.
> The diff coverage is `100%`.

[![Impacted file tree graph](https://codecov.io/gh/pandas-dev/pandas/pull/24343/graphs/tree.svg?width=650&token=eZ4WkYLtcO&height=150&src=pr)](https://codecov.io/gh/pandas-dev/pandas/pull/24343?src=pr&el=tree)

```diff
@@            Coverage Diff             @@
##           master   #24343      +/-   ##
==========================================
+ Coverage   92.28%   92.34%   +0.06%     
==========================================
  Files         162      162              
  Lines       51835    52217     +382     
==========================================
+ Hits        47834    48218     +384     
+ Misses       4001     3999       -2
```

| Flag | Coverage Δ | |
|---|---|---|
| #multiple | `90.75% <100%> (+0.07%)` | :arrow_up: |
| #single | `43.16% <90%> (+0.16%)` | :arrow_up: |

| [Impacted Files](https://codecov.io/gh/pandas-dev/pandas/pull/24343?src=pr&el=tree) | Coverage Δ | |
|---|---|---|
| [pandas/core/indexes/category.py](https://codecov.io/gh/pandas-dev/pandas/pull/24343/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvaW5kZXhlcy9jYXRlZ29yeS5weQ==) | `98.65% <100%> (+0.75%)` | :arrow_up: |
| [pandas/util/testing.py](https://codecov.io/gh/pandas-dev/pandas/pull/24343/diff?src=pr&el=tree#diff-cGFuZGFzL3V0aWwvdGVzdGluZy5weQ==) | `87.58% <0%> (+0.09%)` | :arrow_up: |
| [pandas/core/arrays/datetimes.py](https://codecov.io/gh/pandas-dev/pandas/pull/24343/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvYXJyYXlzL2RhdGV0aW1lcy5weQ==) | `98.37% <0%> (+0.13%)` | :arrow_up: |
| [pandas/core/resample.py](https://codecov.io/gh/pandas-dev/pandas/pull/24343/diff?src=pr&el=tree#diff-cGFuZGFzL2NvcmUvcmVzYW1wbGUucHk=) | `96.75% <0%> (+0.16%)` | :arrow_up: |
| [pandas/tseries/offsets.py](https://codecov.io/gh/pandas-dev/pandas/pull/24343/diff?src=pr&el=tree#diff-cGFuZGFzL3RzZXJpZXMvb2Zmc2V0cy5weQ==) | `97.24% <0%> (+0.4%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24343?src=pr&el=continue).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/pandas-dev/pandas/pull/24343?src=pr&el=footer). Last update [a34adac...6a5a1f7](https://codecov.io/gh/pandas-dev/pandas/pull/24343?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).

thanks @topper-123