Skip to content

Commit

Permalink
Fixed formatting issues: indents, and block quotes
Browse files Browse the repository at this point in the history
  • Loading branch information
map222 committed Mar 31, 2017
1 parent 86a90bc commit ccaff42
Showing 1 changed file with 24 additions and 22 deletions.
46 changes: 24 additions & 22 deletions python/pyspark/sql/column.py
Original file line number Diff line number Diff line change
Expand Up @@ -251,32 +251,34 @@ def __iter__(self):

# string methods
_rlike_doc = """ Return a Boolean :class:`Column` based on a regex match.\n
:param other: an extended regex expression\n
:param other: an extended regex expression
>>> df.filter( df.name.rlike('ice$') ).collect()
[Row(name=u'Alice', age=1)]
"""
>>> df.filter( df.name.rlike('ice$') ).collect()
[Row(name=u'Alice', age=1)]
"""
_like_doc = """ Return a Boolean :class:`Column` based on a SQL LIKE match.\n
:param other: a SQL LIKE pattern\n
See :func:`pyspark.sql.Column.rlike` for a regex version\n
:param other: a SQL LIKE pattern\n
See :func:`pyspark.sql.Column.rlike` for a regex version
>>> df.filter( df.name.like('Al%') ).collect()
[Row(name=u'Alice', age=1)]
>>> df.filter( df.name.like('Al%') ).collect()
[Row(name=u'Alice', age=1)]
"""
_startswith_doc = ''' Return a Boolean :class:`Column` based on a string match.\n
:param other: string at end of line (do not use a regex `^`)\n
>>> df.filter(df.name.startswith('Al')).collect()
[Row(name=u'Alice', age=1)]
>>> df.filter(df.name.startswith('^Al')).collect()
[]
'''
_endswith_doc = ''' Return a Boolean :class:`Column` based on matching end of string.\n
:param other: string at end of line (do not use a regex `$`)\n
>>> df.filter(df.name.endswith('ice')).collect()
[Row(name=u'Alice', age=1)]
>>> df.filter(df.name.endswith('ice$')).collect()
[]
'''
_startswith_doc = """ Return a Boolean :class:`Column` based on a string match.\n
:param other: string at end of line (do not use a regex `^`)
>>> df.filter(df.name.startswith('Al')).collect()
[Row(name=u'Alice', age=1)]
>>> df.filter(df.name.startswith('^Al')).collect()
[]
"""
_endswith_doc = """ Return a Boolean :class:`Column` based on matching end of string.\n
:param other: string at end of line (do not use a regex `$`)
>>> df.filter(df.name.endswith('ice')).collect()
[Row(name=u'Alice', age=1)]
>>> df.filter(df.name.endswith('ice$')).collect()
[]
"""

contains = _bin_op("contains")
rlike = _bin_op("rlike", _rlike_doc)
Expand Down

0 comments on commit ccaff42

Please sign in to comment.