@@ -87,13 +87,13 @@ def freq(self, value):
87
87
88
88
@property
89
89
def freqstr (self ):
90
- return self ._data .freqstr
90
+ return self ._eadata .freqstr
91
91
92
92
def unique (self , level = None ):
93
93
if level is not None :
94
94
self ._validate_index_level (level )
95
95
96
- result = self ._data .unique ()
96
+ result = self ._eadata .unique ()
97
97
98
98
# Note: if `self` is already unique, then self.unique() should share
99
99
# a `freq` with self. If not already unique, then self.freq must be
@@ -106,7 +106,7 @@ def _create_comparison_method(cls, op):
106
106
Create a comparison method that dispatches to ``cls.values``.
107
107
"""
108
108
def wrapper (self , other ):
109
- result = op (self ._data , maybe_unwrap_index (other ))
109
+ result = op (self ._eadata , maybe_unwrap_index (other ))
110
110
return result
111
111
112
112
wrapper .__doc__ = op .__doc__
@@ -205,7 +205,7 @@ def wrapper(left, right):
205
205
206
206
@Appender (DatetimeLikeArrayMixin ._evaluate_compare .__doc__ )
207
207
def _evaluate_compare (self , other , op ):
208
- result = self ._data ._evaluate_compare (other , op )
208
+ result = self ._eadata ._evaluate_compare (other , op )
209
209
if is_bool_dtype (result ):
210
210
return result
211
211
try :
@@ -532,7 +532,7 @@ def _add_datetimelike_methods(cls):
532
532
533
533
def __add__ (self , other ):
534
534
# dispatch to ExtensionArray implementation
535
- result = self ._data .__add__ (maybe_unwrap_index (other ))
535
+ result = self ._eadata .__add__ (maybe_unwrap_index (other ))
536
536
return wrap_arithmetic_op (self , other , result )
537
537
538
538
cls .__add__ = __add__
@@ -544,13 +544,13 @@ def __radd__(self, other):
544
544
545
545
def __sub__ (self , other ):
546
546
# dispatch to ExtensionArray implementation
547
- result = self ._data .__sub__ (maybe_unwrap_index (other ))
547
+ result = self ._eadata .__sub__ (maybe_unwrap_index (other ))
548
548
return wrap_arithmetic_op (self , other , result )
549
549
550
550
cls .__sub__ = __sub__
551
551
552
552
def __rsub__ (self , other ):
553
- result = self ._data .__rsub__ (maybe_unwrap_index (other ))
553
+ result = self ._eadata .__rsub__ (maybe_unwrap_index (other ))
554
554
return wrap_arithmetic_op (self , other , result )
555
555
556
556
cls .__rsub__ = __rsub__
@@ -581,7 +581,7 @@ def repeat(self, repeats, axis=None):
581
581
nv .validate_repeat (tuple (), dict (axis = axis ))
582
582
freq = self .freq if is_period_dtype (self ) else None
583
583
return self ._shallow_copy (self .asi8 .repeat (repeats ), freq = freq )
584
- # TODO: dispatch to _data
584
+ # TODO: dispatch to _eadata
585
585
586
586
@Appender (_index_shared_docs ['where' ] % _index_doc_kwargs )
587
587
def where (self , cond , other = None ):
@@ -655,10 +655,10 @@ def astype(self, dtype, copy=True):
655
655
# Ensure that self.astype(self.dtype) is self
656
656
return self
657
657
658
- new_values = self ._data .astype (dtype , copy = copy )
658
+ new_values = self ._eadata .astype (dtype , copy = copy )
659
659
660
660
# pass copy=False because any copying will be done in the
661
- # _data .astype call above
661
+ # _eadata .astype call above
662
662
return Index (new_values ,
663
663
dtype = new_values .dtype , name = self .name , copy = False )
664
664
@@ -675,7 +675,7 @@ def view(self, dtype=None, type=None):
675
675
676
676
@Appender (DatetimeLikeArrayMixin ._time_shift .__doc__ )
677
677
def _time_shift (self , periods , freq = None ):
678
- result = self ._data ._time_shift (periods , freq = freq )
678
+ result = self ._eadata ._time_shift (periods , freq = freq )
679
679
return type (self )(result , name = self .name )
680
680
681
681
@deprecate_kwarg (old_arg_name = 'n' , new_arg_name = 'periods' )
0 commit comments