tp TouchPointWP Involvement_PostTypeSettings - TenthPres/TouchPoint-WP GitHub Wiki

tp\TouchPointWP\Involvement_PostTypeSettings

Contains the settings for a single Involvement Post Type. This is instantiated as an array of these objects.

  • Class name: Involvement_PostTypeSettings
  • Namespace: \tp\TouchPointWP

Constants

POST_TYPE_PREFIX

const POST_TYPE_PREFIX = "inv_"

Methods

instance

\tp\TouchPointWP\Involvement_PostTypeSettings[] tp\TouchPointWP\Involvement_PostTypeSettings::instance()
  • Visibility: public
  • This method is static.

Returns

  • \tp\TouchPointWP\Involvement_PostTypeSettings[] -

__construct

mixed tp\TouchPointWP\Involvement_PostTypeSettings::__construct(object o)
  • Visibility: public

Arguments

  • o object

Returns

  • mixed

getAllDivs

int[] tp\TouchPointWP\Involvement_PostTypeSettings::getAllDivs()

Get a list of all division IDs that are being imported by all types.

  • Visibility: public
  • This method is static.

Returns

  • int[] -

postTypeWithPrefix

string tp\TouchPointWP\Involvement_PostTypeSettings::postTypeWithPrefix()

Get the Post Type for use with WordPress functions

  • Visibility: public

Returns

  • string -

postTypeWithoutPrefix

string tp\TouchPointWP\Involvement_PostTypeSettings::postTypeWithoutPrefix()

Get the Post Type without the hook prefix.

  • Visibility: public

Returns

  • string -

__get

mixed tp\TouchPointWP\Involvement_PostTypeSettings::__get(mixed what)
  • Visibility: public

Arguments

  • what mixed

Returns

  • mixed

getPostTypes

string[] tp\TouchPointWP\Involvement_PostTypeSettings::getPostTypes()

Gets an array of the postType strings.

  • Visibility: public
  • This method is static.

Returns

  • string[] -

getPostTypesWithGeoEnabled

string[] tp\TouchPointWP\Involvement_PostTypeSettings::getPostTypesWithGeoEnabled()

Gets an array of the postType strings for post type that use Geo.

  • Visibility: public
  • This method is static.

Returns

  • string[] -

getForInvType

\tp\TouchPointWP\Involvement_PostTypeSettings|null tp\TouchPointWP\Involvement_PostTypeSettings::getForInvType(string postType)

Gets the Involvement Post Type Settings object for a given inv type.

  • Visibility: public
  • This method is static.

Arguments

  • postType string

Returns

  • \tp\TouchPointWP\Involvement_PostTypeSettings|null -

validateNewSettings

string tp\TouchPointWP\Involvement_PostTypeSettings::validateNewSettings(string new)
  • Visibility: public
  • This method is static.

Arguments

  • new string

Returns

  • string -

leaderTypeInts

int[] tp\TouchPointWP\Involvement_PostTypeSettings::leaderTypeInts()

Get the leader member types, as an array of ints

  • Visibility: public

Returns

  • int[] -

hostTypeInts

?int[] tp\TouchPointWP\Involvement_PostTypeSettings::hostTypeInts()

Get the host member types, as an array of ints. Will be null if useGeo is false.

  • Visibility: public

Returns

  • ?int[] -