| 1 |
// |
| 2 |
// CMRHostTypes.h |
| 3 |
// BathyScaphe |
| 4 |
// |
| 5 |
// Updated by Tsutomu Sawada on 10/03/07. |
| 6 |
// Copyright 2005-2014 BathyScaphe Project. All rights reserved. |
| 7 |
// encoding="UTF-8" |
| 8 |
// |
| 9 |
|
| 10 |
#ifndef HOSTTYPES_INCLUDED |
| 11 |
#define HOSTTYPES_INCLUDED |
| 12 |
#ifdef __cplusplus |
| 13 |
extern "C" { |
| 14 |
#endif |
| 15 |
|
| 16 |
#import <Foundation/Foundation.h> |
| 17 |
|
| 18 |
/* |
| 19 |
2channel.brd compatibility |
| 20 |
-------------------------------- |
| 21 |
http://jbbs.shitaraba.com/business/767/ |
| 22 |
--> |
| 23 |
(host) jbbs.shitaraba.com |
| 24 |
(path) jbbs.shitaraba.com/business |
| 25 |
(directory) 767 |
| 26 |
*/ |
| 27 |
|
| 28 |
// return temporary cstring |
| 29 |
extern const char *CMRGetHostCStringFromBoardURL(NSURL *anURL, const char **bbs); |
| 30 |
// return copied string |
| 31 |
extern NSString *CMRGetHostStringFromBoardURL(NSURL *anURL, NSString **bbs); |
| 32 |
// Available in BathyScaphe 2.4.1 and later. |
| 33 |
// jbbs.livedoor.jp <--> jbbs.shitaraba.net 相互変換した URL を返す。 |
| 34 |
// したらば以外の URL では nil を返す。 |
| 35 |
// 変換後の URL では、末尾の「/」が消えているので -absoluteString して使う際は要注意。 |
| 36 |
extern NSURL *CMRGetAlternativeHostURLFromShitarabaBoardURL(NSURL *anURL); |
| 37 |
|
| 38 |
|
| 39 |
|
| 40 |
extern bool can_readcgi(const char *host); |
| 41 |
|
| 42 |
// 2channel互換 |
| 43 |
extern bool is_2channel(const char *host); |
| 44 |
|
| 45 |
// 純粋な2ちゃんねる(pink も除く) Available in BathyScaphe 2.0.3 and later. |
| 46 |
extern bool is_2ch_except_pink(const char *host); |
| 47 |
/* |
| 48 |
Deprecated in BathyScaphe 2.0 and later. |
| 49 |
*/ |
| 50 |
//extern bool is_be2ch(const char *host); // EUC エンコーディングが必要かどうかを判定する際に使う |
| 51 |
|
| 52 |
// 書き込みに Be ログインが必須かどうかを判定する際に使う |
| 53 |
extern bool is_2ch_belogin_needed(const char *host); |
| 54 |
|
| 55 |
/* |
| 56 |
Deprecated in BathyScaphe 2.0 and later. |
| 57 |
Use is_jbbs_livedoor(const char *host) instead. |
| 58 |
*/ |
| 59 |
extern bool is_jbbs_shita(const char *host); |
| 60 |
|
| 61 |
/* |
| 62 |
Available in BathyScaphe 1.6 and later. |
| 63 |
*/ |
| 64 |
extern bool is_jbbs_livedoor(const char *host); |
| 65 |
extern bool is_machi(const char *host); |
| 66 |
|
| 67 |
/* |
| 68 |
Deprecated in BathyScaphe 1.6 and later. |
| 69 |
These BBSs has no longer been available recent years. |
| 70 |
*/ |
| 71 |
//extern bool is_jbbs(const char *host); |
| 72 |
//extern bool is_shitaraba(const char *host); |
| 73 |
//extern bool is_tanteifile(const char *host); |
| 74 |
|
| 75 |
//extern bool can_offlaw(const char *host); |
| 76 |
//extern bool kako_salad(const char *host, const char *bbs); |
| 77 |
//extern bool bbs_qb(const char *host); |
| 78 |
|
| 79 |
/* |
| 80 |
Available in BathyScaphe 2.4.2 and later. |
| 81 |
*/ |
| 82 |
extern bool is_2ch_sc(const char *host); |
| 83 |
|
| 84 |
|
| 85 |
|
| 86 |
|
| 87 |
#ifdef __cplusplus |
| 88 |
} |
| 89 |
#endif |
| 90 |
|
| 91 |
#endif /* HOSTTYPES_INCLUDED */ |