Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 04-27-2023, 10:02 AM   #106
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 8,724
Karma: 62000001
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
if it follows the same behaviour as annotation_count(), checking it >#0 should also work.
ownedbycats is offline   Reply With Quote
Old 04-27-2023, 10:21 AM   #107
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,761
Karma: 7029857
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by ownedbycats View Post
if it follows the same behaviour as annotation_count(), checking it >#0 should also work.
Yes, it will, but this is a touch slower if all you want to know is if some files exist. Same thing is true for annotation_count().

I am submitting these changes:
  • has_extra_files([pattern]) -- returns the count of extra files, otherwise '' (the empty string). If the optional parameter 'pattern', a regular expression, is supplied then the list is filtered to files that match pattern before the files are counted. The pattern match is case insensitive. This function can be used only in the GUI.
  • extra_file_names(sep [, pattern]) -- returns a sep-separated list of extra files in the book's '{}/' folder. If the optional parameter 'pattern', a regular expression, is supplied then the list is filtered to files that match pattern. The pattern match is case insensitive. This function can be used only in the GUI.
chaley is offline   Reply With Quote
Advert
Old 04-27-2023, 11:09 AM   #108
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,761
Karma: 7029857
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Changed template functions

27 Apr 2023 (in calibre 6.18)

Changed template functions.
  • has_extra_files()
    Code:
    has_extra_files([pattern])
    returns the count of extra files, otherwise '' (the empty string). If the optional parameter 'pattern', a regular expression, is supplied then the list is filtered to files that match pattern before the files are counted. The pattern match is case insensitive. This function can be used only in the GUI.

    What changed: the 'pattern' parameter was added and the function returns a count instead of 'Yes'.
  • extra_file_names()
    Code:
    extra_file_names(sep [, pattern])
    returns a sep-separated list of extra files in the book's '{}/' folder. If the optional parameter 'pattern', a regular expression, is supplied then the list is filtered to files that match pattern. The pattern match is case insensitive. This function can be used only in the GUI.

    What changed: the 'pattern' parameter was added.

Last edited by chaley; 06-21-2023 at 03:43 PM.
chaley is offline   Reply With Quote
Old 04-27-2023, 11:31 AM   #109
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,761
Karma: 7029857
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by BetterRed View Post
I want to show an icon if the data folder contains a file named todo.???? (might be ToDo.txt, TODO.EML, todo.stky, etc).

Something like extra_file_exists("todo.*") might be useful.

BR
The changed has_extra_files() that takes an optional regexp does what you want, returning a count of files that match the pattern. For example:
Code:
program:
	if has_extra_files('^todo\.') then "icon.png" fi
chaley is offline   Reply With Quote
Old 04-29-2023, 05:46 PM   #110
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,622
Karma: 26960534
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by BetterRed View Post
I want to show an icon if the data folder contains a file named todo.???? (might be ToDo.txt, TODO.EML, todo.stky, etc).

Something like extra_file_exists("todo.*") might be useful.

BR
Quote:
Originally Posted by chaley View Post
Code:
program:
	files = extra_file_names(':');
	in_list(files, ':', 'todo\..*', 'Yes', '')
EDIT: where 'Yes' would be the icon name
I see I forgot to thank you for this, so I'm doing it now. Thanks

It works of course but because I use the file manager to add/delete the file to/from the books data folder the column icon doesn't appear/disappear in real time.

Re-apply current sort (F5) doesn't do the trick, perhaps it could/should. Header menu->Restore default layout doesn't do it either. Apart from restart, the only way I've found to get the icon updated, is switching to another library and back again.

BR
BetterRed is offline   Reply With Quote
Advert
Old 04-29-2023, 06:49 PM   #111
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,622
Karma: 26960534
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by BetterRed View Post
. . . because I use the file manager to add/delete the file to/from the books data folder the column icon doesn't appear/disappear in real time.

Re-apply current sort (F5) doesn't do the trick, perhaps it could/should. Header menu->Restore default layout doesn't do it either. Apart from restart, the only way I've found to get the icon updated, is switching to another library and back again.

BR
On reflection, I'm going to take different tack on this; not only does it get rid of the icon update problem, its a better solution to storing transient data like to-do-lists, reminders etc.

I'll put them into a OneNote 'page' and put a link to it in the Links column, then I can set the icon to show if Links contains "To Do in OneNote".

BR
BetterRed is offline   Reply With Quote
Old 04-30-2023, 05:05 AM   #112
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,761
Karma: 7029857
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by BetterRed View Post
I see I forgot to thank you for this, so I'm doing it now. Thanks
You are welcome
Quote:
It works of course but because I use the file manager to add/delete the file to/from the books data folder the column icon doesn't appear/disappear in real time.

