Skip to content

Commit

Permalink
Corrected links and dates
Browse files Browse the repository at this point in the history
  • Loading branch information
andypiper committed Oct 22, 2020
1 parent 827b9f9 commit 3af0d32
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 17 deletions.
8 changes: 4 additions & 4 deletions java/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ This is the Java implementation of the twitter-text parsing library. The library

## Getting Started

The latest artifacts are published to maven central.
The latest artifacts are published to Maven Central.

Bringing twitter-text-java into your project should be as simple as adding the following to your pom.xml:

Expand Down Expand Up @@ -48,15 +48,15 @@ twitter-text 2.0 introduced configuration files that define how Tweets are parse

This method takes a string as input and returns a results object that contains information about the string. `TwitterTextParseResults` includes:

* `public final int weightedLength`: the overall length of the tweet with code points weighted per the ranges defined in the configuration file.
* `public final int weightedLength`: the overall length of the Tweet with code points weighted per the ranges defined in the configuration file.

* `public final int permillage`: indicates the proportion (per thousand) of the weighted length in comparison to the max weighted length. A value > 1000 indicates input text that is longer than the allowable maximum.

* `public final boolean isValid`: indicates if input text length corresponds to a valid result.

* `public final Range displayTextRange`: A pair of unicode code point indices identifying the inclusive start and exclusive end of the displayable content of the Tweet. For more information, see the description of `display_text_range` here: [Tweet updates](https://developer.twitter.com/en/docs/tweets/tweet-updates)
* `public final Range displayTextRange`: A pair of unicode code point indices identifying the inclusive start and exclusive end of the displayable content of the Tweet.

* `public final Range validDisplayTextRange`: A pair of unicode code point indices identifying the inclusive start and exclusive end of the valid content of the Tweet. For more information on the `display_text_range` see [Tweet updates](https://developer.twitter.com/en/docs/tweets/tweet-updates)
* `public final Range validDisplayTextRange`: A pair of unicode code point indices identifying the inclusive start and exclusive end of the valid content of the Tweet.

## Tweet Length Examples

Expand Down
10 changes: 5 additions & 5 deletions js/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ twitter.autoLink(twitter.htmlEscape('#hello < @world >'))
}
]});

See [Tweet Entities](https://dev.twitter.com/overview/api/entities-in-twitter-objects) for more info getting url entities from Twitter's API.
See [Tweet Entities](https://developer.twitter.com/en/docs/twitter-api/v1/data-dictionary/overview/entities-object) for more info getting url entities from Twitter's API.

## Tweet Parsing
Previous versions of Twitter-Text provided different helper methods for Tweet validation, Tweet length, and remaining characters calculation. To simplify the API and obtain this information with just one call, Twitter-Text now exposes a new “parseTweet” method that will return the following fields:
Expand All @@ -52,7 +52,7 @@ Previous versions of Twitter-Text provided different helper methods for Tweet va
* **validDisplayRangeEnd:** Integer indicating the valid end index on the Tweet string. This can be lesser than displayRangeEnd (inclusive).

```js
var tweet = "This is a test tweet";
var tweet = "This is a test Tweet";
twttr.txt.parseTweet(tweet);
/* Returns:
{
Expand All @@ -66,11 +66,11 @@ twttr.txt.parseTweet(tweet);
}
*/
```
Details about Twitter's weighted counting scheme are available on the [official developer website](https://developer.twitter.com/en/docs/developer-utilities/twitter-text).
Details about Twitter's weighted counting scheme are available on the [official developer website](https://developer.twitter.com/en/docs/counting-characters).

### Marked for Deprecation

`getTweetLength` returns the weighted length of a tweet that is calculated by parseTweet. It will be deprecated in a subsequent release. Please use parseTweet instead.
`getTweetLength` returns the weighted length of a Tweet that is calculated by parseTweet. It will be removed in a subsequent release. Please use parseTweet instead.

## Usernames

Expand Down Expand Up @@ -149,7 +149,7 @@ Please direct bug reports to the [twitter-text issue tracker on GitHub](https://

## Copyright and License

Copyright 2012 Twitter, Inc.
Copyright 2012-2020 Twitter, Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this work except in compliance with the License.
Expand Down
11 changes: 4 additions & 7 deletions objc/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ This method takes a string as input and returns a results object that
contains information about the string. `TwitterTextParseResults`
includes:

* `(NSInteger)weightedLength`: the overall length of the tweet with code points
* `(NSInteger)weightedLength`: the overall length of the Tweet with code points
weighted per the ranges defined in the configuration file.

* `(NSInteger)permillage`: indicates the proportion (per thousand) of the weighted
Expand All @@ -71,14 +71,11 @@ result.

* `(NSRange)displayTextRange`: An array of two unicode code point
indices identifying the inclusive start and exclusive end of the
displayable content of the Tweet. For more information, see
the description of `display_text_range` here:
[Tweet updates](https://developer.twitter.com/en/docs/tweets/tweet-updates)
displayable content of the Tweet.

* `(NSRange)validDisplayTextRange`: An array of two unicode code point
indices identifying the inclusive start and exclusive end of the valid
content of the Tweet. For more information on the extended Tweet
payload see [Tweet updates](https://developer.twitter.com/en/docs/tweets/tweet-updates)
content of the Tweet.

## Issues

Expand All @@ -94,6 +91,6 @@ Have a bug? Please create an issue here on GitHub!

## License

Copyright 2012-2018 Twitter, Inc and other contributors
Copyright 2012-2020 Twitter, Inc and other contributors

Licensed under the [Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0)
2 changes: 1 addition & 1 deletion rb/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,6 @@ Have a bug? Please create an issue here on GitHub!

## License

Copyright 2012-2018 Twitter, Inc and other contributors
Copyright 2012-2020 Twitter, Inc and other contributors

Licensed under the [Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0)

0 comments on commit 3af0d32

Please sign in to comment.