Comment

insert_link hentai.Page

A dataclass that bundles related Comment properties. See also the documentation for dataclass on python's docs page or self.thread.

Properties

insert_link self.id -> int

Returns the ID of this Comment object.

            
                from hentai import Hentai

                doujin = Hentai(177013)
                
                # get first comment posted
                comment = doujin.thread[-1]

                # 67669
                print(comment.id)
            
        
insert_link self.gallery_id -> int

Returns the gallery ID of this Comment object.

            
                from hentai import Hentai

                doujin = Hentai(177013)
                
                # get first comment posted
                comment = doujin.thread[-1]

                # 177013
                print(comment.gallery_id)
            
        
insert_link self.post_date -> datetime

Returns the post date of this Comment object as UTC timezone aware datetime object.

            
                from hentai import Hentai

                doujin = Hentai(177013)
                
                # get first comment posted
                comment = doujin.thread[-1]

                # 2016-10-18 14:59:25+00:00
                print(comment.post_date)
            
        
insert_link self.body -> str

Returns the body of this Comment object.

            
                from hentai import Hentai

                doujin = Hentai(177013)
                
                # get first comment posted
                comment = doujin.thread[-1]

                # well depressing from the start but end up as a happy ending
                print(comment.body)
            
        
insert_link self.poster -> User

Returns the poster of this Comment object. See also the User page for detailed information about this dataclass.

            
                from hentai import Hentai

                doujin = Hentai(177013)
                
                # get first comment posted
                comment = doujin.thread[-1]

                # devil_arm
                print(comment.poster.username)