Re-apply current sort (F5) doesn't do the trick, perhaps it could/should. Header menu->Restore default layout doesn't do it either. Apart from restart, the only way I've found to get the icon updated, is switching to another library and back again.

BR
Ways to refresh it are (some of these might require the next release -- I don't remember beyond what I noted):
  • Using the link to open a file explorer on a book or a book's data folder resets the indicator for that book. In the next release it checks once per second for 5 minutes after you open the explorer. If you do your "File system operations" using that explorer then the icon will automatically update.
  • Using "Add data files to books" does the reset for the affected books.
  • Selecting the book, doing Edit Metadata, changing nothing, then hit OK, does it for that book.
  • Selecting all books then doing Edit Metadata (bulk), changing nothing, then pressing OK does it.
  • Editing any cell, for example Title, then hitting return without changing anything does it for that book.
  • This python template does it for all books:
    Code:
    python:
    def evaluate(book, context):
    	db = context.db.new_api
    	db.clear_extra_files_cache(None)
    	return 'Ok'
  • Use a Python code Action chain, probably with a shortcut. The code is
    Code:
    def run(gui, settings, chain):
        db = gui.current_db.new_api
        db.clear_extra_files_cache(None)
        gui.current_view().model().refresh()
  • Of course and as you found, restarting or switching libraries does it.
I don't think doing it on every sort is a good idea, as that would affect performance by making the cache near useless. It also isn't any more discoverable than the above operations.

I considered adding a global refresh action but Kovid thought that such a thing wouldn't be any more discoverable than (for example) Select All then Edit Metadata (bulk) then OK without changing anything.
chaley is offline   Reply With Quote
Old 04-30-2023, 08:43 PM   #113
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,622
Karma: 26960534
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by chaley View Post
Ways to refresh it are (some of these might require the next release -- I don't remember beyond what I noted):

<snip>

I don't think doing it on every sort is a good idea, as that would affect performance by making the cache near useless. It also isn't any more discoverable than the above operations.

I considered adding a global refresh action but Kovid thought that such a thing wouldn't be any more discoverable than (for example) Select All then Edit Metadata (bulk) then OK without changing anything.
FTR: The 'todo.txt' was created by: pressing 'O' to open the book folder, I then opened the already existing 'data' folder in File Explorer, created a todo.txt, saved it and closed File Explorer.

I tried various things to try to get the icon to show, edited a date custom column via F2, added a Tag in the MDE dialogue and saved it, edited a long text column with JobSpy's NoteView, re-sorted the list by clicking on the Author column header, moved columns and refreshed via View Manager's Refresh current view. None of them caused the icon to display.

I 'picked' on Refresh current sort because its default shortcut is F5 which is often used as the shortcut key for 'refresh' - almost a de-facto standard like F1 for Help, F2 for Edit, etc. BTW it is not in the Sort By menu.

But all of that is moot now. It was a bad design decision on my part to use the presence of a todo.* file in the data folder as a signal I needed to do something… classic case of give a bloke a new hammer and everything looks like a nail. I'll put the ON page links into a #todo/To Do column, needless to say I'll put a calibre:\\show-book URL into the ON pages.

Matters arising:
  • I think we need a keyboard shortcut to open the data folder, having to press 'O' to open the book folder and then poking around it to open the 'data' folder is… 'hazardous'.
  • I noticed there are couple of unassigned Copy URL keyboard shortcuts for Metadata Edit that aren't in the Metadata Edit menu.

    I think we need a Copy Calibre URL toolbar/menu item that consolidates the Copy links options in the book details and column right click menus. This would make them keyboard accessible (via the book list context menu) and obviate need to show the book details panel to access them.

Slightly off topic. Caste your mind back to when you made the Tag Browser keyboard accessible, I can't find the thread now, but I'm sure you provided a keyboard way of cycling through the +, ++, -, and -- options, I thought it was Space, if it was, it's not working now… otherwise I've forgotten what it was

BR

Last edited by BetterRed; 04-30-2023 at 08:50 PM.
BetterRed is offline   Reply With Quote
Old 04-30-2023, 09:02 PM   #114
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 8,724
Karma: 62000001
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
If 'D' is unutilized*, I think that would make a good default Open Extra Data Folder key.

* is there a list of the defaults somewhere? Ive modified mine a lot.
ownedbycats is offline   Reply With Quote
Old 04-30-2023, 09:08 PM   #115
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,622
Karma: 26960534
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by ownedbycats View Post
If 'D' is unutilized*, I think that would make a good default Open Extra Data Folder key.

* is there a list of the defaults somewhere? Ive modified mine a lot.
JS+ GUI Tool: Active Keyboard Shortcut Assignments

D is default for send to device

Salt on Sauce.

BR
BetterRed is offline   Reply With Quote
Old 05-01-2023, 07:13 AM   #116
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,761
Karma: 7029857
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by BetterRed View Post
[...]
Matters arising:
  1. I think we need a keyboard shortcut to open the data folder, having to press 'O' to open the book folder and then poking around it to open the 'data' folder is… 'hazardous'.
  2. I noticed there are couple of unassigned Copy URL keyboard shortcuts for Metadata Edit that aren't in the Metadata Edit menu.

    I think we need a Copy Calibre URL toolbar/menu item that consolidates the Copy links options in the book details and column right click menus. This would make them keyboard accessible (via the book list context menu) and obviate need to show the book details panel to access them.
Re #1: I will look at that. Re #2: You are asking that all the Copy URL actions show in the edit metadata action? If so, why put them into a new action as well?
Quote:
Slightly off topic. Caste your mind back to when you made the Tag Browser keyboard accessible, I can't find the thread now, but I'm sure you provided a keyboard way of cycling through the +, ++, -, and -- options, I thought it was Space, if it was, it's not working now… otherwise I've forgotten what it was

BR
The Return key. And for completeness, the left and right arrow keys open and close categories.
chaley is offline   Reply With Quote
Old 05-01-2023, 01:05 PM   #117
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,622
Karma: 26960534
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by chaley View Post
Re #2: You are asking that all the Copy URL actions show in the edit metadata action? If so, why put them into a new action as well?
I should have been explicit.

I was suggesting the two Copy URL shortcuts in the MDE group be removed, and all the Copy URL actions be gathered onto a dedicated Copy Calibre:// URL tool that can be added to a menu or tool bar. This would include those kept in category link fields, which would make it a dynamic menu.

I doubt more than 10% of calibre users make use of the Copy calibre:// URLs right click actions in book details, and not even 1% would have discovered the two MDE shortcuts… I spotted them when looking for an Open data folder shortcut.

Quote:
Originally Posted by chaley View Post
The Return key. And for completeness, the left and right arrow keys open and close categories.
Aa-ha, the Typewriter Return key, I would have tried the Numpad Return key

BR
BetterRed is offline   Reply With Quote
Old 05-02-2023, 05:32 AM   #118
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,761
Karma: 7029857
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by BetterRed View Post
Matters arising:
  • I think we need a keyboard shortcut to open the data folder, having to press 'O' to open the book folder and then poking around it to open the 'data' folder is… 'hazardous'.
In source now: the "Open book folder" action has a drop-down menu offering to open either the book folder or the book data folder. Either can have a shortcut. Opening the book folder defaults to O (as before). Opening the data folder doesn't have a default. You can put the action wherever you want: toolbars and/or the context menu.

NB: In the process renamed the action from "Open containing folder" to "Open book folder".
chaley is offline   Reply With Quote
Old 05-02-2023, 07:25 PM   #119
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 20,622
Karma: 26960534
Join Date: Mar 2012
Location: Sydney Australia
Device: none
Quote:
Originally Posted by chaley View Post
In source now: the "Open book folder" action has a drop-down menu offering to open either the book folder or the book data folder. Either can have a shortcut. Opening the book folder defaults to O (as before). Opening the data folder doesn't have a default. You can put the action wherever you want: toolbars and/or the context menu.

NB: In the process renamed the action from "Open containing folder" to "Open book folder".


I don't use Send to Device, so 'D' is waiting in the wings. What happens of there is no 'data' subfolder?

BR
BetterRed is offline   Reply With Quote
Old 05-02-2023, 07:26 PM   #120
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 8,724
Karma: 62000001
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
https://github.com/kovidgoyal/calibre/pull/1899

Quote:
Add opening the data folder to the Open action. Allow it to have a shortcut. Create the data folder if it doesn't exist.

Last edited by ownedbycats; 05-02-2023 at 07:29 PM.
ownedbycats is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
A few questions... (template language, mainly) Clem2605 Library Management 2 12-30-2020 03:25 AM
Template Language phossler Calibre 8 01-12-2016 04:37 PM
Help needed with template language Mamaijee Devices 12 02-19-2013 01:52 AM
Help with template language Pepin33 Calibre 8 11-11-2012 08:32 AM
Template language question BookJunkieLI Library Management 7 02-02-2012 06:55 PM


All times are GMT -4. The time now is 01:29 PM.


MobileRead.com is a privately owned, operated and funded community.