-
-
Notifications
You must be signed in to change notification settings - Fork 18.7k
Closed
Labels
API DesignStringsString extension data type and string dataString extension data type and string data
Milestone
Description
Should StringMethods
be compatible with standard str
, or have only useful methods? Sometimes I have to adjust text formats before converting other types, and I've chosen additionals which makes formatting / adjustments easier. Any ideas?
-
str.find
(ENH: Add StringMethod.find and rfind #9386) -
str.rfind
(ENH: Add StringMethod.find and rfind #9386) -
str.isalnum
(ENH: StringMethods supports is_xxx methods #9282) -
str.isalpha
(ENH: StringMethods supports is_xxx methods #9282) -
str.isdigit
(ENH: StringMethods supports is_xxx methods #9282) -
str.isspace
(ENH: StringMethods supports is_xxx methods #9282) -
str.islower
(ENH: StringMethods supports is_xxx methods #9282) -
str.isupper
(ENH: StringMethods supports is_xxx methods #9282) -
str.istitle
(ENH: StringMethods supports is_xxx methods #9282) -
str.ljust
(ENH: StringMethods now supports ljust and rjust #9352) -
str.rjust
(ENH: StringMethods now supports ljust and rjust #9352):StringMethods.pad
works as the same asljust
,rjust
andcenter
by switchingside
option. AndStringMethods.center
exists,ljust
andrjust
don't. -
str.rsplit
:split
also supports regex, and there seems no straightforward way torsplit
using regex. (ENH: added rsplit to StringMethods #10303) -
str.zfill
(ENH: Add StringMethods.zfill #9387) -
StringMethods.center
andStringMethods.pad
should have 'fillchar` kw to specify padding character. (ENH: StringMethods now supports ljust and rjust #9352) -
str.capitalize
(ENH: Add StringMethods.capitalize and swapcase #9766) -
str.swapcase
(ENH: Add StringMethods.capitalize and swapcase #9766) -
str.translate
(ENH: support str translate for StringMethods #10052) -
str.index
(ENH: support StringMethods index and rindex #10045) -
str.rindex
(ENH: support StringMethods index and rindex #10045) -
str.partition
(ENH: Add StringMethods.partition and rpartition #9773) -
str.rpartition
(ENH: Add StringMethods.partition and rpartition #9773) -
unicode.isnumeric
(ENH: Add StringMethods.isnumeric and isdecimal #9439) -
unicode.isdecimal
(ENH: Add StringMethods.isnumeric and isdecimal #9439) -
unicodedata.normalize
(ENH: Added str.normalize to use unicodedata.normalize #10031)
NOTE For python 2.x, once convert target to unicode internally then call the func.
Which may not be very userful:
expandtabs
splitlines
I think there is an option to implement these to say "support the same methods as standard str
".
Metadata
Metadata
Assignees
Labels
API DesignStringsString extension data type and string dataString extension data type and string data