Class | Sweeper
In: | app/models/sweeper.rb
Parent: | ActionController::Caching::Sweeper

Copyright (c) 2006 Logica

### Methods

after_create after_destroy

### Public Instance methods

after_create(record)

TODO more advanced expiration

[Source]

        # File app/models/sweeper.rb, line 20
    20:   def after_create(record)
    21:     if record.is_a?(Wiki) || record.is_a?(Checkout) || record.is_a?(Comment) || record.is_a?(UserVersion) || record.is_a?(Wiki) || record.is_a?(Upload)
    22:       expire_all_pages
    23:     elsif record.is_a?(WikiPage)
    24:       expire_all_pages if record.tool = 'Wiki'
    25:     end
    26:   end

after_destroy(record)

[Source]

        # File app/models/sweeper.rb, line 28
    28:   def after_destroy(record)
    29:     if record.is_a?(Checkout)
    30:       expire_all_pages
    31:     end
    32:   end

[Validate]